Bug 478607 - Download manager should support three finger swipe up/down on Mac OS X. r=enndeakin

This commit is contained in:
Edward Lee 2009-02-20 17:16:04 -06:00
parent 4710dc3be6
commit 0eed40a42d

View File

@ -467,6 +467,24 @@
}
]]>
</handler>
<handler event="MozSwipeGesture">
<![CDATA[
// Figure out where to scroll to
let targetHeight = 0;
let scrollBox = document.getAnonymousElementByAttribute(this, "anonid", "main-box");
// Only handle swipe gestures up and down
switch (event.direction) {
case event.DIRECTION_DOWN:
targetHeight = scrollBox.scrollHeight;
// Fall through for actual action
case event.DIRECTION_UP:
scrollBox.scrollTop = targetHeight;
break;
}
]]>
</handler>
</handlers>
</binding>