mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-17 04:41:36 +08:00
Merge pull request #2598 from NativeScript/raikov/fix-button-unload
Fixed: There is an exception when removing a button
This commit is contained in:
@ -69,6 +69,13 @@ export class Button extends common.Button {
|
||||
this.style._updateTextTransform();
|
||||
}
|
||||
|
||||
public onUnloaded() {
|
||||
super.onUnloaded();
|
||||
if (this._stateChangedHandler) {
|
||||
this._stateChangedHandler.stop();
|
||||
}
|
||||
}
|
||||
|
||||
@PseudoClassHandler("normal", "highlighted")
|
||||
_updateHandler(subscribe: boolean) {
|
||||
if (subscribe) {
|
||||
|
Reference in New Issue
Block a user