removeLabel: remove listeners before detaching.

This commit is contained in:
Christopher Jeffrey 2015-05-07 18:54:07 -07:00
parent da1ff18493
commit d36b90ce40
1 changed files with 1 additions and 1 deletions

View File

@ -993,9 +993,9 @@ Element.prototype.setLabel = function(options) {
Element.prototype.removeLabel = function() {
if (!this._label) return;
this._label.detach();
this.removeListener('scroll', this._labelScroll);
this.removeListener('resize', this._labelResize);
this._label.detach();
delete this._labelScroll;
delete this._labelResize;
delete this._label;