]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/dcclient.cpp
reset virtual root to NULL in DeleteAllItems()
[wxWidgets.git] / src / msw / dcclient.cpp
index 6d5df17f484938b49ad871ffd07347b9eae9a8f0..687253ddc8cbae3de9807e72144b826e00828295 100644 (file)
@@ -120,6 +120,13 @@ void wxWindowDC::InitDC()
 #endif
 }
 
+void wxWindowDC::DoGetSize(int *width, int *height) const
+{
+    wxCHECK_RET( m_canvas, _T("wxWindowDC without a window?") );
+
+    m_canvas->GetSize(width, height);
+}
+
 // ----------------------------------------------------------------------------
 // wxClientDC
 // ----------------------------------------------------------------------------
@@ -165,6 +172,13 @@ wxClientDC::~wxClientDC()
 {
 }
 
+void wxClientDC::DoGetSize(int *width, int *height) const
+{
+    wxCHECK_RET( m_canvas, _T("wxClientDC without a window?") );
+
+    m_canvas->GetClientSize(width, height);
+}
+
 // ----------------------------------------------------------------------------
 // wxPaintDC
 // ----------------------------------------------------------------------------
@@ -262,9 +276,10 @@ wxPaintDCInfo *wxPaintDC::FindInCache(size_t *index) const
     size_t nCache = ms_cache.GetCount();
     for ( size_t n = 0; n < nCache; n++ )
     {
-        info = &ms_cache[n];
-        if ( info->hwnd == m_canvas->GetHWND() )
+        wxPaintDCInfo *info1 = &ms_cache[n];
+        if ( info1->hwnd == m_canvas->GetHWND() )
         {
+            info = info1;
             if ( index )
                 *index = n;
             break;