GNOME Bugzilla – Bug 709043
Wifi labeled as "off" when it should say "disconnected"
Last modified: 2013-10-09 16:41:21 UTC
When the wifi is enabled, but disconnected, the status label in the menu says "Off", which is particularly confusing because one of the labels when you open the subsection says "Turn off" (to actually disable the radio). This label should say "disconnected" or "not connected" instead.
This issue is also mentioned in bug 708967. I agree with the report - "off" and "not connected" are different states that need to be identified. The wireframes indicate that this state should be described as "Not Connected".
Created attachment 256289 [details] [review] Network: show Not Connected instead of Off when wifi radio is on When wifi is powered but not connected, show Not Connected instead of off. This avoids a Off status next to a Turn Off menu item.
Created attachment 256290 [details] [review] NetworkMenu/NMDeviceWireless: use the device state instead of active connection state Since we connect to signals for that, we need to sync on that, or we can miss a notification.
The same fix is needed for WWAN too, but I can't test it right now, because my bluetooth adapter stopped working.
Review of attachment 256290 [details] [review]: I don't understand this one.
Review of attachment 256289 [details] [review]: OK. ::: js/ui/status/network.js @@ +1056,3 @@ + return ssidToLabel(ap.get_ssid()); + else if (!this._client.wireless_hardware_enabled) + return _("Hardware disabled"); double-check on this string please. Caps is inconsistent with "Not Connected" below.
(In reply to comment #5) > Review of attachment 256290 [details] [review]: > > I don't understand this one. Oh it's simple: we connect to state-changed signal (which is the signal for NMDevice::state), but we use the state from the ActiveConnection. If the DBus signals are out of order, we never sync the UI properly and end up with a stuck connecting icon.
(In reply to comment #7) > Oh it's simple: we connect to state-changed signal (which is the signal for > NMDevice::state), but we use the state from the ActiveConnection. If the DBus > signals are out of order, we never sync the UI properly and end up with a stuck > connecting icon. We should connect to the notify::state signal on the ActiveConnection, then. (The connecting icon issue is a dbus-glib issue, and danw was looking into it)
(In reply to comment #8) > (In reply to comment #7) > > Oh it's simple: we connect to state-changed signal (which is the signal for > > NMDevice::state), but we use the state from the ActiveConnection. If the DBus > > signals are out of order, we never sync the UI properly and end up with a stuck > > connecting icon. > > We should connect to the notify::state signal on the ActiveConnection, then. Why? We use the device state everywhere else (See NMConnectionDevice._getStatus() etc.) > (The connecting icon issue is a dbus-glib issue, and danw was looking into it) Interesting, because changing the state variable fixed it here.
Created attachment 256360 [details] [review] Network: show Not Connected instead of Off when wifi radio is on When wifi is powered but not connected, show Not Connected instead of off. This avoids a Off status next to a Turn Off menu item.
Created attachment 256361 [details] [review] NetworkMenu/NMDeviceWireless: use the device state instead of active connection state Since we connect to signals for that, we need to sync on that, or we can miss a notification.
Created attachment 256362 [details] [review] NetworkMenu/NMConnectionDevice: grab the connection before using it If the active connection for the device is not the primary or activating globally, it won't have the _connection and _primaryDevice expando properties, so grab them from the settings object.
Created attachment 256363 [details] [review] Bluetooth: fix ngettext call
Created attachment 256364 [details] [review] NetworkMenu/NMConnectionDevice: fix status text Be consistent with v4 mockups
Created attachment 256365 [details] [review] NetworkMenu/NMDeviceModem: fix status texts for airplane mode Show "Hardware Disabled" when disabled by HW switch, and generically "Disabled" when airplane mode is active, as indicated by v4 mockups. Note that bluetooth is not affected by NM handling of airplane mode (and generally the firmware makes the USB bluetooth adapter disappear when rfkilled), so this is in NMDeviceModem instead of NMConnectionDevice.
Created attachment 256375 [details] [review] NetworkMenu/NMDeviceModem: fix status texts for airplane mode Show "Hardware Disabled" when disabled by HW switch, and generically "Disabled" when airplane mode is active, as indicated by v4 mockups. Note that bluetooth is not affected by NM handling of airplane mode (and generally the firmware makes the USB bluetooth adapter disappear when rfkilled), so this is in NMDeviceModem instead of NMConnectionDevice.
Created attachment 256376 [details] [review] NetworkMenu/NMDeviceModem: use the operator name when we have it Instead of the connection name, as the operator name is usually shorter and more useful.
Review of attachment 256360 [details] [review]: OK.
Review of attachment 256362 [details] [review]: ::: js/ui/status/network.js @@ +306,3 @@ + // This list is guaranteed to have only one device in it. + let device = a.get_devices()[0]._delegate; + a._primaryDevice = device; Can we have function ensureActiveConnectionProps(a, settings) {} so we don't duplicate code?
Review of attachment 256363 [details] [review]: OK.
Review of attachment 256364 [details] [review]: OK.
Review of attachment 256376 [details] [review]: Whoops. This was my fault.
Review of attachment 256361 [details] [review]: OK.
Review of attachment 256375 [details] [review]: Yep.
Pushing (with suggested changes) the patches that don't require string freeze approval. Attachment 256361 [details] pushed as 843f076 - NetworkMenu/NMDeviceWireless: use the device state instead of active connection state Attachment 256362 [details] pushed as e898e29 - NetworkMenu/NMConnectionDevice: grab the connection before using it Attachment 256363 [details] pushed as fdb732c - Bluetooth: fix ngettext call
*** Bug 709565 has been marked as a duplicate of this bug. ***
*** Bug 709639 has been marked as a duplicate of this bug. ***
Attachment 256360 [details] pushed as 6a154ef - Network: show Not Connected instead of Off when wifi radio is on Attachment 256364 [details] pushed as c79bdd9 - NetworkMenu/NMConnectionDevice: fix status text Attachment 256375 [details] pushed as 777c7a9 - NetworkMenu/NMDeviceModem: fix status texts for airplane mode Attachment 256376 [details] pushed as bde5cfc - NetworkMenu/NMDeviceModem: use the operator name when we have it