From 65067c24cc7207cbdb32b5091da536a247193fcd Mon Sep 17 00:00:00 2001 From: "Jasper St. Pierre" Date: Wed, 6 Mar 2013 18:01:12 -0500 Subject: [PATCH] main: Show the greeter dialog when we're prepared If we don't wait until the stage is mapped, pushing a modal will fail with an X error. https://bugzilla.gnome.org/show_bug.cgi?id=694321 --- js/ui/main.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/js/ui/main.js b/js/ui/main.js index f727a661b..b0a8c2d34 100644 --- a/js/ui/main.js +++ b/js/ui/main.js @@ -84,8 +84,6 @@ function _sessionUpdated() { Shell.KeyBindingMode.NORMAL | Shell.KeyBindingMode.OVERVIEW, sessionMode.hasRunDialog ? openRunDialog : null); - if (sessionMode.isGreeter && screenShield) - screenShield.showDialog(); } function start() { @@ -191,6 +189,12 @@ function _initializeUI() { ExtensionDownloader.init(); ExtensionSystem.init(); + if (sessionMode.isGreeter && screenShield) { + layoutManager.connect('startup-prepared', function() { + screenShield.showDialog(); + }); + } + layoutManager.connect('startup-complete', function() { if (keybindingMode == Shell.KeyBindingMode.NONE) { keybindingMode = Shell.KeyBindingMode.NORMAL;