mshtml: Destroy connection points.
This commit is contained in:
parent
bf1724ef33
commit
7f617230a5
|
@ -197,6 +197,19 @@ static void ConnectionPoint_Create(HTMLDocument *doc, REFIID riid, ConnectionPoi
|
||||||
*cp = ret;
|
*cp = ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void ConnectionPoint_Destroy(ConnectionPoint *This)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
for(i=0; i<This->sinks_size; i++) {
|
||||||
|
if(This->sinks[i].unk)
|
||||||
|
IUnknown_Release(This->sinks[i].unk);
|
||||||
|
}
|
||||||
|
|
||||||
|
HeapFree(GetProcessHeap(), 0, This->sinks);
|
||||||
|
HeapFree(GetProcessHeap(), 0, This);
|
||||||
|
}
|
||||||
|
|
||||||
#define CONPTCONT_THIS(iface) DEFINE_THIS(HTMLDocument, ConnectionPointContainer, iface)
|
#define CONPTCONT_THIS(iface) DEFINE_THIS(HTMLDocument, ConnectionPointContainer, iface)
|
||||||
|
|
||||||
static HRESULT WINAPI ConnectionPointContainer_QueryInterface(IConnectionPointContainer *iface,
|
static HRESULT WINAPI ConnectionPointContainer_QueryInterface(IConnectionPointContainer *iface,
|
||||||
|
@ -271,3 +284,10 @@ void HTMLDocument_ConnectionPoints_Init(HTMLDocument *This)
|
||||||
ConnectionPoint_Create(This, &DIID_HTMLDocumentEvents, &This->cp_htmldocevents);
|
ConnectionPoint_Create(This, &DIID_HTMLDocumentEvents, &This->cp_htmldocevents);
|
||||||
ConnectionPoint_Create(This, &DIID_HTMLDocumentEvents2, &This->cp_htmldocevents2);
|
ConnectionPoint_Create(This, &DIID_HTMLDocumentEvents2, &This->cp_htmldocevents2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void HTMLDocument_ConnectionPoints_Destroy(HTMLDocument *This)
|
||||||
|
{
|
||||||
|
ConnectionPoint_Destroy(This->cp_propnotif);
|
||||||
|
ConnectionPoint_Destroy(This->cp_htmldocevents);
|
||||||
|
ConnectionPoint_Destroy(This->cp_htmldocevents2);
|
||||||
|
}
|
||||||
|
|
|
@ -157,6 +157,8 @@ static ULONG WINAPI HTMLDocument_Release(IHTMLDocument2 *iface)
|
||||||
|
|
||||||
release_nodes(This);
|
release_nodes(This);
|
||||||
|
|
||||||
|
HTMLDocument_ConnectionPoints_Destroy(This);
|
||||||
|
|
||||||
if(This->nscontainer)
|
if(This->nscontainer)
|
||||||
NSContainer_Release(This->nscontainer);
|
NSContainer_Release(This->nscontainer);
|
||||||
|
|
||||||
|
|
|
@ -260,6 +260,8 @@ void HTMLDocument_Service_Init(HTMLDocument*);
|
||||||
void HTMLDocument_Hlink_Init(HTMLDocument*);
|
void HTMLDocument_Hlink_Init(HTMLDocument*);
|
||||||
void HTMLDocument_ConnectionPoints_Init(HTMLDocument*);
|
void HTMLDocument_ConnectionPoints_Init(HTMLDocument*);
|
||||||
|
|
||||||
|
void HTMLDocument_ConnectionPoints_Destroy(HTMLDocument*);
|
||||||
|
|
||||||
NSContainer *NSContainer_Create(HTMLDocument*,NSContainer*);
|
NSContainer *NSContainer_Create(HTMLDocument*,NSContainer*);
|
||||||
void NSContainer_Release(NSContainer*);
|
void NSContainer_Release(NSContainer*);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue