messageTray: Remove dead code
The "clearable" concept is no longer relevant with the new design, not to mention that resident sources are no longer a thing either ...
This commit is contained in:
parent
6660342d2f
commit
0141a2be9e
@ -753,10 +753,6 @@ const Source = new Lang.Class({
|
|||||||
return this.count > 1;
|
return this.count > 1;
|
||||||
},
|
},
|
||||||
|
|
||||||
get isClearable() {
|
|
||||||
return !this.isChat && !this.resident;
|
|
||||||
},
|
|
||||||
|
|
||||||
countUpdated: function() {
|
countUpdated: function() {
|
||||||
this.emit('count-updated');
|
this.emit('count-updated');
|
||||||
},
|
},
|
||||||
@ -929,8 +925,6 @@ const MessageTray = new Lang.Class({
|
|||||||
this._notificationTimeoutId = 0;
|
this._notificationTimeoutId = 0;
|
||||||
this._notificationRemoved = false;
|
this._notificationRemoved = false;
|
||||||
|
|
||||||
this.clearableCount = 0;
|
|
||||||
|
|
||||||
Main.layoutManager.addChrome(this.actor, { affectsInputRegion: false });
|
Main.layoutManager.addChrome(this.actor, { affectsInputRegion: false });
|
||||||
Main.layoutManager.trackChrome(this._bannerBin, { affectsInputRegion: true });
|
Main.layoutManager.trackChrome(this._bannerBin, { affectsInputRegion: true });
|
||||||
|
|
||||||
@ -1031,9 +1025,6 @@ const MessageTray = new Lang.Class({
|
|||||||
destroyId: 0,
|
destroyId: 0,
|
||||||
};
|
};
|
||||||
|
|
||||||
if (source.isClearable)
|
|
||||||
this.clearableCount++;
|
|
||||||
|
|
||||||
this._sources.set(source, obj);
|
this._sources.set(source, obj);
|
||||||
|
|
||||||
obj.notifyId = source.connect('notify', Lang.bind(this, this._onNotify));
|
obj.notifyId = source.connect('notify', Lang.bind(this, this._onNotify));
|
||||||
@ -1046,9 +1037,6 @@ const MessageTray = new Lang.Class({
|
|||||||
let obj = this._sources.get(source);
|
let obj = this._sources.get(source);
|
||||||
this._sources.delete(source);
|
this._sources.delete(source);
|
||||||
|
|
||||||
if (source.isClearable)
|
|
||||||
this.clearableCount--;
|
|
||||||
|
|
||||||
source.disconnect(obj.notifyId);
|
source.disconnect(obj.notifyId);
|
||||||
source.disconnect(obj.destroyId);
|
source.disconnect(obj.destroyId);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user