[Spice-devel] [PATCH spice] Make the gui use Application::hide_gui rather then hide_me
Hans de Goede
hdegoede at redhat.com
Mon Oct 18 05:47:17 PDT 2010
Now that Application::hide_me actually does what the name suggests
(hide the entire client, ie all client windows), the gui using it to
not show the gui layer leads to the entire client disappearing when
one presses close in the GUI or dismisses a GUI dialog. This patch makes
the GUI code call hide_gui instead of hide_me, fixing this.
---
client/application.cpp | 2 --
client/application.h | 2 +-
client/gui/gui.cpp | 4 ++--
3 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/client/application.cpp b/client/application.cpp
index 15916f7..212b20e 100644
--- a/client/application.cpp
+++ b/client/application.cpp
@@ -1786,8 +1786,6 @@ void Application::show_me(bool full_screen)
void Application::hide_me()
{
-// hide_gui();
-// FIXME: this instead?
if (_full_screen) {
exit_full_screen();
}
diff --git a/client/application.h b/client/application.h
index 2cff2d5..c01e08b 100644
--- a/client/application.h
+++ b/client/application.h
@@ -254,6 +254,7 @@ public:
#ifdef USE_GUI
bool is_disconnect_allowed();
+ void hide_gui();
#endif
const std::string& get_host();
@@ -318,7 +319,6 @@ private:
void attach_gui_barriers();
void detach_gui_barriers();
void show_gui();
- void hide_gui();
void create_gui_barrier(RedScreen& screen, int id);
void destroyed_gui_barrier(int id);
void destroyed_gui_barriers();
diff --git a/client/gui/gui.cpp b/client/gui/gui.cpp
index 9152ff1..f1ca13d 100644
--- a/client/gui/gui.cpp
+++ b/client/gui/gui.cpp
@@ -420,7 +420,7 @@ void GUI::Dialog::handle_message_click(int id)
}
if (_close_on_message_click) {
- application().hide_me();
+ application().hide_gui();
}
}
@@ -840,7 +840,7 @@ public:
bool SettingsDialog::handle_close(const CEGUI::EventArgs& e)
{
DBG(0, "");
- application().hide_me();
+ application().hide_gui();
return true;
}
--
1.7.3.1
More information about the Spice-devel
mailing list