mshtml: Added IHTMLPluginsCollection::get_length implementation.
This commit is contained in:
parent
b25d49c6c1
commit
7d4e9f7792
@ -145,8 +145,12 @@ static HRESULT WINAPI HTMLPluginsCollection_Invoke(IHTMLPluginsCollection *iface
|
|||||||
static HRESULT WINAPI HTMLPluginsCollection_get_length(IHTMLPluginsCollection *iface, LONG *p)
|
static HRESULT WINAPI HTMLPluginsCollection_get_length(IHTMLPluginsCollection *iface, LONG *p)
|
||||||
{
|
{
|
||||||
HTMLPluginsCollection *This = impl_from_IHTMLPluginsCollection(iface);
|
HTMLPluginsCollection *This = impl_from_IHTMLPluginsCollection(iface);
|
||||||
FIXME("(%p)->(%p)\n", This, p);
|
|
||||||
return E_NOTIMPL;
|
TRACE("(%p)->(%p)\n", This, p);
|
||||||
|
|
||||||
|
/* IE always returns 0 here */
|
||||||
|
*p = 0;
|
||||||
|
return S_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
static HRESULT WINAPI HTMLPluginsCollection_refresh(IHTMLPluginsCollection *iface, VARIANT_BOOL reload)
|
static HRESULT WINAPI HTMLPluginsCollection_refresh(IHTMLPluginsCollection *iface, VARIANT_BOOL reload)
|
||||||
|
@ -3760,12 +3760,19 @@ static void test_location(IHTMLDocument2 *doc)
|
|||||||
ok(!ref, "location chould be destroyed here\n");
|
ok(!ref, "location chould be destroyed here\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_plugins_col(IOmNavigator *nav)
|
static void test_plugins_col(IHTMLDocument2 *doc)
|
||||||
{
|
{
|
||||||
IHTMLPluginsCollection *col, *col2;
|
IHTMLPluginsCollection *col, *col2;
|
||||||
|
IHTMLWindow2 *window;
|
||||||
|
IOmNavigator *nav;
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
|
LONG len;
|
||||||
HRESULT hres;
|
HRESULT hres;
|
||||||
|
|
||||||
|
window = get_doc_window(doc);
|
||||||
|
hres = IHTMLWindow2_get_navigator(window, &nav);
|
||||||
|
IHTMLWindow2_Release(window);
|
||||||
|
|
||||||
hres = IOmNavigator_get_plugins(nav, &col);
|
hres = IOmNavigator_get_plugins(nav, &col);
|
||||||
ok(hres == S_OK, "get_plugins failed: %08x\n", hres);
|
ok(hres == S_OK, "get_plugins failed: %08x\n", hres);
|
||||||
|
|
||||||
@ -3776,8 +3783,15 @@ static void test_plugins_col(IOmNavigator *nav)
|
|||||||
|
|
||||||
test_disp2((IUnknown*)col, &DIID_DispCPlugins, &IID_IHTMLPluginsCollection, "[object]");
|
test_disp2((IUnknown*)col, &DIID_DispCPlugins, &IID_IHTMLPluginsCollection, "[object]");
|
||||||
|
|
||||||
|
len = 0xdeadbeef;
|
||||||
|
hres = IHTMLPluginsCollection_get_length(col, &len);
|
||||||
|
ok(hres == S_OK, "get_length failed: %08x\n", hres);
|
||||||
|
ok(!len, "length = %d\n", len);
|
||||||
|
|
||||||
ref = IHTMLPluginsCollection_Release(col);
|
ref = IHTMLPluginsCollection_Release(col);
|
||||||
ok(!ref, "ref=%d\n", ref);
|
ok(!ref, "ref=%d\n", ref);
|
||||||
|
|
||||||
|
IOmNavigator_Release(nav);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_mime_types_col(IOmNavigator *nav)
|
static void test_mime_types_col(IOmNavigator *nav)
|
||||||
@ -3892,7 +3906,6 @@ static void test_navigator(IHTMLDocument2 *doc)
|
|||||||
skip("nonstandard user agent\n");
|
skip("nonstandard user agent\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
test_plugins_col(navigator);
|
|
||||||
test_mime_types_col(navigator);
|
test_mime_types_col(navigator);
|
||||||
|
|
||||||
ref = IOmNavigator_Release(navigator);
|
ref = IOmNavigator_Release(navigator);
|
||||||
@ -4263,6 +4276,7 @@ static void test_defaults(IHTMLDocument2 *doc)
|
|||||||
test_compatmode(doc);
|
test_compatmode(doc);
|
||||||
test_location(doc);
|
test_location(doc);
|
||||||
test_navigator(doc);
|
test_navigator(doc);
|
||||||
|
test_plugins_col(doc);
|
||||||
|
|
||||||
elem2 = get_elem2_iface((IUnknown*)elem);
|
elem2 = get_elem2_iface((IUnknown*)elem);
|
||||||
hres = IHTMLElement2_get_currentStyle(elem2, &cstyle);
|
hres = IHTMLElement2_get_currentStyle(elem2, &cstyle);
|
||||||
@ -4653,6 +4667,8 @@ static void test_elems(IHTMLDocument2 *doc)
|
|||||||
IHTMLElementCollection_Release(collection);
|
IHTMLElementCollection_Release(collection);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
test_plugins_col(doc);
|
||||||
|
|
||||||
elem = get_doc_elem(doc);
|
elem = get_doc_elem(doc);
|
||||||
test_elem_all((IUnknown*)elem, all_types+1, sizeof(all_types)/sizeof(all_types[0])-1);
|
test_elem_all((IUnknown*)elem, all_types+1, sizeof(all_types)/sizeof(all_types[0])-1);
|
||||||
IHTMLElement_Release(elem);
|
IHTMLElement_Release(elem);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user