From: Mohamad Al-Jaf mohamadaljaf@gmail.com
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=58133 Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=58192 --- dlls/dxcore/dxcore.c | 5 +++-- dlls/dxcore/tests/dxcore.c | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/dlls/dxcore/dxcore.c b/dlls/dxcore/dxcore.c index 1dc984b57b8..2dbf7eb0f34 100644 --- a/dlls/dxcore/dxcore.c +++ b/dlls/dxcore/dxcore.c @@ -227,8 +227,9 @@ static HRESULT WINAPI dxcore_adapter_list_GetAdapter( IDXCoreAdapterList *iface,
static uint32_t WINAPI dxcore_adapter_list_GetAdapterCount( IDXCoreAdapterList *iface ) { - FIXME( "iface %p stub!\n", iface ); - return 0; + struct dxcore_adapter_list *impl = impl_from_IDXCoreAdapterList( iface ); + TRACE( "iface %p\n", iface ); + return impl->adapter_count; }
static BOOL WINAPI dxcore_adapter_list_IsStale( IDXCoreAdapterList *iface ) diff --git a/dlls/dxcore/tests/dxcore.c b/dlls/dxcore/tests/dxcore.c index 796ce11fe00..c85eea9d9d1 100644 --- a/dlls/dxcore/tests/dxcore.c +++ b/dlls/dxcore/tests/dxcore.c @@ -46,6 +46,7 @@ static void test_DXCoreCreateAdapterFactory(void) IDXCoreAdapterFactory *adapter_factory = (void *)0xdeadbeef; IDXCoreAdapterList *adapter_list2 = (void *)0xdeadbeef; IDXCoreAdapterList *adapter_list = (void *)0xdeadbeef; + uint32_t adapter_count = 0; HRESULT hr; LONG ref;
@@ -96,6 +97,9 @@ static void test_DXCoreCreateAdapterFactory(void) check_interface( adapter_list, &IID_IDXCoreAdapter, FALSE ); check_interface( adapter_list, &IID_IDXCoreAdapterFactory, FALSE );
+ adapter_count = IDXCoreAdapterList_GetAdapterCount( adapter_list ); + ok( adapter_count != 0, "IDXCoreAdapterList_GetAdapterCount returned 0.\n" ); + ref = IDXCoreAdapterList_Release( adapter_list ); ok( ref == 0, "got ref %ld.\n", ref ); ref = IDXCoreAdapterFactory_Release( adapter_factory );