Jacek Caban : mshtml: Add IHTMLCSSStyleDeclaration2::columnRuleWidth property semi-stub implementation.
Alexandre Julliard
julliard at winehq.org
Tue Jun 9 15:27:48 CDT 2020
Module: wine
Branch: master
Commit: 883f45ac0eff47a099813cbe0e5e89ca5406e359
URL: https://source.winehq.org/git/wine.git/?a=commit;h=883f45ac0eff47a099813cbe0e5e89ca5406e359
Author: Jacek Caban <jacek at codeweavers.com>
Date: Tue Jun 9 16:16:36 2020 +0200
mshtml: Add IHTMLCSSStyleDeclaration2::columnRuleWidth property semi-stub implementation.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/mshtml/htmlstyle.c | 13 +++++++++----
dlls/mshtml/htmlstyle.h | 1 +
dlls/mshtml/tests/style.c | 19 +++++++++++++++++++
3 files changed, 29 insertions(+), 4 deletions(-)
diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c
index 0159dac75b..388d200fa3 100644
--- a/dlls/mshtml/htmlstyle.c
+++ b/dlls/mshtml/htmlstyle.c
@@ -573,6 +573,11 @@ static const style_tbl_entry_t style_tbl[] = {
DISPID_IHTMLCSSSTYLEDECLARATION2_COLUMNRULESTYLE,
DISPID_UNKNOWN
},
+ {
+ L"column-rule-width",
+ DISPID_IHTMLCSSSTYLEDECLARATION2_COLUMNRULEWIDTH,
+ DISPID_UNKNOWN
+ },
{
L"column-span",
DISPID_IHTMLCSSSTYLEDECLARATION2_COLUMNSPAN,
@@ -8955,15 +8960,15 @@ static HRESULT WINAPI HTMLCSSStyleDeclaration2_get_columnRuleStyle(IHTMLCSSStyle
static HRESULT WINAPI HTMLCSSStyleDeclaration2_put_columnRuleWidth(IHTMLCSSStyleDeclaration2 *iface, VARIANT v)
{
CSSStyle *This = impl_from_IHTMLCSSStyleDeclaration2(iface);
- FIXME("(%p)->(%s)\n", This, debugstr_variant(&v));
- return E_NOTIMPL;
+ WARN("(%p)->(%s) semi-stub\n", This, debugstr_variant(&v));
+ return set_style_property_var(This, STYLEID_COLUMN_RULE_WIDTH, &v);
}
static HRESULT WINAPI HTMLCSSStyleDeclaration2_get_columnRuleWidth(IHTMLCSSStyleDeclaration2 *iface, VARIANT *p)
{
CSSStyle *This = impl_from_IHTMLCSSStyleDeclaration2(iface);
- FIXME("(%p)->(%p)\n", This, p);
- return E_NOTIMPL;
+ WARN("(%p)->(%p) semi-stub\n", This, p);
+ return get_style_property_var(This, STYLEID_COLUMN_RULE_WIDTH, p);
}
static HRESULT WINAPI HTMLCSSStyleDeclaration2_put_breakBefore(IHTMLCSSStyleDeclaration2 *iface, BSTR v)
diff --git a/dlls/mshtml/htmlstyle.h b/dlls/mshtml/htmlstyle.h
index 5823ccdf00..c85e2be9e6 100644
--- a/dlls/mshtml/htmlstyle.h
+++ b/dlls/mshtml/htmlstyle.h
@@ -86,6 +86,7 @@ typedef enum {
STYLEID_COLUMN_GAP,
STYLEID_COLUMN_RULE_COLOR,
STYLEID_COLUMN_RULE_STYLE,
+ STYLEID_COLUMN_RULE_WIDTH,
STYLEID_COLUMN_SPAN,
STYLEID_COLUMN_WIDTH,
STYLEID_CURSOR,
diff --git a/dlls/mshtml/tests/style.c b/dlls/mshtml/tests/style.c
index cc6c2ec6f9..f56b68d2b2 100644
--- a/dlls/mshtml/tests/style.c
+++ b/dlls/mshtml/tests/style.c
@@ -1054,6 +1054,25 @@ static void test_css_style_declaration2(IHTMLCSSStyleDeclaration2 *css_style)
todo_wine
ok(str && !lstrcmpW(str, L"solid"), "columnRuleStyle = %s\n", wine_dbgstr_w(str));
SysFreeString(str);
+
+ V_VT(&v) = VT_ERROR;
+ hres = IHTMLCSSStyleDeclaration2_get_columnRuleWidth(css_style, &v);
+ ok(hres == S_OK, "get_columnRuleWidth failed: %08x\n", hres);
+ ok(V_VT(&v) == VT_BSTR && !V_BSTR(&v), "columnRuleWidth = %s\n", wine_dbgstr_variant(&v));
+ VariantClear(&v);
+
+ V_VT(&v) = VT_BSTR;
+ V_BSTR(&v) = SysAllocString(L"10px");
+ hres = IHTMLCSSStyleDeclaration2_put_columnRuleWidth(css_style, v);
+ ok(hres == S_OK, "put_columnRuleWidth failed: %08x\n", hres);
+ VariantClear(&v);
+
+ V_VT(&v) = VT_ERROR;
+ hres = IHTMLCSSStyleDeclaration2_get_columnRuleWidth(css_style, &v);
+ ok(hres == S_OK, "get_columnRuleWidth failed: %08x\n", hres);
+ todo_wine
+ ok(V_VT(&v) == VT_BSTR && V_BSTR(&v) && !lstrcmpW(V_BSTR(&v), L"10px"), "columnRuleWidth = %s\n", wine_dbgstr_variant(&v));
+ VariantClear(&v);
}
static void test_body_style(IHTMLStyle *style)
More information about the wine-cvs
mailing list