mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-04 10:32:39 +08:00
Merge branch 'v1.9'
This commit is contained in:
@@ -174,7 +174,7 @@ Audio.State = {
|
||||
};
|
||||
|
||||
proto.resume = function () {
|
||||
if (!this._element || this._element.currentTime === 0) return;
|
||||
if (!this._element || this._state === Audio.State.PLAYING) return;
|
||||
this._bindEnded();
|
||||
this._element.play();
|
||||
this._state = Audio.State.PLAYING;
|
||||
|
||||
@@ -1246,8 +1246,8 @@ var ScrollView = cc.Class({
|
||||
this._autoScrolling = false;
|
||||
}
|
||||
|
||||
var contentPos = cc.pSub(newPosition, this.getContentPosition());
|
||||
this._moveContent(contentPos, reachedEnd);
|
||||
var deltaMove = cc.pSub(newPosition, this.getContentPosition());
|
||||
this._moveContent(this._clampDelta(deltaMove), reachedEnd);
|
||||
this._dispatchEvent('scrolling');
|
||||
|
||||
if (!this._autoScrolling) {
|
||||
@@ -1335,7 +1335,6 @@ var ScrollView = cc.Class({
|
||||
this._autoScrollBraking = true;
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
_calculateTouchMoveVelocity: function() {
|
||||
@@ -1366,7 +1365,6 @@ var ScrollView = cc.Class({
|
||||
|
||||
_moveContent: function(deltaMove, canStartBounceBack) {
|
||||
var adjustedMove = this._flattenVectorByDirection(deltaMove);
|
||||
|
||||
var newPosition = cc.pAdd(this.getContentPosition(), adjustedMove);
|
||||
|
||||
this.setContentPosition(newPosition);
|
||||
@@ -1377,10 +1375,8 @@ var ScrollView = cc.Class({
|
||||
if (this.elastic && canStartBounceBack) {
|
||||
this._startBounceBackIfNeeded();
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
|
||||
_getContentLeftBoundary: function() {
|
||||
var contentPos = this.getContentPosition();
|
||||
var leftBoundary = contentPos.x - this.content.getAnchorPoint().x * this.content.getContentSize().width;
|
||||
|
||||
@@ -643,7 +643,7 @@ else if (CC_WECHATGAME) {
|
||||
sys.osVersion = version[0];
|
||||
sys.osMainVersion = parseInt(sys.osVersion);
|
||||
// wechagame subdomain
|
||||
if (wx.getGroupCloudStorage && wx.getFriendCloudStorage) {
|
||||
if (!wx.getFileSystemManager) {
|
||||
sys.browserType = sys.BROWSER_TYPE_WECHAT_GAME_SUB;
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user