mirror of
https://github.com/reactos/wine.git
synced 2024-11-25 04:39:45 +00:00
mshtml: Added IHTMLStyle::padding property implementation.
This commit is contained in:
parent
f82668f23e
commit
991104b97f
@ -129,6 +129,8 @@ static const WCHAR attrMinHeight[] =
|
|||||||
{'m','i','n','-','h','e','i','g','h','t',0};
|
{'m','i','n','-','h','e','i','g','h','t',0};
|
||||||
static const WCHAR attrOverflow[] =
|
static const WCHAR attrOverflow[] =
|
||||||
{'o','v','e','r','f','l','o','w',0};
|
{'o','v','e','r','f','l','o','w',0};
|
||||||
|
static const WCHAR attrPadding[] =
|
||||||
|
{'p','a','d','d','i','n','g',0};
|
||||||
static const WCHAR attrPaddingBottom[] =
|
static const WCHAR attrPaddingBottom[] =
|
||||||
{'p','a','d','d','i','n','g','-','b','o','t','t','o','m',0};
|
{'p','a','d','d','i','n','g','-','b','o','t','t','o','m',0};
|
||||||
static const WCHAR attrPaddingLeft[] =
|
static const WCHAR attrPaddingLeft[] =
|
||||||
@ -213,6 +215,7 @@ static const struct{
|
|||||||
{attrMarginTop, DISPID_IHTMLSTYLE_MARGINTOP},
|
{attrMarginTop, DISPID_IHTMLSTYLE_MARGINTOP},
|
||||||
{attrMinHeight, DISPID_IHTMLSTYLE4_MINHEIGHT},
|
{attrMinHeight, DISPID_IHTMLSTYLE4_MINHEIGHT},
|
||||||
{attrOverflow, DISPID_IHTMLSTYLE_OVERFLOW},
|
{attrOverflow, DISPID_IHTMLSTYLE_OVERFLOW},
|
||||||
|
{attrPadding, DISPID_IHTMLSTYLE_PADDING},
|
||||||
{attrPaddingBottom, DISPID_IHTMLSTYLE_PADDINGBOTTOM},
|
{attrPaddingBottom, DISPID_IHTMLSTYLE_PADDINGBOTTOM},
|
||||||
{attrPaddingLeft, DISPID_IHTMLSTYLE_PADDINGLEFT},
|
{attrPaddingLeft, DISPID_IHTMLSTYLE_PADDINGLEFT},
|
||||||
{attrPaddingRight, DISPID_IHTMLSTYLE_PADDINGRIGHT},
|
{attrPaddingRight, DISPID_IHTMLSTYLE_PADDINGRIGHT},
|
||||||
@ -1416,15 +1419,19 @@ static HRESULT WINAPI HTMLStyle_get_paddingLeft(IHTMLStyle *iface, VARIANT *p)
|
|||||||
static HRESULT WINAPI HTMLStyle_put_padding(IHTMLStyle *iface, BSTR v)
|
static HRESULT WINAPI HTMLStyle_put_padding(IHTMLStyle *iface, BSTR v)
|
||||||
{
|
{
|
||||||
HTMLStyle *This = HTMLSTYLE_THIS(iface);
|
HTMLStyle *This = HTMLSTYLE_THIS(iface);
|
||||||
FIXME("(%p)->(%s)\n", This, debugstr_w(v));
|
|
||||||
return E_NOTIMPL;
|
TRACE("(%p)->(%s)\n", This, debugstr_w(v));
|
||||||
|
|
||||||
|
return set_style_attr(This, STYLEID_PADDING, v, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
static HRESULT WINAPI HTMLStyle_get_padding(IHTMLStyle *iface, BSTR *p)
|
static HRESULT WINAPI HTMLStyle_get_padding(IHTMLStyle *iface, BSTR *p)
|
||||||
{
|
{
|
||||||
HTMLStyle *This = HTMLSTYLE_THIS(iface);
|
HTMLStyle *This = HTMLSTYLE_THIS(iface);
|
||||||
FIXME("(%p)->(%p)\n", This, p);
|
|
||||||
return E_NOTIMPL;
|
TRACE("(%p)->(%p)\n", This, p);
|
||||||
|
|
||||||
|
return get_style_attr(This, STYLEID_PADDING, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
static HRESULT WINAPI HTMLStyle_put_border(IHTMLStyle *iface, BSTR v)
|
static HRESULT WINAPI HTMLStyle_put_border(IHTMLStyle *iface, BSTR v)
|
||||||
|
@ -82,6 +82,7 @@ typedef enum {
|
|||||||
STYLEID_MARGIN_TOP,
|
STYLEID_MARGIN_TOP,
|
||||||
STYLEID_MIN_HEIGHT,
|
STYLEID_MIN_HEIGHT,
|
||||||
STYLEID_OVERFLOW,
|
STYLEID_OVERFLOW,
|
||||||
|
STYLEID_PADDING,
|
||||||
STYLEID_PADDING_BOTTOM,
|
STYLEID_PADDING_BOTTOM,
|
||||||
STYLEID_PADDING_LEFT,
|
STYLEID_PADDING_LEFT,
|
||||||
STYLEID_PADDING_RIGHT,
|
STYLEID_PADDING_RIGHT,
|
||||||
|
@ -4976,6 +4976,22 @@ static void test_default_style(IHTMLStyle *style)
|
|||||||
ok(!V_BSTR(&v), "str=%s\n", wine_dbgstr_w(V_BSTR(&v)));
|
ok(!V_BSTR(&v), "str=%s\n", wine_dbgstr_w(V_BSTR(&v)));
|
||||||
VariantClear(&v);
|
VariantClear(&v);
|
||||||
|
|
||||||
|
/* padding */
|
||||||
|
hres = IHTMLStyle_get_padding(style, &str);
|
||||||
|
ok(hres == S_OK, "get_padding failed: %08x\n", hres);
|
||||||
|
ok(!str, "padding = %s\n", wine_dbgstr_w(str));
|
||||||
|
SysFreeString(str);
|
||||||
|
|
||||||
|
str = a2bstr("1");
|
||||||
|
hres = IHTMLStyle_put_padding(style, str);
|
||||||
|
ok(hres == S_OK, "put_padding failed: %08x\n", hres);
|
||||||
|
SysFreeString(str);
|
||||||
|
|
||||||
|
hres = IHTMLStyle_get_padding(style, &str);
|
||||||
|
ok(hres == S_OK, "get_padding failed: %08x\n", hres);
|
||||||
|
ok(!strcmp_wa(str, "1px"), "padding = %s\n", wine_dbgstr_w(str));
|
||||||
|
SysFreeString(str);
|
||||||
|
|
||||||
/* PaddingLeft */
|
/* PaddingLeft */
|
||||||
hres = IHTMLStyle_get_paddingLeft(style, &vDefault);
|
hres = IHTMLStyle_get_paddingLeft(style, &vDefault);
|
||||||
ok(hres == S_OK, "get_paddingLeft: %08x\n", hres);
|
ok(hres == S_OK, "get_paddingLeft: %08x\n", hres);
|
||||||
|
Loading…
Reference in New Issue
Block a user