Alistair Leslie-Hughes : mshtml: Implement IHTMLCurrentStyle_get_zIndex.

Alexandre Julliard julliard at winehq.org
Tue Feb 24 10:21:50 CST 2009


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

Author: Alistair Leslie-Hughes <leslie_alistair at hotmail.com>
Date:   Sun Feb 22 19:50:09 2009 +1100

mshtml: Implement IHTMLCurrentStyle_get_zIndex.

---

 dlls/mshtml/htmlcurstyle.c |    4 ++--
 dlls/mshtml/tests/dom.c    |    6 ++++++
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/dlls/mshtml/htmlcurstyle.c b/dlls/mshtml/htmlcurstyle.c
index 01909bf..f297b04 100644
--- a/dlls/mshtml/htmlcurstyle.c
+++ b/dlls/mshtml/htmlcurstyle.c
@@ -393,8 +393,8 @@ static HRESULT WINAPI HTMLCurrentStyle_get_visibility(IHTMLCurrentStyle *iface,
 static HRESULT WINAPI HTMLCurrentStyle_get_zIndex(IHTMLCurrentStyle *iface, VARIANT *p)
 {
     HTMLCurrentStyle *This = HTMLCURSTYLE_THIS(iface);
-    FIXME("(%p)->(%p)\n", This, p);
-    return E_NOTIMPL;
+    TRACE("(%p)->(%p)\n", This, p);
+    return get_nsstyle_attr_var(This->nsstyle, STYLEID_Z_INDEX, p, ATTR_STR_TO_INT);
 }
 
 static HRESULT WINAPI HTMLCurrentStyle_get_letterSpacing(IHTMLCurrentStyle *iface, VARIANT *p)
diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c
index 2c6cdcb..222d93a 100644
--- a/dlls/mshtml/tests/dom.c
+++ b/dlls/mshtml/tests/dom.c
@@ -2475,6 +2475,12 @@ static void test_current_style(IHTMLCurrentStyle *current_style)
     ok(hres == S_OK, "get_paddingLeft failed: %08x\n", hres);
     ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v));
     VariantClear(&v);
+
+    hres = IHTMLCurrentStyle_get_zIndex(current_style, &v);
+    ok(hres == S_OK, "get_zIndex failed: %08x\n", hres);
+    ok(V_VT(&v) == VT_I4, "V_VT(v) = %d\n", V_VT(&v));
+    ok( V_I4(&v) == 1, "expect 1 got (%d)\n", V_I4(&v));
+    VariantClear(&v);
 }
 
 static void test_style2(IHTMLStyle2 *style2)




More information about the wine-cvs mailing list