mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 11:17:19 +08:00
fix(gesture): destroy gesture handler when it's done (#17184)
fixes #16433 fixes #16974
This commit is contained in:
@ -118,6 +118,13 @@ export class Toggle implements ComponentInterface {
|
||||
this.disabledChanged();
|
||||
}
|
||||
|
||||
componentDidUnload() {
|
||||
if (this.gesture) {
|
||||
this.gesture.destroy();
|
||||
this.gesture = undefined;
|
||||
}
|
||||
}
|
||||
|
||||
@Listen('click')
|
||||
onClick() {
|
||||
if (this.lastDrag + 300 < Date.now()) {
|
||||
|
Reference in New Issue
Block a user