From 53f2cb83dcb6e459b7a2bf9e7c5fd713e445d2b9 Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Tue, 6 May 2008 16:04:58 +0200 Subject: [PATCH] mshtml: gcc 2.95 does not allow an array of undefined dimension in a struct. So fix dispex_static_data_t accordingly. --- dlls/mshtml/htmlcomment.c | 9 +++++---- dlls/mshtml/htmldoc.c | 15 ++++++++------- dlls/mshtml/htmlelem.c | 24 +++++++++++++----------- dlls/mshtml/htmlimg.c | 17 +++++++++-------- dlls/mshtml/htmlinput.c | 17 +++++++++-------- dlls/mshtml/htmlnode.c | 9 +++++---- dlls/mshtml/htmloption.c | 17 +++++++++-------- dlls/mshtml/htmlstyle.c | 9 +++++---- dlls/mshtml/htmltextnode.c | 13 +++++++------ dlls/mshtml/htmlwindow.c | 11 ++++++----- dlls/mshtml/mshtml_private.h | 2 +- dlls/mshtml/omnavigator.c | 9 +++++---- 12 files changed, 82 insertions(+), 70 deletions(-) diff --git a/dlls/mshtml/htmlcomment.c b/dlls/mshtml/htmlcomment.c index 2155a16bc42..b006dbbb3a7 100644 --- a/dlls/mshtml/htmlcomment.c +++ b/dlls/mshtml/htmlcomment.c @@ -175,14 +175,15 @@ static const NodeImplVtbl HTMLCommentElementImplVtbl = { HTMLCommentElement_destructor }; +static const tid_t HTMLCommentElement_iface_tids[] = { + IHTMLCommentElement_tid, + 0 +}; static dispex_static_data_t HTMLCommentElement_dispex = { NULL, DispHTMLCommentElement_tid, NULL, - { - IHTMLCommentElement_tid, - 0 - } + HTMLCommentElement_iface_tids }; HTMLElement *HTMLCommentElement_Create(nsIDOMNode *nsnode) diff --git a/dlls/mshtml/htmldoc.c b/dlls/mshtml/htmldoc.c index 73e31f14f52..c7d9eb82951 100644 --- a/dlls/mshtml/htmldoc.c +++ b/dlls/mshtml/htmldoc.c @@ -1490,17 +1490,18 @@ static const IDispatchExVtbl DocDispatchExVtbl = { DocDispatchEx_GetNameSpaceParent }; +static const tid_t HTMLDocument_iface_tids[] = { + IHTMLDocument2_tid, + IHTMLDocument3_tid, + IHTMLDocument4_tid, + IHTMLDocument5_tid, + 0 +}; static dispex_static_data_t HTMLDocument_dispex = { NULL, DispHTMLDocument_tid, NULL, - { - IHTMLDocument2_tid, - IHTMLDocument3_tid, - IHTMLDocument4_tid, - IHTMLDocument5_tid, - 0 - } + HTMLDocument_iface_tids }; HRESULT HTMLDocument_Create(IUnknown *pUnkOuter, REFIID riid, void** ppvObject) diff --git a/dlls/mshtml/htmlelem.c b/dlls/mshtml/htmlelem.c index 837f548ef9c..22e8c5ce8fd 100644 --- a/dlls/mshtml/htmlelem.c +++ b/dlls/mshtml/htmlelem.c @@ -1326,17 +1326,18 @@ static const NodeImplVtbl HTMLElementImplVtbl = { HTMLElement_destructor }; +static const tid_t HTMLElement_iface_tids[] = { + IHTMLDOMNode_tid, + IHTMLDOMNode2_tid, + IHTMLElement_tid, + IHTMLElement2_tid, + 0 +}; static dispex_static_data_t HTMLElement_dispex = { NULL, DispHTMLUnknownElement_tid, NULL, - { - IHTMLDOMNode_tid, - IHTMLDOMNode2_tid, - IHTMLElement_tid, - IHTMLElement2_tid, - 0 - } + HTMLElement_iface_tids }; void HTMLElement_Init(HTMLElement *This) @@ -1769,14 +1770,15 @@ static const dispex_static_data_vtbl_t HTMLElementColection_dispex_vtbl = { HTMLElementCollection_invoke }; +static const tid_t HTMLElementCollection_iface_tids[] = { + IHTMLElementCollection_tid, + 0 +}; static dispex_static_data_t HTMLElementCollection_dispex = { &HTMLElementColection_dispex_vtbl, DispHTMLElementCollection_tid, NULL, - { - IHTMLElementCollection_tid, - 0 - } + HTMLElementCollection_iface_tids }; IHTMLElementCollection *create_all_collection(HTMLDOMNode *node) diff --git a/dlls/mshtml/htmlimg.c b/dlls/mshtml/htmlimg.c index 81060c1366e..92647be9a7b 100644 --- a/dlls/mshtml/htmlimg.c +++ b/dlls/mshtml/htmlimg.c @@ -526,18 +526,19 @@ static const NodeImplVtbl HTMLImgElementImplVtbl = { HTMLImgElement_destructor }; +static const tid_t HTMLImgElement_iface_tids[] = { + IHTMLDOMNode_tid, + IHTMLDOMNode2_tid, + IHTMLElement_tid, + IHTMLElement2_tid, + IHTMLImgElement_tid, + 0 +}; static dispex_static_data_t HTMLImgElement_dispex = { NULL, DispHTMLImg_tid, NULL, - { - IHTMLDOMNode_tid, - IHTMLDOMNode2_tid, - IHTMLElement_tid, - IHTMLElement2_tid, - IHTMLImgElement_tid, - 0 - } + HTMLImgElement_iface_tids }; HTMLElement *HTMLImgElement_Create(nsIDOMHTMLElement *nselem) diff --git a/dlls/mshtml/htmlinput.c b/dlls/mshtml/htmlinput.c index c4f27507d20..5b605b3e368 100644 --- a/dlls/mshtml/htmlinput.c +++ b/dlls/mshtml/htmlinput.c @@ -1059,18 +1059,19 @@ static const NodeImplVtbl HTMLInputElementImplVtbl = { HTMLInputElement_destructor }; +static const tid_t HTMLInputElement_iface_tids[] = { + IHTMLDOMNode_tid, + IHTMLDOMNode2_tid, + IHTMLElement_tid, + IHTMLElement2_tid, + IHTMLInputElement_tid, + 0 +}; static dispex_static_data_t HTMLInputElement_dispex = { NULL, DispHTMLInputElement_tid, NULL, - { - IHTMLDOMNode_tid, - IHTMLDOMNode2_tid, - IHTMLElement_tid, - IHTMLElement2_tid, - IHTMLInputElement_tid, - 0 - } + HTMLInputElement_iface_tids }; HTMLElement *HTMLInputElement_Create(nsIDOMHTMLElement *nselem) diff --git a/dlls/mshtml/htmlnode.c b/dlls/mshtml/htmlnode.c index f330d15ac64..f2178939255 100644 --- a/dlls/mshtml/htmlnode.c +++ b/dlls/mshtml/htmlnode.c @@ -193,14 +193,15 @@ static const IHTMLDOMChildrenCollectionVtbl HTMLDOMChildrenCollectionVtbl = { HTMLDOMChildrenCollection_item }; +static const tid_t HTMLDOMChildrenCollection_iface_tids[] = { + IHTMLDOMChildrenCollection_tid, + 0 +}; static dispex_static_data_t HTMLDOMChildrenCollection_dispex = { NULL, DispDOMChildrenCollection_tid, NULL, - { - IHTMLDOMChildrenCollection_tid, - 0 - } + HTMLDOMChildrenCollection_iface_tids }; static IHTMLDOMChildrenCollection *create_child_collection(HTMLDocument *doc, nsIDOMNodeList *nslist) diff --git a/dlls/mshtml/htmloption.c b/dlls/mshtml/htmloption.c index 0753810ac7b..efb983031c2 100644 --- a/dlls/mshtml/htmloption.c +++ b/dlls/mshtml/htmloption.c @@ -331,18 +331,19 @@ static const NodeImplVtbl HTMLOptionElementImplVtbl = { HTMLOptionElement_destructor }; +static const tid_t HTMLOptionElement_iface_tids[] = { + IHTMLDOMNode_tid, + IHTMLDOMNode2_tid, + IHTMLElement_tid, + IHTMLElement2_tid, + IHTMLOptionElement_tid, + 0 +}; static dispex_static_data_t HTMLOptionElement_dispex = { NULL, DispHTMLOptionElement_tid, NULL, - { - IHTMLDOMNode_tid, - IHTMLDOMNode2_tid, - IHTMLElement_tid, - IHTMLElement2_tid, - IHTMLOptionElement_tid, - 0 - } + HTMLOptionElement_iface_tids }; HTMLElement *HTMLOptionElement_Create(nsIDOMHTMLElement *nselem) diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c index 01aa391d147..a9dc1796312 100644 --- a/dlls/mshtml/htmlstyle.c +++ b/dlls/mshtml/htmlstyle.c @@ -1845,14 +1845,15 @@ static const IHTMLStyleVtbl HTMLStyleVtbl = { HTMLStyle_toString }; +static const tid_t HTMLStyle_iface_tids[] = { + IHTMLStyle_tid, + 0 +}; static dispex_static_data_t HTMLStyle_dispex = { NULL, DispHTMLStyle_tid, NULL, - { - IHTMLStyle_tid, - 0 - } + HTMLStyle_iface_tids }; IHTMLStyle *HTMLStyle_Create(nsIDOMCSSStyleDeclaration *nsstyle) diff --git a/dlls/mshtml/htmltextnode.c b/dlls/mshtml/htmltextnode.c index b98821b89ab..1911b18387a 100644 --- a/dlls/mshtml/htmltextnode.c +++ b/dlls/mshtml/htmltextnode.c @@ -185,16 +185,17 @@ static const NodeImplVtbl HTMLDOMTextNodeImplVtbl = { HTMLDOMTextNode_destructor }; +static const tid_t HTMLDOMTextNode_iface_tids[] = { + IHTMLDOMNode_tid, + IHTMLDOMNode2_tid, + IHTMLDOMTextNode_tid, + 0 +}; static dispex_static_data_t HTMLDOMTextNode_dispex = { NULL, DispHTMLDOMTextNode_tid, 0, - { - IHTMLDOMNode_tid, - IHTMLDOMNode2_tid, - IHTMLDOMTextNode_tid, - 0 - } + HTMLDOMTextNode_iface_tids }; HTMLDOMNode *HTMLDOMTextNode_Create(nsIDOMNode *nsnode) diff --git a/dlls/mshtml/htmlwindow.c b/dlls/mshtml/htmlwindow.c index 20731329eb6..c46f05e25d5 100644 --- a/dlls/mshtml/htmlwindow.c +++ b/dlls/mshtml/htmlwindow.c @@ -1107,15 +1107,16 @@ static const IDispatchExVtbl WindowDispExVtbl = { WindowDispEx_GetNameSpaceParent }; +static const tid_t HTMLWindow_iface_tids[] = { + IHTMLWindow2_tid, + IHTMLWindow3_tid, + 0 +}; static dispex_static_data_t HTMLWindow_dispex = { NULL, DispHTMLWindow2_tid, NULL, - { - IHTMLWindow2_tid, - IHTMLWindow3_tid, - 0 - } + HTMLWindow_iface_tids }; static const char wineConfig_func[] = diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 921d9751e16..7ad23251aa0 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -108,7 +108,7 @@ typedef struct { const dispex_static_data_vtbl_t *vtbl; const tid_t disp_tid; dispex_data_t *data; - const tid_t iface_tids[]; + const tid_t* const iface_tids; } dispex_static_data_t; typedef struct { diff --git a/dlls/mshtml/omnavigator.c b/dlls/mshtml/omnavigator.c index 74b2cfdb7e1..26287e81770 100644 --- a/dlls/mshtml/omnavigator.c +++ b/dlls/mshtml/omnavigator.c @@ -300,14 +300,15 @@ static const IOmNavigatorVtbl OmNavigatorVtbl = { OmNavigator_get_userProfile }; +static const tid_t OmNavigator_iface_tids[] = { + IOmNavigator_tid, + 0 +}; static dispex_static_data_t OmNavigator_dispex = { NULL, IOmNavigator_tid, NULL, - { - IOmNavigator_tid, - 0 - } + OmNavigator_iface_tids }; IOmNavigator *OmNavigator_Create(void) -- 2.11.4.GIT