tweetcast/nodejs/client/js/jquery.mousewheel.min.js
author Raphael Velt <raph.velt@gmail.com>
Mon, 24 Oct 2011 18:01:55 +0200
changeset 331 03c69425efa6
permissions -rw-r--r--
Added SQLite Database in Node Server
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
331
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     1
/* Copyright (c) 2009 Brandon Aaron (http://brandonaaron.net)
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     2
 * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     3
 * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     4
 * Thanks to: http://adomas.org/javascript-mouse-wheel/ for some pointers.
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     5
 * Thanks to: Mathias Bank(http://www.mathias-bank.de) for a scope bug fix.
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     6
 *
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     7
 * Version: 3.0.2
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     8
 * 
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
     9
 * Requires: 1.2.2+
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
    10
 */
03c69425efa6 Added SQLite Database in Node Server
Raphael Velt <raph.velt@gmail.com>
parents:
diff changeset
    11
(function(c){var a=["DOMMouseScroll","mousewheel"];c.event.special.mousewheel={setup:function(){if(this.addEventListener){for(var d=a.length;d;){this.addEventListener(a[--d],b,false)}}else{this.onmousewheel=b}},teardown:function(){if(this.removeEventListener){for(var d=a.length;d;){this.removeEventListener(a[--d],b,false)}}else{this.onmousewheel=null}}};c.fn.extend({mousewheel:function(d){return d?this.bind("mousewheel",d):this.trigger("mousewheel")},unmousewheel:function(d){return this.unbind("mousewheel",d)}});function b(f){var d=[].slice.call(arguments,1),g=0,e=true;f=c.event.fix(f||window.event);f.type="mousewheel";if(f.wheelDelta){g=f.wheelDelta/120}if(f.detail){g=-f.detail/3}d.unshift(f,g);return c.event.handle.apply(this,d)}})(jQuery);