summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2010-11-09 11:45:41 +0100
committerHans de Goede <hdegoede@redhat.com>2010-11-09 13:03:58 +0100
commitc278cfa88c22b9426ac4a37847f69318c2b1de20 (patch)
treea123a90bdbf4d9a80edcb3f22fd72b3389032a37
parentcec1d980293308fd25e3600cd44eceb208442172 (diff)
downloadspice-c278cfa88c22b9426ac4a37847f69318c2b1de20.tar.gz
spice-c278cfa88c22b9426ac4a37847f69318c2b1de20.tar.xz
spice-c278cfa88c22b9426ac4a37847f69318c2b1de20.zip
spicec: Don't show gui when connection info is specified on the cmdline
Currently when compiled with the gui enabled if you specify a host to connect to on the cmdline the gui flashes by (show_gui gets called, then the connect handler calls hide_gui as soon as the connection is made). This patch removes this ugly flashing by of the gui.
-rw-r--r--client/application.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/client/application.cpp b/client/application.cpp
index 27016411..4b22e1f1 100644
--- a/client/application.cpp
+++ b/client/application.cpp
@@ -602,14 +602,12 @@ void Application::on_start_running()
}
//FIXME: _client.connect() or use the following instead?
#ifdef USE_GUI
- if (_gui_mode != GUI_MODE_FULL) {
- connect();
+ if (_gui_mode == GUI_MODE_FULL) {
+ show_gui();
+ return;
}
-
- show_gui();
-#else
- connect();
#endif // HAVE_GUI
+ connect();
}
RedScreen* Application::find_screen(int id)