+ wxRegionRefData(const wxRegionRefData& refData)
+ : wxObjectRefData()
+ {
+ m_region = gdk_regions_union(wxGdkRegion(), refData.m_region);
+ }
+
+ ~wxRegionRefData()
+ {
+ if (m_region)
+ gdk_region_destroy( m_region );
+ }
+
+ GdkRegion *m_region;
+};
+
+// ----------------------------------------------------------------------------
+// macros
+// ----------------------------------------------------------------------------
+
+#define M_REGIONDATA ((wxRegionRefData *)m_refData)
+#define M_REGIONDATA_OF(rgn) ((wxRegionRefData *)(rgn.m_refData))
+
+IMPLEMENT_DYNAMIC_CLASS(wxRegion, wxGDIObject)
+IMPLEMENT_DYNAMIC_CLASS(wxRegionIterator,wxObject)
+
+// ----------------------------------------------------------------------------
+// wxRegion construction
+// ----------------------------------------------------------------------------