removeLabel: remove listeners before detaching.
This commit is contained in:
parent
da1ff18493
commit
d36b90ce40
|
@ -993,9 +993,9 @@ Element.prototype.setLabel = function(options) {
|
||||||
|
|
||||||
Element.prototype.removeLabel = function() {
|
Element.prototype.removeLabel = function() {
|
||||||
if (!this._label) return;
|
if (!this._label) return;
|
||||||
this._label.detach();
|
|
||||||
this.removeListener('scroll', this._labelScroll);
|
this.removeListener('scroll', this._labelScroll);
|
||||||
this.removeListener('resize', this._labelResize);
|
this.removeListener('resize', this._labelResize);
|
||||||
|
this._label.detach();
|
||||||
delete this._labelScroll;
|
delete this._labelScroll;
|
||||||
delete this._labelResize;
|
delete this._labelResize;
|
||||||
delete this._label;
|
delete this._label;
|
||||||
|
|
Loading…
Reference in New Issue