diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index ae545bf49a..b996ff7fee 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -3526,6 +3526,8 @@ bool wxWindowGTK::ScrollPages(int pages) return DoScrollByUnits(ScrollDir_Vert, ScrollUnit_Page, pages); } +#include "wx/treectrl.h" + void wxWindowGTK::Refresh(bool WXUNUSED(eraseBackground), const wxRect *rect) { @@ -3541,23 +3543,21 @@ void wxWindowGTK::Refresh(bool WXUNUSED(eraseBackground), return; if (rect == NULL) - gtk_widget_queue_draw(widget); + { + gdk_window_invalidate_rect( widget->window, NULL, TRUE ); + } else { int x = rect->x; if (GetLayoutDirection() == wxLayout_RightToLeft) x = GetClientSize().x - x - rect->width; - -#if 0 - gtk_widget_queue_draw_area(widget, x, rect->y, rect->width, rect->height); -#else + GdkRectangle r; r.x = rect->x; r.y = rect->y; r.width = rect->width; r.height = rect->height; gdk_window_invalidate_rect( m_wxwindow->window, &r, TRUE ); -#endif } }