Skip to content

Commit

Permalink
Build scrollview
Browse files Browse the repository at this point in the history
  • Loading branch information
derek committed Sep 10, 2012
1 parent 05e32fa commit eec0e8e
Show file tree
Hide file tree
Showing 4 changed files with 102 additions and 92 deletions.
174 changes: 89 additions & 85 deletions build/scrollview-base/scrollview-base-coverage.js

Large diffs are not rendered by default.

9 changes: 6 additions & 3 deletions build/scrollview-base/scrollview-base-debug.js
Expand Up @@ -306,7 +306,7 @@ Y.ScrollView = Y.extend(ScrollView, Y.Widget, {


sv._set(AXIS, sv._cAxis); sv._set(AXIS, sv._cAxis);
} }

// get text direction on or inherited by scrollview node // get text direction on or inherited by scrollview node
sv.rtl = (sv._cb.getComputedStyle('direction') === 'rtl'); sv.rtl = (sv._cb.getComputedStyle('direction') === 'rtl');


Expand Down Expand Up @@ -745,15 +745,18 @@ Y.ScrollView = Y.extend(ScrollView, Y.Widget, {
} }


var sv = this, var sv = this,
gesture = sv._gesture,
svAxis = sv._cAxis, svAxis = sv._cAxis,
flick = e.flick, flick = e.flick,
flickAxis = flick.axis, flickAxis = flick.axis,
flickVelocity = flick.velocity, flickVelocity = flick.velocity,
axisAttr = flickAxis === DIM_X ? SCROLL_X : SCROLL_Y, axisAttr = flickAxis === DIM_X ? SCROLL_X : SCROLL_Y,
startPosition = sv.get(axisAttr); startPosition = sv.get(axisAttr);


gesture.flick = flick; // Sometimes flick is enabled, but drag is disabled
if (sv._gesture) {
sv._gesture.flick = flick;
}

// Prevent unneccesary firing of _flickFrame if we can't scroll on the flick axis // Prevent unneccesary firing of _flickFrame if we can't scroll on the flick axis
if (svAxis[flickAxis]) { if (svAxis[flickAxis]) {
sv._flickFrame(flickVelocity, flickAxis, startPosition); sv._flickFrame(flickVelocity, flickAxis, startPosition);
Expand Down
2 changes: 1 addition & 1 deletion build/scrollview-base/scrollview-base-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions build/scrollview-base/scrollview-base.js
Expand Up @@ -306,7 +306,7 @@ Y.ScrollView = Y.extend(ScrollView, Y.Widget, {


sv._set(AXIS, sv._cAxis); sv._set(AXIS, sv._cAxis);
} }

// get text direction on or inherited by scrollview node // get text direction on or inherited by scrollview node
sv.rtl = (sv._cb.getComputedStyle('direction') === 'rtl'); sv.rtl = (sv._cb.getComputedStyle('direction') === 'rtl');


Expand Down Expand Up @@ -745,15 +745,18 @@ Y.ScrollView = Y.extend(ScrollView, Y.Widget, {
} }


var sv = this, var sv = this,
gesture = sv._gesture,
svAxis = sv._cAxis, svAxis = sv._cAxis,
flick = e.flick, flick = e.flick,
flickAxis = flick.axis, flickAxis = flick.axis,
flickVelocity = flick.velocity, flickVelocity = flick.velocity,
axisAttr = flickAxis === DIM_X ? SCROLL_X : SCROLL_Y, axisAttr = flickAxis === DIM_X ? SCROLL_X : SCROLL_Y,
startPosition = sv.get(axisAttr); startPosition = sv.get(axisAttr);


gesture.flick = flick; // Sometimes flick is enabled, but drag is disabled
if (sv._gesture) {
sv._gesture.flick = flick;
}

// Prevent unneccesary firing of _flickFrame if we can't scroll on the flick axis // Prevent unneccesary firing of _flickFrame if we can't scroll on the flick axis
if (svAxis[flickAxis]) { if (svAxis[flickAxis]) {
sv._flickFrame(flickVelocity, flickAxis, startPosition); sv._flickFrame(flickVelocity, flickAxis, startPosition);
Expand Down

0 comments on commit eec0e8e

Please sign in to comment.