Implement wxSTAY_ON_TOP for wxMessageDialog in wxGTK.
Call gtk_window_set_keep_above() to force the message dialog to be above the other windows (some WMs do this by default anyhow but not all). Closes #11163. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61828 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -51,8 +51,8 @@
|
|||||||
@c wxYES_NO is not given so it is usually unnecessary to specify it
|
@c wxYES_NO is not given so it is usually unnecessary to specify it
|
||||||
explicitly.
|
explicitly.
|
||||||
@style{wxSTAY_ON_TOP}
|
@style{wxSTAY_ON_TOP}
|
||||||
Makes the message box stay on top of all other windows (currently
|
Makes the message box stay on top of all other windows and not only
|
||||||
implemented only under MSW).
|
just its parent (currently implemented only under MSW and GTK).
|
||||||
@endStyleTable
|
@endStyleTable
|
||||||
|
|
||||||
@library{wxcore}
|
@library{wxcore}
|
||||||
|
@@ -190,6 +190,11 @@ void wxMessageDialog::GTKCreateMsgDialog()
|
|||||||
|
|
||||||
GtkDialog * const dlg = GTK_DIALOG(m_widget);
|
GtkDialog * const dlg = GTK_DIALOG(m_widget);
|
||||||
|
|
||||||
|
if ( m_dialogStyle & wxSTAY_ON_TOP )
|
||||||
|
{
|
||||||
|
gtk_window_set_keep_above(GTK_WINDOW(m_widget), TRUE);
|
||||||
|
}
|
||||||
|
|
||||||
// we need to add buttons manually if we use custom labels or always for
|
// we need to add buttons manually if we use custom labels or always for
|
||||||
// Yes/No/Cancel dialog as GTK+ doesn't support it natively and when using
|
// Yes/No/Cancel dialog as GTK+ doesn't support it natively and when using
|
||||||
// Hildon we add all the buttons manually as it doesn't support too many of
|
// Hildon we add all the buttons manually as it doesn't support too many of
|
||||||
|
Reference in New Issue
Block a user