From fc4482815c00a3b5da8f3b17a55c3bcead36b136 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Iv=C4=83ncescu?= Date: Thu, 7 Oct 2021 16:52:34 +0300 Subject: [PATCH] mshtml: Implement HTMLStyle's toString. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Gabriel Ivăncescu Signed-off-by: Jacek Caban Signed-off-by: Alexandre Julliard --- dlls/mshtml/htmlstyle.c | 6 ++++-- dlls/mshtml/tests/documentmode.js | 1 + 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c index 7dd7000bab0..2cbd8a55789 100644 --- a/dlls/mshtml/htmlstyle.c +++ b/dlls/mshtml/htmlstyle.c @@ -3025,8 +3025,10 @@ static HRESULT WINAPI HTMLStyle_removeAttribute(IHTMLStyle *iface, BSTR strAttri static HRESULT WINAPI HTMLStyle_toString(IHTMLStyle *iface, BSTR *String) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, String); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, String); + + return dispex_to_string(&This->css_style.dispex, String); } static const IHTMLStyleVtbl HTMLStyleVtbl = { diff --git a/dlls/mshtml/tests/documentmode.js b/dlls/mshtml/tests/documentmode.js index cf0d7bf0f4b..91e50c76fc0 100644 --- a/dlls/mshtml/tests/documentmode.js +++ b/dlls/mshtml/tests/documentmode.js @@ -218,6 +218,7 @@ sync_test("builtin_toString", function() { test("navigator", window.navigator, "Navigator"); test("screen", window.screen, "Screen"); test("sessionStorage", window.sessionStorage, "Storage"); + test("style", document.body.style, "MSStyleCSSProperties"); test("styleSheet", sheet, "CSSStyleSheet"); test("styleSheetRule", sheet.rules.item(0), "CSSStyleRule"); test("styleSheetRules", sheet.rules, "MSCSSRuleList");