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:
parent
25b3661bd4
commit
9c721ebf97
@ -298,6 +298,9 @@ wxActiveX::~wxActiveX()
|
||||
m_oleObject->Close(OLECLOSE_NOSAVE);
|
||||
m_oleObject->SetClientSite(NULL);
|
||||
}
|
||||
|
||||
// Unregister object as active
|
||||
RevokeActiveObject(m_pdwRegister, NULL);
|
||||
}
|
||||
|
||||
void wxActiveX::CreateActiveX(REFCLSID clsid)
|
||||
@ -323,7 +326,7 @@ void wxActiveX::CreateActiveX(REFCLSID clsid)
|
||||
|
||||
// Register object as active
|
||||
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");
|
||||
|
||||
// Get Dispatch interface
|
||||
|
@ -566,6 +566,7 @@ protected:
|
||||
friend class FrameSite;
|
||||
friend class wxActiveXEvents;
|
||||
|
||||
unsigned long m_pdwRegister;
|
||||
|
||||
typedef map<MEMBERID, int> MemberIdMap;
|
||||
typedef map<wxString, int, NS_wxActiveX::less_wxStringI> NameMap;
|
||||
|
Loading…
Reference in New Issue
Block a user