Unregister the object too
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34655 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -298,6 +298,9 @@ wxActiveX::~wxActiveX()
|
|||||||
m_oleObject->Close(OLECLOSE_NOSAVE);
|
m_oleObject->Close(OLECLOSE_NOSAVE);
|
||||||
m_oleObject->SetClientSite(NULL);
|
m_oleObject->SetClientSite(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Unregister object as active
|
||||||
|
RevokeActiveObject(m_pdwRegister, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxActiveX::CreateActiveX(REFCLSID clsid)
|
void wxActiveX::CreateActiveX(REFCLSID clsid)
|
||||||
@@ -323,7 +326,7 @@ void wxActiveX::CreateActiveX(REFCLSID clsid)
|
|||||||
|
|
||||||
// Register object as active
|
// Register object as active
|
||||||
unsigned long pdwRegister;
|
unsigned long pdwRegister;
|
||||||
hret = RegisterActiveObject(m_ActiveX, clsid, ACTIVEOBJECT_WEAK, &pdwRegister);
|
hret = RegisterActiveObject(m_ActiveX, clsid, ACTIVEOBJECT_WEAK, &m_pdwRegister);
|
||||||
WXOLE_WARN(hret, "Unable to register object as active");
|
WXOLE_WARN(hret, "Unable to register object as active");
|
||||||
|
|
||||||
// Get Dispatch interface
|
// Get Dispatch interface
|
||||||
|
@@ -566,6 +566,7 @@ protected:
|
|||||||
friend class FrameSite;
|
friend class FrameSite;
|
||||||
friend class wxActiveXEvents;
|
friend class wxActiveXEvents;
|
||||||
|
|
||||||
|
unsigned long m_pdwRegister;
|
||||||
|
|
||||||
typedef map<MEMBERID, int> MemberIdMap;
|
typedef map<MEMBERID, int> MemberIdMap;
|
||||||
typedef map<wxString, int, NS_wxActiveX::less_wxStringI> NameMap;
|
typedef map<wxString, int, NS_wxActiveX::less_wxStringI> NameMap;
|
||||||
|
Reference in New Issue
Block a user