Blame SOURCES/0001-network-Close-Wifi-selection-dialog-when-appropriate.patch

f3cbb9
From 465e059a0c8a68301f8071a1cc14c817d2337012 Mon Sep 17 00:00:00 2001
f3cbb9
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
f3cbb9
Date: Tue, 14 Mar 2017 20:32:50 +0100
f3cbb9
Subject: [PATCH] network: Close Wifi selection dialog when appropriate
f3cbb9
f3cbb9
Currently when the wifi selection dialog is open when the screen lock is
f3cbb9
activated, the dialog remains visible above the shield. This is clearly
f3cbb9
broken, so close the dialog automatically on session mode changes if the
f3cbb9
mode doesn't allow settings (as changing the access point is arguably a
f3cbb9
user setting).
f3cbb9
f3cbb9
https://bugzilla.gnome.org/show_bug.cgi?id=780054
f3cbb9
---
f3cbb9
 js/ui/status/network.js | 8 ++++++++
f3cbb9
 1 file changed, 8 insertions(+)
f3cbb9
f3cbb9
diff --git a/js/ui/status/network.js b/js/ui/status/network.js
f3cbb9
index 11ca16014..842f6be6a 100644
f3cbb9
--- a/js/ui/status/network.js
f3cbb9
+++ b/js/ui/status/network.js
f3cbb9
@@ -769,6 +769,14 @@ const NMWirelessDialog = new Lang.Class({
f3cbb9
         this._scanTimeoutId = Mainloop.timeout_add_seconds(15, Lang.bind(this, this._onScanTimeout));
f3cbb9
         GLib.Source.set_name_by_id(this._scanTimeoutId, '[gnome-shell] this._onScanTimeout');
f3cbb9
         this._onScanTimeout();
f3cbb9
+
f3cbb9
+        let id = Main.sessionMode.connect('updated', () => {
f3cbb9
+            if (Main.sessionMode.allowSettings)
f3cbb9
+                return;
f3cbb9
+
f3cbb9
+            Main.sessionMode.disconnect(id);
f3cbb9
+            this.close();
f3cbb9
+        });
f3cbb9
     },
f3cbb9
 
f3cbb9
     destroy: function() {
f3cbb9
-- 
f3cbb9
2.12.0
f3cbb9