mshtml: Added IHTMLLocation::toString implementation.

This commit is contained in:
Jacek Caban 2012-10-22 11:59:27 +02:00 committed by Alexandre Julliard
parent 8b04ab10b9
commit 610ea94da5
2 changed files with 10 additions and 2 deletions

View File

@ -583,8 +583,10 @@ static HRESULT WINAPI HTMLLocation_assign(IHTMLLocation *iface, BSTR bstr)
static HRESULT WINAPI HTMLLocation_toString(IHTMLLocation *iface, BSTR *String)
{
HTMLLocation *This = impl_from_IHTMLLocation(iface);
FIXME("(%p)->(%p)\n", This, String);
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, String);
return IHTMLLocation_get_href(&This->IHTMLLocation_iface, String);
}
static const IHTMLLocationVtbl HTMLLocationVtbl = {

View File

@ -129,6 +129,12 @@ static void test_href(IHTMLLocation *loc, const struct location_test *test)
"%s: expected retrieved href to be L\"%s\", was: %s\n",
test->name, test->href, wine_dbgstr_w(str));
SysFreeString(str);
hres = IHTMLLocation_toString(loc, &str);
ok(hres == S_OK, "%s: toString failed: 0x%08x\n", test->name, hres);
ok(str_eq_wa(str, test->href), "%s: toString returned %s, expected %s\n",
test->name, wine_dbgstr_w(str), test->href);
SysFreeString(str);
}
static void test_protocol(IHTMLLocation *loc, const struct location_test *test)