]> git.saurik.com Git - wxWidgets.git/commitdiff
added wxCLOSE and fixed wxSYSTEM_MENU on Unix
authorVáclav Slavík <vslavik@fastmail.fm>
Wed, 26 Feb 2003 19:24:19 +0000 (19:24 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Wed, 26 Feb 2003 19:24:19 +0000 (19:24 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19338 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/changes.txt
src/gtk/toplevel.cpp
src/gtk1/toplevel.cpp
src/x11/toplevel.cpp

index 1559d0eaaa27b7c03f94cff01db6bd5d46e82bf7..eb953092e0b49a009d14ee5f7745edecedd2e477 100644 (file)
@@ -13,6 +13,7 @@ OTHER CHANGES
 
 All:
 
+- added wxCLOSE style for dialogs and frames
 - added wxDateSpan::operator==() and !=() (Lukasz Michalski)
 - use true/false throughout the library instead of TRUE/FALSE
 - wxStopWatch::Start() resumes the stop watch if paused, as per the docs
index 1e76307895e2dd2c2b7374f1804915af721d077f..1a2e7c1adf0c281ab18678f37d465f9d3add3be2 100644 (file)
@@ -456,10 +456,15 @@ bool wxTopLevelWindowGTK::Create( wxWindow *parent,
         // All this is for Motif Window Manager "hints" and is supposed to be
         // recognized by other WMs as well.
         if ((style & wxCAPTION) != 0)
+        {
             m_gdkDecor |= GDK_DECOR_TITLE;
-        if ((style & wxSYSTEM_MENU) != 0)
+        }
+        if ((style & wxCLOSE) != 0)
         {
             m_gdkFunc |= GDK_FUNC_CLOSE;
+        }
+        if ((style & wxSYSTEM_MENU) != 0)
+        {
             m_gdkDecor |= GDK_DECOR_MENU;
         }
         if ((style & wxMINIMIZE_BOX) != 0)
index 1e76307895e2dd2c2b7374f1804915af721d077f..1a2e7c1adf0c281ab18678f37d465f9d3add3be2 100644 (file)
@@ -456,10 +456,15 @@ bool wxTopLevelWindowGTK::Create( wxWindow *parent,
         // All this is for Motif Window Manager "hints" and is supposed to be
         // recognized by other WMs as well.
         if ((style & wxCAPTION) != 0)
+        {
             m_gdkDecor |= GDK_DECOR_TITLE;
-        if ((style & wxSYSTEM_MENU) != 0)
+        }
+        if ((style & wxCLOSE) != 0)
         {
             m_gdkFunc |= GDK_FUNC_CLOSE;
+        }
+        if ((style & wxSYSTEM_MENU) != 0)
+        {
             m_gdkDecor |= GDK_DECOR_MENU;
         }
         if ((style & wxMINIMIZE_BOX) != 0)
index fdcf28a869b83167d53d98f2f4c9f24e19ec35ef..84ce7c9694651f95a0c630fb591a723d03b46837 100644 (file)
@@ -677,7 +677,7 @@ bool wxSetWMDecorations(Window w, long style)
         wmProp.flags |= GR_WM_FLAGS_PROPS ;
     }
 
-    if (style & wxSYSTEM_MENU)
+    if (style & wxCLOSE)
     {
         wmProp.props |= GR_WM_PROPS_CLOSEBOX ;
         wmProp.flags |= GR_WM_FLAGS_PROPS ;
@@ -751,10 +751,10 @@ bool wxSetWMDecorations(Window w, long style)
             hints.decorations |= MWM_DECOR_TITLE;
             
         if ((style & wxSYSTEM_MENU) != 0)
-        {
-            hints.functions |= MWM_FUNC_CLOSE;
             hints.decorations |= MWM_DECOR_MENU;
-        }
+        
+        if ((style & wxCLOSE) != 0)
+            hints.functions |= MWM_FUNC_CLOSE;
         
         if ((style & wxMINIMIZE_BOX) != 0)
         {