diff --git a/dlls/mshtml/htmlstyle.c b/dlls/mshtml/htmlstyle.c
index 82d48690761..a199a3cbb8f 100644
--- a/dlls/mshtml/htmlstyle.c
+++ b/dlls/mshtml/htmlstyle.c
@@ -43,6 +43,8 @@ static const WCHAR attrBackgroundImage[] =
{'b','a','c','k','g','r','o','u','n','d','-','i','m','a','g','e',0};
static const WCHAR attrBackgroundPositionX[] =
{'b','a','c','k','g','r','o','u','n','d','-','p','o','s','i','t','i','o','n','-','x',0};
+static const WCHAR attrBackgroundPositionY[] =
+ {'b','a','c','k','g','r','o','u','n','d','-','p','o','s','i','t','i','o','n','-','y',0};
static const WCHAR attrBackgroundRepeat[] =
{'b','a','c','k','g','r','o','u','n','d','-','r','e','p','e','a','t',0};
static const WCHAR attrBorder[] =
@@ -122,6 +124,7 @@ static const struct{
{attrBackgroundColor, DISPID_IHTMLSTYLE_BACKGROUNDCOLOR},
{attrBackgroundImage, DISPID_IHTMLSTYLE_BACKGROUNDIMAGE},
{attrBackgroundPositionX, DISPID_IHTMLSTYLE_BACKGROUNDPOSITIONX},
+ {attrBackgroundPositionY, DISPID_IHTMLSTYLE_BACKGROUNDPOSITIONY},
{attrBackgroundRepeat, DISPID_IHTMLSTYLE_BACKGROUNDREPEAT},
{attrBorder, DISPID_IHTMLSTYLE_BORDER},
{attrBorderBottomStyle, DISPID_IHTMLSTYLE_BORDERBOTTOMSTYLE},
@@ -891,15 +894,15 @@ static HRESULT WINAPI HTMLStyle_get_backgroundPositionX(IHTMLStyle *iface, VARIA
static HRESULT WINAPI HTMLStyle_put_backgroundPositionY(IHTMLStyle *iface, VARIANT v)
{
HTMLStyle *This = HTMLSTYLE_THIS(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_BACKGROUND_POSITION_Y, &v, 0);
}
static HRESULT WINAPI HTMLStyle_get_backgroundPositionY(IHTMLStyle *iface, VARIANT *p)
{
HTMLStyle *This = HTMLSTYLE_THIS(iface);
- FIXME("(%p)->(%p)\n", This, p);
- return E_NOTIMPL;
+ TRACE("(%p)->(%p)\n", This, p);
+ return get_nsstyle_attr_var(This->nsstyle, STYLEID_BACKGROUND_POSITION_Y, p, 0);
}
static HRESULT WINAPI HTMLStyle_put_wordSpacing(IHTMLStyle *iface, VARIANT v)
diff --git a/dlls/mshtml/htmlstyle.h b/dlls/mshtml/htmlstyle.h
index 407a4abdc48..b5fa2306a08 100644
--- a/dlls/mshtml/htmlstyle.h
+++ b/dlls/mshtml/htmlstyle.h
@@ -39,6 +39,7 @@ typedef enum {
STYLEID_BACKGROUND_COLOR,
STYLEID_BACKGROUND_IMAGE,
STYLEID_BACKGROUND_POSITION_X,
+ STYLEID_BACKGROUND_POSITION_Y,
STYLEID_BACKGROUND_REPEAT,
STYLEID_BORDER,
STYLEID_BORDER_BOTTOM_STYLE,
diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c
index 2a6758531d5..50f55b18cdc 100644
--- a/dlls/mshtml/tests/dom.c
+++ b/dlls/mshtml/tests/dom.c
@@ -3448,6 +3448,25 @@ static void test_default_style(IHTMLStyle *style)
ok(hres == S_OK, "put_backgroundPositionX failed: %08x\n", hres);
VariantClear(&vDefault);
+ /* backgroundPositionY */
+ hres = IHTMLStyle_get_backgroundPositionY(style, &vDefault);
+ ok(hres == S_OK, "get_backgroundPositionY failed: %08x\n", hres);
+
+ V_VT(&v) = VT_BSTR;
+ V_BSTR(&v) = a2bstr("10px");
+ hres = IHTMLStyle_put_backgroundPositionY(style, v);
+ ok(hres == S_OK, "put_backgroundPositionY failed: %08x\n", hres);
+ VariantClear(&v);
+
+ hres = IHTMLStyle_get_backgroundPositionY(style, &v);
+ ok(hres == S_OK, "get_backgroundPositionY failed: %08x\n", hres);
+ ok(V_VT(&v) == VT_BSTR, "V_VT(v)=%d\n", V_VT(&v));
+ VariantClear(&v);
+
+ hres = IHTMLStyle_put_backgroundPositionY(style, vDefault);
+ ok(hres == S_OK, "put_backgroundPositionY failed: %08x\n", hres);
+ VariantClear(&vDefault);
+
hres = IHTMLStyle_QueryInterface(style, &IID_IHTMLStyle2, (void**)&style2);
ok(hres == S_OK, "Could not get IHTMLStyle2 iface: %08x\n", hres);
if(SUCCEEDED(hres)) {