X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f74fd79b8e0b396659b99a92effa20672b0254d8..9b2a74693ea0ac096f5099caac4a5ead3268e07f:/src/msw/ole/activex.cpp diff --git a/src/msw/ole/activex.cpp b/src/msw/ole/activex.cpp index 7f23874d09..0c8ec070f4 100644 --- a/src/msw/ole/activex.cpp +++ b/src/msw/ole/activex.cpp @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: msw/ole/activex.cpp +// Name: src/msw/ole/activex.cpp // Purpose: wxActiveXContainer implementation // Author: Ryan Norton , Lindsay Mathieson // Modified by: @@ -523,7 +523,7 @@ public: HRESULT STDMETHODCALLTYPE LockContainer(BOOL){return S_OK;} //********************IOleItemContainer*************************** HRESULT STDMETHODCALLTYPE - #ifdef __WXWINCE__ + #if 0 // defined(__WXWINCE__) && __VISUALC__ < 1400 GetObject #elif defined(_UNICODE) GetObjectW @@ -691,7 +691,7 @@ private: public: wxActiveXEvents(wxActiveXContainer *ax) : m_activeX(ax), m_haveCustomId(false) {} - wxActiveXEvents(wxActiveXContainer *ax, REFIID iid) : m_activeX(ax), m_haveCustomId(true), m_customId(iid) {} + wxActiveXEvents(wxActiveXContainer *ax, REFIID iid) : m_activeX(ax), m_customId(iid), m_haveCustomId(true) {} virtual ~wxActiveXEvents() { } @@ -946,7 +946,7 @@ void wxActiveXContainer::CreateActiveX(REFIID iid, IUnknown* pUnk) hret = cp->Advise(new wxActiveXEvents(this, ta->guid), &adviseCookie); wxASSERT_MSG( SUCCEEDED(hret), - wxString::Format(wxT("Cannot connect!\nHRESULT:%X"), hret) + wxString::Format(wxT("Cannot connect!\nHRESULT:%X"), (unsigned int)hret) ); } } @@ -1123,7 +1123,11 @@ void wxActiveXContainer::OnPaint(wxPaintEvent& WXUNUSED(event)) posRect.right = w; posRect.bottom = h; +#if !(defined(_WIN32_WCE) && _WIN32_WCE < 400) ::RedrawWindow(m_oleObjectHWND, NULL, NULL, RDW_INTERNALPAINT); +#else + ::InvalidateRect(m_oleObjectHWND, NULL, false); +#endif RECTL *prcBounds = (RECTL *) &posRect; m_viewObject->Draw(DVASPECT_CONTENT, -1, NULL, NULL, NULL, (HDC)dc.GetHDC(), prcBounds, NULL, NULL, 0);