]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/ole/activex.cpp
Fix wxGrid editors background painting.
[wxWidgets.git] / src / msw / ole / activex.cpp
index b034ab1c11470728999e0d70861b9a62f5d9d8e0..d0652d4bcc7182c2b543b7dcde0ab45eddc4b80a 100644 (file)
@@ -1113,8 +1113,11 @@ void wxActiveXContainer::CreateActiveX(REFIID iid, IUnknown* pUnk)
 
     if (! (dwMiscStatus & OLEMISC_INVISIBLEATRUNTIME))
     {
+        RECT posRect;
+        wxCopyRectToRECT(m_realparent->GetClientSize(), posRect);
+
         hret = m_oleObject->DoVerb(OLEIVERB_INPLACEACTIVATE, NULL,
-            m_clientSite, 0, (HWND)m_realparent->GetHWND(), NULL);
+            m_clientSite, 0, (HWND)m_realparent->GetHWND(), &posRect);
         CHECK_HR(hret);
 
         if (m_oleInPlaceObject.IsOk())
@@ -1124,9 +1127,6 @@ void wxActiveXContainer::CreateActiveX(REFIID iid, IUnknown* pUnk)
             ::SetActiveWindow(m_oleObjectHWND);
         }
 
-        RECT posRect;
-        wxCopyRectToRECT(m_realparent->GetClientSize(), posRect);
-
         if (posRect.right > 0 && posRect.bottom > 0 &&
             m_oleInPlaceObject.IsOk())
         {