X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0ab0d0e1dc1b58cc9a1ab77db5279d82404ab771..9d5507f7a2701395e1d5c121bd877bb9066ee6ea:/src/gtk/minifram.cpp diff --git a/src/gtk/minifram.cpp b/src/gtk/minifram.cpp index 7cdf1b9f62..ed003a902c 100644 --- a/src/gtk/minifram.cpp +++ b/src/gtk/minifram.cpp @@ -13,6 +13,7 @@ #if wxUSE_MINIFRAME #include "wx/minifram.h" +#include "wx/gtk/dcclient.h" #ifndef WX_PRECOMP #include "wx/settings.h" @@ -73,15 +74,9 @@ static gboolean gtk_window_own_expose_callback(GtkWidget* widget, GdkEventExpose wxClientDC dc(win); -#if wxUSE_NEW_DC - wxImplDC *impl = dc.GetImpl(); - wxGTKClientImplDC *client_impl = wxDynamicCast( impl, wxGTKClientImplDC ); - // Hack alert - client_impl->m_window = widget->window; -#else - // Hack alert - dc.m_window = widget->window; -#endif + wxDCImpl *impl = dc.GetImpl(); + wxClientDCImpl *gtk_impl = wxDynamicCast( impl, wxClientDCImpl ); + gtk_impl->m_gdkwindow = widget->window; // Hack alert if (style & wxRESIZE_BORDER) { @@ -352,10 +347,6 @@ bool wxMiniFrame::Create( wxWindow *parent, wxWindowID id, const wxString &title if (style & wxRESIZE_BORDER) m_gdkFunc = GDK_FUNC_RESIZE; - // need to reset default size after changing m_gdkDecor - gtk_window_set_default_size(GTK_WINDOW(m_widget), m_width, m_height); - m_decorSize.Set(0, 0); - // don't allow sizing smaller than decorations GdkGeometry geom; geom.min_width = 2 * m_miniEdge;