diff options
author | Hakim El Hattab <hakim.elhattab@gmail.com> | 2012-01-03 00:11:05 -0800 |
---|---|---|
committer | Hakim El Hattab <hakim.elhattab@gmail.com> | 2012-01-03 00:11:05 -0800 |
commit | 614b8cde660fb78e45b55490d0f6d8aefb9a35d9 (patch) | |
tree | 0194b871da86d1518097b400f6188e6b74d00019 /js | |
parent | 4805234a41d0019096dcd9e70e3d6cfdafbb6b9b (diff) | |
download | perl-software-in-gnu-guix-614b8cde660fb78e45b55490d0f6d8aefb9a35d9.tar perl-software-in-gnu-guix-614b8cde660fb78e45b55490d0f6d8aefb9a35d9.tar.gz |
scrolling fallback mode for IE < 9
Diffstat (limited to 'js')
-rw-r--r-- | js/reveal.js | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/js/reveal.js b/js/reveal.js index aa5cc7d..767c4b9 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -104,13 +104,26 @@ var Reveal = (function(){ supports3DTransforms = document.body.style['perspectiveProperty'] !== undefined || document.body.style['WebkitPerspective'] !== undefined || document.body.style['MozPerspective'] !== undefined || - document.body.style['msTransform'] !== undefined; + document.body.style['msPerspective'] !== undefined, + + supports2DTransforms = document.body.style['transformProperty'] !== undefined || + document.body.style['WebkitTransform'] !== undefined || + document.body.style['MozTransform'] !== undefined || + document.body.style['msTransform'] !== undefined || + document.body.style['OTransform'] !== undefined; /** * Starts up the slideshow by applying configuration * options and binding various events. */ function initialize( options ) { + + if( !supports2DTransforms && !supports3DTransforms ) { + document.body.setAttribute( 'class', 'no-transforms' ); + + return; + } + // Cache references to DOM elements dom.wrapper = document.querySelector( '#reveal' ); dom.progress = document.querySelector( '#reveal .progress' ); |