diff options
author | Mark Longair <mhl@pobox.com> | 2013-09-26 10:50:12 +0100 |
---|---|---|
committer | Mark Longair <mhl@pobox.com> | 2013-11-19 17:31:35 +0000 |
commit | 7e5fe3d27f1921841f45b46dc508af133403c1f0 (patch) | |
tree | 02f7bf9fdea41be4ead92efed80b7d95e2d72c7c /app/assets/javascripts/ba-throttle-debounce.js | |
parent | aa83f5741d9276356454f3eb869b2834246e0635 (diff) |
Switch Javascript (bar admin) to be served with the asset pipline
Diffstat (limited to 'app/assets/javascripts/ba-throttle-debounce.js')
-rw-r--r-- | app/assets/javascripts/ba-throttle-debounce.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/assets/javascripts/ba-throttle-debounce.js b/app/assets/javascripts/ba-throttle-debounce.js new file mode 100644 index 000000000..07205508e --- /dev/null +++ b/app/assets/javascripts/ba-throttle-debounce.js @@ -0,0 +1,9 @@ +/* + * jQuery throttle / debounce - v1.1 - 3/7/2010 + * http://benalman.com/projects/jquery-throttle-debounce-plugin/ + * + * Copyright (c) 2010 "Cowboy" Ben Alman + * Dual licensed under the MIT and GPL licenses. + * http://benalman.com/about/license/ + */ +(function(b,c){var $=b.jQuery||b.Cowboy||(b.Cowboy={}),a;$.throttle=a=function(e,f,j,i){var h,d=0;if(typeof f!=="boolean"){i=j;j=f;f=c}function g(){var o=this,m=+new Date()-d,n=arguments;function l(){d=+new Date();j.apply(o,n)}function k(){h=c}if(i&&!h){l()}h&&clearTimeout(h);if(i===c&&m>e){l()}else{if(f!==true){h=setTimeout(i?k:l,i===c?e-m:e)}}}if($.guid){g.guid=j.guid=j.guid||$.guid++}return g};$.debounce=function(d,e,f){return f===c?a(d,e,false):a(d,f,e!==false)}})(this);
\ No newline at end of file |