X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a2053b27b318fe81918a72c838944d1e8cd1524f..07d4b94c3b5d8876d3c9a5f93048afdd6734fe78:/src/gtk/minifram.cpp diff --git a/src/gtk/minifram.cpp b/src/gtk/minifram.cpp index e4267e0a7f..9da9393c89 100644 --- a/src/gtk/minifram.cpp +++ b/src/gtk/minifram.cpp @@ -12,6 +12,9 @@ #endif #include "wx/minifram.h" + +#if wxUSE_MINIFRAME + #include "wx/dcscreen.h" #include "gtk/gtk.h" @@ -160,6 +163,8 @@ static gint gtk_window_button_press_callback( GtkWidget *widget, GdkEventButton if (win->m_isDragging) return TRUE; + gdk_window_raise( win->m_widget->window ); + gdk_pointer_grab( widget->window, FALSE, (GdkEventMask) (GDK_BUTTON_PRESS_MASK | @@ -209,7 +214,8 @@ static gint gtk_window_button_release_callback( GtkWidget *widget, GdkEventButto gdk_window_get_origin( widget->window, &org_x, &org_y ); x += org_x - win->m_diffX; y += org_y - win->m_diffY; - win->InternalSetPosition(x, y); + win->m_x = x; + win->m_y = y; gtk_widget_set_uposition( win->m_widget, x, y ); return TRUE; @@ -317,3 +323,5 @@ bool wxMiniFrame::Create( wxWindow *parent, wxWindowID id, const wxString &title return TRUE; } + +#endif