Module: wine Branch: master Commit: 26380e1720db6c759fe1e236d77295e88ad5d0f7 URL: http://source.winehq.org/git/wine.git/?a=commit;h=26380e1720db6c759fe1e236d7...
Author: Alistair Leslie-Hughes leslie_alistair@hotmail.com Date: Mon Feb 7 13:38:19 2011 +1100
mshtml: Implement IHTMLStyle put_borderRightColor.
---
dlls/mshtml/htmlstyle.c | 6 ++++-- dlls/mshtml/tests/dom.c | 18 ++++++++++++++++++ 2 files changed, 22 insertions(+), 2 deletions(-)
diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c index 3a976cd..45efd95 100644 --- a/dlls/mshtml/htmlstyle.c +++ b/dlls/mshtml/htmlstyle.c @@ -1559,8 +1559,10 @@ static HRESULT WINAPI HTMLStyle_get_borderTopColor(IHTMLStyle *iface, VARIANT *p static HRESULT WINAPI HTMLStyle_put_borderRightColor(IHTMLStyle *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(v%d)\n", This, V_VT(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(v%d)\n", This, V_VT(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_BORDER_RIGHT_COLOR, &v, ATTR_HEX_INT); }
static HRESULT WINAPI HTMLStyle_get_borderRightColor(IHTMLStyle *iface, VARIANT *p) diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c index 9cc25a3..b5babed 100644 --- a/dlls/mshtml/tests/dom.c +++ b/dlls/mshtml/tests/dom.c @@ -5461,6 +5461,24 @@ static void test_default_style(IHTMLStyle *style) hres = IHTMLStyle_put_borderTopColor(style, vDefault); ok(hres == S_OK, "put_borderTopColor: %08x\n", hres);
+ /* borderRightColor */ + hres = IHTMLStyle_get_borderRightColor(style, &vDefault); + ok(hres == S_OK, "get_borderRightColor: %08x\n", hres); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("blue"); + hres = IHTMLStyle_put_borderRightColor(style, v); + ok(hres == S_OK, "put_borderRightColor: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle_get_borderRightColor(style, &v); + ok(hres == S_OK, "get_borderRightColor: %08x\n", hres); + ok(!strcmp_wa(V_BSTR(&v), "blue"), "expected blue = %s\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + hres = IHTMLStyle_put_borderRightColor(style, vDefault); + ok(hres == S_OK, "putborderRightColorr: %08x\n", hres); + hres = IHTMLStyle_QueryInterface(style, &IID_IHTMLStyle2, (void**)&style2); ok(hres == S_OK, "Could not get IHTMLStyle2 iface: %08x\n", hres); if(SUCCEEDED(hres)) {