mshtml: Added IOmNavigator::get_appVersion implementation.
This commit is contained in:
parent
53d6b6616e
commit
c97d498f40
|
@ -146,8 +146,21 @@ static HRESULT WINAPI OmNavigator_get_appName(IOmNavigator *iface, BSTR *p)
|
|||
static HRESULT WINAPI OmNavigator_get_appVersion(IOmNavigator *iface, BSTR *p)
|
||||
{
|
||||
OmNavigator *This = OMNAVIGATOR_THIS(iface);
|
||||
FIXME("(%p)->(%p)\n", This, p);
|
||||
return E_NOTIMPL;
|
||||
|
||||
/* FIXME: Should we return something smarter? */
|
||||
static const WCHAR app_verW[] =
|
||||
{'4','.','0',' ','(','c','o','m','p','a','t','i','b','l','e',';',
|
||||
' ','M','S','I','E',' ','7','.','0',';',
|
||||
' ','W','i','n','d','o','w','s',' ','N','T',' ','5','.','1',';',
|
||||
' ','M','o','z','i','l','l','a','/','4','.','0',')',0};
|
||||
|
||||
TRACE("(%p)->(%p)\n", This, p);
|
||||
|
||||
*p = SysAllocString(app_verW);
|
||||
if(!*p)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI OmNavigator_get_userAgent(IOmNavigator *iface, BSTR *p)
|
||||
|
|
|
@ -2152,6 +2152,8 @@ static void test_navigator(IHTMLDocument2 *doc)
|
|||
BSTR bstr;
|
||||
HRESULT hres;
|
||||
|
||||
static const WCHAR v40[] = {'4','.','0'};
|
||||
|
||||
hres = IHTMLDocument2_get_parentWindow(doc, &window);
|
||||
ok(hres == S_OK, "parentWidnow failed: %08x\n", hres);
|
||||
|
||||
|
@ -2174,10 +2176,16 @@ static void test_navigator(IHTMLDocument2 *doc)
|
|||
|
||||
bstr = NULL;
|
||||
hres = IOmNavigator_get_platform(navigator, &bstr);
|
||||
ok(hres == S_OK, "get_appMinorVersion failed: %08x\n", hres);
|
||||
ok(hres == S_OK, "get_platform failed: %08x\n", hres);
|
||||
ok(!strcmp_wa(bstr, "Win32"), "unexpected platform %s\n", dbgstr_w(bstr));
|
||||
SysFreeString(bstr);
|
||||
|
||||
bstr = NULL;
|
||||
hres = IOmNavigator_get_appVersion(navigator, &bstr);
|
||||
ok(hres == S_OK, "get_appVersion failed: %08x\n", hres);
|
||||
ok(!memcmp(bstr, v40, sizeof(v40)), "appVersion is %s\n", dbgstr_w(bstr));
|
||||
SysFreeString(bstr);
|
||||
|
||||
ref = IOmNavigator_Release(navigator);
|
||||
ok(!ref, "navigator should be destroyed here\n");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue