Jacek Caban : mshtml: Use custom get_readyState implementations for object and frame elements.

Alexandre Julliard julliard at winehq.org
Mon Nov 15 13:28:48 CST 2010


Module: wine
Branch: master
Commit: cb99f716a7635fc8ef20d092b2326b72669d1a6e
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=cb99f716a7635fc8ef20d092b2326b72669d1a6e

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Sun Nov 14 14:42:00 2010 +0100

mshtml: Use custom get_readyState implementations for object and frame elements.

---

 dlls/mshtml/htmlframe.c  |    9 ++++++++-
 dlls/mshtml/htmlobject.c |   17 +++++++++++++++--
 2 files changed, 23 insertions(+), 3 deletions(-)

diff --git a/dlls/mshtml/htmlframe.c b/dlls/mshtml/htmlframe.c
index ece349d..6683462 100644
--- a/dlls/mshtml/htmlframe.c
+++ b/dlls/mshtml/htmlframe.c
@@ -211,6 +211,13 @@ static HRESULT HTMLFrameElement_get_document(HTMLDOMNode *iface, IDispatch **p)
     return S_OK;
 }
 
+static HRESULT HTMLFrameElement_get_readystate(HTMLDOMNode *iface, BSTR *p)
+{
+    HTMLFrameElement *This = HTMLFRAME_NODE_THIS(iface);
+
+    return IHTMLFrameBase2_get_readyState(HTMLFRAMEBASE2(&This->framebase), p);
+}
+
 static HRESULT HTMLFrameElement_get_dispid(HTMLDOMNode *iface, BSTR name,
         DWORD grfdex, DISPID *pid)
 {
@@ -264,7 +271,7 @@ static const NodeImplVtbl HTMLFrameElementImplVtbl = {
     NULL,
     NULL,
     HTMLFrameElement_get_document,
-    NULL,
+    HTMLFrameElement_get_readystate,
     HTMLFrameElement_get_dispid,
     HTMLFrameElement_invoke,
     HTMLFrameElement_bind_to_tree
diff --git a/dlls/mshtml/htmlobject.c b/dlls/mshtml/htmlobject.c
index f7f6d45..66f9a5d 100644
--- a/dlls/mshtml/htmlobject.c
+++ b/dlls/mshtml/htmlobject.c
@@ -40,7 +40,7 @@ typedef struct {
     nsIDOMHTMLObjectElement *nsobject;
 } HTMLObjectElement;
 
-#define HTMLOBJECT(x)  (&(x)->lpIHTMLObjectElementVtbl)
+#define HTMLOBJECT(x)  ((IHTMLObjectElement*)  &(x)->lpIHTMLObjectElementVtbl)
 
 #define HTMLOBJECT_THIS(iface) DEFINE_THIS(HTMLObjectElement, IHTMLObjectElement, iface)
 
@@ -424,12 +424,25 @@ static void HTMLObjectElement_destructor(HTMLDOMNode *iface)
     HTMLElement_destructor(&This->element.node);
 }
 
+static HRESULT HTMLObjectElement_get_readystate(HTMLDOMNode *iface, BSTR *p)
+{
+    HTMLObjectElement *This = HTMLOBJECT_NODE_THIS(iface);
+    FIXME("(%p)->(%p)\n", This, p);
+    return E_NOTIMPL;
+}
+
 #undef HTMLOBJECT_NODE_THIS
 
 static const NodeImplVtbl HTMLObjectElementImplVtbl = {
     HTMLObjectElement_QI,
     HTMLObjectElement_destructor,
-    HTMLElement_clone
+    HTMLElement_clone,
+    NULL,
+    NULL,
+    NULL,
+    NULL,
+    NULL,
+    HTMLObjectElement_get_readystate
 };
 
 static const tid_t HTMLObjectElement_iface_tids[] = {




More information about the wine-cvs mailing list