Don't call gtk_window_set_geometry_hints() if there are no hints to set.
Calling gtk_window_set_geometry_hints() with the hints mask of 0 doesn't work correctly and sets the window size to the smallest possible. Avoid this by simply not calling this function at all if there is nothing to do. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71825 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1137,8 +1137,12 @@ void wxTopLevelWindowGTK::DoSetSizeHints( int minW, int minH,
|
|||||||
hints.width_inc = incW > 0 ? incW : 1;
|
hints.width_inc = incW > 0 ? incW : 1;
|
||||||
hints.height_inc = incH > 0 ? incH : 1;
|
hints.height_inc = incH > 0 ? incH : 1;
|
||||||
}
|
}
|
||||||
gtk_window_set_geometry_hints(
|
|
||||||
(GtkWindow*)m_widget, NULL, &hints, (GdkWindowHints)hints_mask);
|
if (hints_mask)
|
||||||
|
{
|
||||||
|
gtk_window_set_geometry_hints(
|
||||||
|
(GtkWindow*)m_widget, NULL, &hints, (GdkWindowHints)hints_mask);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxTopLevelWindowGTK::GTKUpdateDecorSize(const wxSize& decorSize)
|
void wxTopLevelWindowGTK::GTKUpdateDecorSize(const wxSize& decorSize)
|
||||||
|
Reference in New Issue
Block a user