From 5503a51cac96518f384565baea2bb271866dbf6d Mon Sep 17 00:00:00 2001 From: Mart Raudsepp Date: Mon, 5 Jun 2006 17:57:37 +0000 Subject: [PATCH] Do not set the wmclass for toplevels. This MUST be unique across the application, and GTK takes care of it for us - don't screw it over. Change it to set_role instead, but #if 0 out for now until some discussion about potential affect of this to existing applications. Toplevels that have a role set can be handled by the window manager, and store the positiong and size for them, and restore it on later occasion. If apps do stupid things like don't have unique motif names set for different toplevels, then this can cause problems with backwards compatibility. I am in favor of doing set_role, but it needs a little discussion and testing. Setting WM_CLASS is definately wrong, so just get rid of that till then. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39571 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/gtk/toplevel.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gtk/toplevel.cpp b/src/gtk/toplevel.cpp index b425e1c119..a60402b336 100644 --- a/src/gtk/toplevel.cpp +++ b/src/gtk/toplevel.cpp @@ -556,8 +556,10 @@ bool wxTopLevelWindowGTK::Create( wxWindow *parent, } #endif +#if 0 if (!name.empty()) - gtk_window_set_wmclass( GTK_WINDOW(m_widget), wxGTK_CONV( name ), wxGTK_CONV( name ) ); + gtk_window_set_role( GTK_WINDOW(m_widget), wxGTK_CONV( name ) ); +#endif gtk_window_set_title( GTK_WINDOW(m_widget), wxGTK_CONV( title ) ); GTK_WIDGET_UNSET_FLAGS( m_widget, GTK_CAN_FOCUS );