xrandr-indicator: stop processing RandR events when disabled

It's hard to tell people to disconnect their signals, when we
are the first to forget it...
This commit is contained in:
Giovanni Campagna
2013-06-06 23:32:53 +02:00
committed by Giovanni Campagna
parent ef91d9802c
commit 087a9208cf
+7
View File
@@ -64,6 +64,13 @@ const Indicator = new Lang.Class({
this._screen.connect('changed', Lang.bind(this, this._randrEvent));
},
destroy: function() [
if (this._screen)
this._screen.run_dispose();
this.parent();
},
_randrEvent: function() {
this.menu.removeAll();
this._createMenu();