Commit c7cb9f75 authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

mshtml: Added HTMLAttributeCollection2_getNamedItem implementation.

parent 130c8342
...@@ -2403,8 +2403,26 @@ static HRESULT WINAPI HTMLAttributeCollection2_getNamedItem(IHTMLAttributeCollec ...@@ -2403,8 +2403,26 @@ static HRESULT WINAPI HTMLAttributeCollection2_getNamedItem(IHTMLAttributeCollec
IHTMLDOMAttribute **newretNode) IHTMLDOMAttribute **newretNode)
{ {
HTMLAttributeCollection *This = impl_from_IHTMLAttributeCollection2(iface); HTMLAttributeCollection *This = impl_from_IHTMLAttributeCollection2(iface);
FIXME("(%p)->(%s %p)\n", This, debugstr_w(bstrName), newretNode); HTMLDOMAttribute *attr;
return E_NOTIMPL; DISPID id;
HRESULT hres;
TRACE("(%p)->(%s %p)\n", This, debugstr_w(bstrName), newretNode);
hres = get_attr_dispid_by_name(This, bstrName, &id);
if(hres == DISP_E_UNKNOWNNAME) {
*newretNode = NULL;
return S_OK;
} else if(FAILED(hres)) {
return hres;
}
hres = get_domattr(This->elem, id, &attr);
if(FAILED(hres))
return hres;
*newretNode = &attr->IHTMLDOMAttribute_iface;
return S_OK;
} }
static HRESULT WINAPI HTMLAttributeCollection2_setNamedItem(IHTMLAttributeCollection2 *iface, static HRESULT WINAPI HTMLAttributeCollection2_setNamedItem(IHTMLAttributeCollection2 *iface,
...@@ -2493,8 +2511,7 @@ static HRESULT WINAPI HTMLAttributeCollection3_getNamedItem(IHTMLAttributeCollec ...@@ -2493,8 +2511,7 @@ static HRESULT WINAPI HTMLAttributeCollection3_getNamedItem(IHTMLAttributeCollec
IHTMLDOMAttribute **ppNodeOut) IHTMLDOMAttribute **ppNodeOut)
{ {
HTMLAttributeCollection *This = impl_from_IHTMLAttributeCollection3(iface); HTMLAttributeCollection *This = impl_from_IHTMLAttributeCollection3(iface);
FIXME("(%p)->(%s %p)\n", This, debugstr_w(bstrName), ppNodeOut); return IHTMLAttributeCollection2_getNamedItem(&This->IHTMLAttributeCollection2_iface, bstrName, ppNodeOut);
return E_NOTIMPL;
} }
static HRESULT WINAPI HTMLAttributeCollection3_setNamedItem(IHTMLAttributeCollection3 *iface, static HRESULT WINAPI HTMLAttributeCollection3_setNamedItem(IHTMLAttributeCollection3 *iface,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment