app/assets/javascripts/pageflow/slideshow/scroller_widget.js in pageflow-0.11.4 vs app/assets/javascripts/pageflow/slideshow/scroller_widget.js in pageflow-12.0.0.rc1

- old
+ new

@@ -2,10 +2,11 @@ (function($) { /** * Wrapper widget around iScroll adding special bump events which * are triggered when scrolling to the very top or very bottom * (called boundary posititon below). + * @private */ $.widget('pageflow.scroller', { dragThreshold: 50, maxXDelta: 50, doubleBumpThreshold: 500, @@ -155,17 +156,15 @@ else { this._trigger('notneartop'); } }, - /** - * Whenever the a mousewheel event is triggered, we test whether - * the scroller is at the very top or at the very bottom. If so, - * we trigger a hintdown or hintup event the first time the mouse - * wheel turns and a bumpup or bumpdown event when the mouse wheel - * is turned to times in a short period of time. - */ + // Whenever the a mousewheel event is triggered, we test whether + // the scroller is at the very top or at the very bottom. If so, + // we trigger a hintdown or hintup event the first time the mouse + // wheel turns and a bumpup or bumpdown event when the mouse wheel + // is turned to times in a short period of time. _initMousewheelBump: function(direction) { var firstBump = false; this.iscroll.on('mousewheel' + direction, _.bind(function() { if (!this._atBoundary(direction)) { @@ -187,14 +186,12 @@ }, this.doubleBumpThreshold); } }, this)); }, - /** - * Trigger bumpup or bumpdown event when the a up/down key is - * pressed while the scroller in boundary position. - */ + // Trigger bumpup or bumpdown event when the a up/down key is + // pressed while the scroller in boundary position. _initKeyboardBump: function(direction) { this.iscroll.on('keyboard' + direction, _.bind(function(event) { if (this._atBoundary(direction)) { // Make sure other iScrolls which might be enabled by the // bump event do not process the keyboard event again. @@ -208,14 +205,12 @@ this._trigger('hint' + direction); } }, this)); }, - /** - * Trigger bumpup or bumpdown when the user drags the page from a - * boundary position. - */ + // Trigger bumpup or bumpdown when the user drags the page from a + // boundary position. _initDragGestureBump: function() { var allowUp = false, allowDown = false, startX, startY; @@ -263,12 +258,10 @@ event.originalEvent.pointerType !== event.originalEvent.MSPOINTER_TYPE_TOUCH && event.originalEvent.pointerType !== 'touch'; } }, - /** - * Checks whether the scroller is at the very top or very bottom. - */ + // Checks whether the scroller is at the very top or very bottom. _atBoundary: function(direction, options) { options = options || {}; var delta = options.delta || 0; if (direction === 'up') { \ No newline at end of file