Jacek Caban : mshtml: Added IHTMLCSSStyleDeclaration:: styleFloat property implementation.
Alexandre Julliard
julliard at winehq.org
Mon Sep 10 16:01:09 CDT 2018
Module: wine
Branch: master
Commit: 9d22dc476f50f18a5900862832e101c5ba34a47d
URL: https://source.winehq.org/git/wine.git/?a=commit;h=9d22dc476f50f18a5900862832e101c5ba34a47d
Author: Jacek Caban <jacek at codeweavers.com>
Date: Mon Sep 10 17:27:46 2018 +0200
mshtml: Added IHTMLCSSStyleDeclaration::styleFloat property implementation.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/mshtml/htmlstyle.c | 8 ++++----
dlls/mshtml/tests/style.c | 17 +++++++++++++++++
2 files changed, 21 insertions(+), 4 deletions(-)
diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c
index 8cfc6e1..282dd58 100644
--- a/dlls/mshtml/htmlstyle.c
+++ b/dlls/mshtml/htmlstyle.c
@@ -5567,15 +5567,15 @@ static HRESULT WINAPI HTMLCSSStyleDeclaration_get_height(IHTMLCSSStyleDeclaratio
static HRESULT WINAPI HTMLCSSStyleDeclaration_put_styleFloat(IHTMLCSSStyleDeclaration *iface, BSTR v)
{
HTMLStyle *This = impl_from_IHTMLCSSStyleDeclaration(iface);
- FIXME("(%p)->(%s)\n", This, debugstr_w(v));
- return E_NOTIMPL;
+ TRACE("(%p)->(%s)\n", This, debugstr_w(v));
+ return set_style_property(This, STYLEID_FLOAT, v);
}
static HRESULT WINAPI HTMLCSSStyleDeclaration_get_styleFloat(IHTMLCSSStyleDeclaration *iface, BSTR *p)
{
HTMLStyle *This = impl_from_IHTMLCSSStyleDeclaration(iface);
- FIXME("(%p)->(%p)\n", This, p);
- return E_NOTIMPL;
+ TRACE("(%p)->(%p)\n", This, p);
+ return get_style_property(This, STYLEID_FLOAT, p);
}
static HRESULT WINAPI HTMLCSSStyleDeclaration_put_clear(IHTMLCSSStyleDeclaration *iface, BSTR v)
diff --git a/dlls/mshtml/tests/style.c b/dlls/mshtml/tests/style.c
index cbd3257..ae3b2a4 100644
--- a/dlls/mshtml/tests/style.c
+++ b/dlls/mshtml/tests/style.c
@@ -2897,6 +2897,12 @@ static void test_body_style(IHTMLStyle *style)
str = NULL;
hres = IHTMLCSSStyleDeclaration_get_cssFloat(css_style, &str);
ok(hres == S_OK, "get_cssFloat failed: %08x\n", hres);
+ ok(!strcmp_wa(str, "left"), "cssFloat = %s\n", wine_dbgstr_w(str));
+ SysFreeString(str);
+
+ str = NULL;
+ hres = IHTMLCSSStyleDeclaration_get_styleFloat(css_style, &str);
+ ok(hres == S_OK, "get_styleFloat failed: %08x\n", hres);
ok(!strcmp_wa(str, "left"), "styleFloat = %s\n", wine_dbgstr_w(str));
SysFreeString(str);
@@ -2910,6 +2916,17 @@ static void test_body_style(IHTMLStyle *style)
ok(hres == S_OK, "get_cssFloat failed: %08x\n", hres);
ok(!strcmp_wa(str, "right"), "styleFloat = %s\n", wine_dbgstr_w(str));
SysFreeString(str);
+
+ str = a2bstr("left");
+ hres = IHTMLCSSStyleDeclaration_put_styleFloat(css_style, str);
+ ok(hres == S_OK, "put_styleFloat failed: %08x\n", hres);
+ SysFreeString(str);
+
+ str = NULL;
+ hres = IHTMLCSSStyleDeclaration_get_cssFloat(css_style, &str);
+ ok(hres == S_OK, "get_cssFloat failed: %08x\n", hres);
+ ok(!strcmp_wa(str, "left"), "styleFloat = %s\n", wine_dbgstr_w(str));
+ SysFreeString(str);
}
hres = IHTMLStyle_QueryInterface(style, &IID_IHTMLStyle2, (void**)&style2);
More information about the wine-cvs
mailing list