[gnome-shell/wip/aggregate-menu: 51/58] network: Remove superfluous intermediate section
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/aggregate-menu: 51/58] network: Remove superfluous intermediate section
- Date: Wed, 17 Jul 2013 19:00:31 +0000 (UTC)
commit 3b4d5e3c40285a095b1606b5a2c9d7e7d2b23d7f
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Fri Jun 7 13:23:57 2013 -0400
network: Remove superfluous intermediate section
Now that we're guaranteed this.menu is a section, this is
excessive and unnecessary.
js/ui/status/network.js | 13 +++++--------
1 files changed, 5 insertions(+), 8 deletions(-)
---
diff --git a/js/ui/status/network.js b/js/ui/status/network.js
index 4a0e3c3..61fdf7e 100644
--- a/js/ui/status/network.js
+++ b/js/ui/status/network.js
@@ -1120,25 +1120,22 @@ const NMApplet = new Lang.Class({
this._nmDevices = [];
this._devices = { };
- this._section = new PopupMenu.PopupMenuSection();
- this.menu.addMenuItem(this._section);
-
this._devices.wireless = {
section: new PopupMenu.PopupMenuSection(),
devices: [ ],
};
- this._section.addMenuItem(this._devices.wireless.section);
+ this.menu.addMenuItem(this._devices.wireless.section);
this._devices.wwan = {
section: new PopupMenu.PopupMenuSection(),
devices: [ ],
};
- this._section.addMenuItem(this._devices.wwan.section);
+ this.menu.addMenuItem(this._devices.wwan.section);
this._vpnSection = new NMVPNSection(this._client);
this._vpnSection.connect('activation-failed', Lang.bind(this, this._onActivationFailed));
this._vpnSection.connect('icon-changed', Lang.bind(this, this._updateIcon));
- this._section.addMenuItem(this._vpnSection.item);
+ this.menu.addMenuItem(this._vpnSection.item);
this._readDevices();
this._syncNMState();
@@ -1157,7 +1154,7 @@ const NMApplet = new Lang.Class({
_sessionUpdated: function() {
let sensitive = !Main.sessionMode.isLocked && !Main.sessionMode.isGreeter;
- this._section.setSensitive(sensitive);
+ this.menu.setSensitive(sensitive);
},
_ensureSource: function() {
@@ -1479,7 +1476,7 @@ const NMApplet = new Lang.Class({
this._syncActiveConnections();
this.indicators.visible = this._client.manager_running;
- this._section.actor.visible = this._client.networking_enabled;
+ this.menu.actor.visible = this._client.networking_enabled;
},
_updateIcon: function() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]