mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-21 16:12:40 +08:00
Merge pull request #2428 from fusijie/fixed_rename_handler
rename private handler.
This commit is contained in:
@@ -60,7 +60,7 @@ let PrivateNode = cc.Class({
|
||||
this.zIndex = cc.macro.MIN_ZINDEX;
|
||||
},
|
||||
|
||||
_anchorChangedHandler () {
|
||||
_onAnchorChangedHandler () {
|
||||
this._localMatDirty = true;
|
||||
},
|
||||
|
||||
@@ -98,10 +98,10 @@ let PrivateNode = cc.Class({
|
||||
this._super(value);
|
||||
if (oldParent !== value) {
|
||||
if (oldParent) {
|
||||
oldParent.off(ANCHOR_CHANGED, this._anchorChangedHandler, this);
|
||||
oldParent.off(ANCHOR_CHANGED, this._onAnchorChangedHandler, this);
|
||||
}
|
||||
if (value) {
|
||||
value.on(ANCHOR_CHANGED, this._anchorChangedHandler, this);
|
||||
value.on(ANCHOR_CHANGED, this._onAnchorChangedHandler, this);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user