Merge pull request #1049 from zilongshanren/fix-issue-4026

fix outOfBoundary when scrollview size changed
This commit is contained in:
Wang Nan
2016-08-19 11:59:17 +08:00
committed by GitHub
+2
View File
@@ -813,6 +813,7 @@ var ScrollView = cc.Class({
}
this._moveContent(moveDelta);
this._adjustContentOutOfBoundary();
},
_calculateBoundary: function() {
@@ -1331,6 +1332,7 @@ var ScrollView = cc.Class({
var newPosition = cc.pAdd(this.getContentPosition(), outOfBoundary);
if(this.content) {
this.content.setPosition(newPosition);
this._updateScrollBar(0);
}
}
},