]> git.saurik.com Git - wxWidgets.git/commitdiff
set transiency relation so that the WM can do better job of positioning the window
authorVáclav Slavík <vslavik@fastmail.fm>
Fri, 4 Jun 2004 11:40:06 +0000 (11:40 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Fri, 4 Jun 2004 11:40:06 +0000 (11:40 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27620 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk/msgdlg.cpp
src/gtk1/msgdlg.cpp

index 97ce07c6166d9c1b14d82e8b47eb943dd312c5c4..250c8798815107889fe90de3b8b66e3fd722e6ff 100644 (file)
@@ -89,6 +89,10 @@ wxMessageDialog::wxMessageDialog(wxWindow *parent,
         else
             gtk_dialog_set_default_response(GTK_DIALOG(m_widget), GTK_RESPONSE_YES);
     }
+
+    if (parent)
+        gtk_window_set_transient_for(GTK_WINDOW(m_widget),
+                                     GTK_WINDOW(m_parent->m_widget));
 }
  
 int wxMessageDialog::ShowModal()
index 97ce07c6166d9c1b14d82e8b47eb943dd312c5c4..250c8798815107889fe90de3b8b66e3fd722e6ff 100644 (file)
@@ -89,6 +89,10 @@ wxMessageDialog::wxMessageDialog(wxWindow *parent,
         else
             gtk_dialog_set_default_response(GTK_DIALOG(m_widget), GTK_RESPONSE_YES);
     }
+
+    if (parent)
+        gtk_window_set_transient_for(GTK_WINDOW(m_widget),
+                                     GTK_WINDOW(m_parent->m_widget));
 }
  
 int wxMessageDialog::ShowModal()