mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 20:33:32 +08:00
chore(animation): clearAsync on destroy, reset tmr each clear
This commit is contained in:
@ -56,8 +56,6 @@ export class Animation {
|
|||||||
this._pFns = [];
|
this._pFns = [];
|
||||||
this._fFns = [];
|
this._fFns = [];
|
||||||
this._fOnceFns = [];
|
this._fOnceFns = [];
|
||||||
|
|
||||||
this._clearAsync();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
element(ele: any): Animation {
|
element(ele: any): Animation {
|
||||||
@ -381,6 +379,7 @@ export class Animation {
|
|||||||
if (this._tmr) {
|
if (this._tmr) {
|
||||||
this._unregTrans && this._unregTrans();
|
this._unregTrans && this._unregTrans();
|
||||||
clearTimeout(this._tmr);
|
clearTimeout(this._tmr);
|
||||||
|
this._tmr = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -722,6 +721,7 @@ export class Animation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this._clearAsync();
|
||||||
this._reset();
|
this._reset();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@ export class Gesture {
|
|||||||
this._options = opts;
|
this._options = opts;
|
||||||
}
|
}
|
||||||
|
|
||||||
options(opts = {}) {
|
options(opts: any) {
|
||||||
assign(this._options, opts);
|
assign(this._options, opts);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user