-#ifdef __WXGTK20__
- GdkRectangle *gdkrects = NULL;
- gint numRects = 0;
- gdk_region_get_rectangles( gdkregion, &gdkrects, &numRects );
-
- m_numRects = numRects;
- if (numRects)
- {
- m_rects = new wxRect[m_numRects];
- for (size_t i=0; i < m_numRects; ++i)
- {
- GdkRectangle &gr = gdkrects[i];
- wxRect &wr = m_rects[i];
- wr.x = gr.x;
- wr.y = gr.y;
- wr.width = gr.width;
- wr.height = gr.height;
- }
- }
- g_free( gdkrects );
-#else // GTK+ 1.x