[gnome-shell] network: Make sure to set the signal icon at dialog item construction time
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] network: Make sure to set the signal icon at dialog item construction time
- Date: Thu, 26 Sep 2013 17:38:41 +0000 (UTC)
commit fb561f10a7040ea682ad648e8687b8295f366854
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Fri Sep 20 12:50:36 2013 -0400
network: Make sure to set the signal icon at dialog item construction time
We forgot to set it here; it would be updated if there was changes in the
signal, but not when it was created.
https://bugzilla.gnome.org/show_bug.cgi?id=708442
js/ui/status/network.js | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/js/ui/status/network.js b/js/ui/status/network.js
index b7e6bf9..90399d4 100644
--- a/js/ui/status/network.js
+++ b/js/ui/status/network.js
@@ -547,18 +547,24 @@ const NMWirelessDialogItem = new Lang.Class({
this._signalIcon = new St.Icon({ style_class: 'nm-dialog-icon' });
this._icons.add_actor(this._signalIcon);
+
+ this._sync();
+ },
+
+ _sync: function() {
+ this._signalIcon.icon_name = this._getSignalIcon();
},
updateBestAP: function(ap) {
this._ap = ap;
- this._signalIcon.icon_name = this._getIcon();
+ this._sync();
},
setActive: function(isActive) {
this._selectedIcon.opacity = isActive ? 255 : 0;
},
- _getIcon: function() {
+ _getSignalIcon: function() {
if (this._ap.mode == NM80211Mode.ADHOC)
return 'network-workgroup-symbolic';
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]