Skip to content

Commit

Permalink
Merge branch 'master' into gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
bartaz committed Jan 2, 2012
2 parents 3135a61 + 19029d2 commit 97e244e
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 1 deletion.
12 changes: 12 additions & 0 deletions README.md
Expand Up @@ -9,6 +9,14 @@ transitions in modern browsers and inspired by the idea behind prezi.com.
impress.js may not help you if you have nothing interesting to say ;)


ABOUT THE NAME
----------------

impress.js name in courtesy of @skuzniak (http://twitter.com/skuzniak/status/143627215165333504).

It's an (un)fortunate coincidence that a Open/LibreOffice presentation tool is called Impress ;)



DEMO
------
Expand All @@ -28,6 +36,10 @@ Impress.js is developed with current webkit-based browsers in mind (Chrome,
Safari), but *should* work also in other browsers supporting CSS3 3D transforms
and transitions (Firefox, IE10).

Additionally for the animations to run smoothly it's required to have hardware
acceleration support in your browser. This depends on the browser, your operating
system and even kind of graphic hardware you have in your machine.

It's actively developed with newest Chromium and tested in Firefox Aurora.

I don't really expect it to run smoothly in non-webkit-based browser.
Expand Down
9 changes: 9 additions & 0 deletions css/style.css
@@ -1,3 +1,12 @@
/**
* This is a stylesheet for a demo presentation for impress.js
*
* It is not meant to be a part of impress.js and is not required by impress.js.
* I expect that anyone creating a presentation for impress.js would create their own
* set of styles.
*/


/* http://meyerweb.com/eric/tools/css/reset/
v2.0 | 20110126
License: none (public domain)
Expand Down
5 changes: 4 additions & 1 deletion js/impress.js
Expand Up @@ -226,17 +226,19 @@
// EVENTS

document.addEventListener("keydown", function ( event ) {
if ( event.keyCode == 9 || event.keyCode == 32 || (event.keyCode >= 37 && event.keyCode <= 40) ) {
if ( event.keyCode == 9 || ( event.keyCode >= 32 && event.keyCode <= 34 ) || (event.keyCode >= 37 && event.keyCode <= 40) ) {
var active = $(".step.active", impress);
var next = active;
switch( event.keyCode ) {
case 33: ; // pg up
case 37: ; // left
case 38: // up
next = steps.indexOf( active ) - 1;
next = next >= 0 ? steps[ next ] : steps[ steps.length-1 ];
break;
case 9: ; // tab
case 32: ; // space
case 34: ; // pg down
case 39: ; // right
case 40: // down
next = steps.indexOf( active ) + 1;
Expand All @@ -249,6 +251,7 @@
event.preventDefault();
}
}, false);


// Sometimes it's possible to trigger focus on first link with some keyboard action.
// Browser in such a case tries to scroll the page to make this element visible
Expand Down

0 comments on commit 97e244e

Please sign in to comment.