Commit 5183ebd8 authored by Alistair Leslie-Hughes's avatar Alistair Leslie-Hughes Committed by Alexandre Julliard

dpnet: Implement IDirectPlay8LobbyClient Initialize.

parent 5f797e6c
...@@ -40,6 +40,10 @@ typedef struct IDirectPlay8LobbyClientImpl ...@@ -40,6 +40,10 @@ typedef struct IDirectPlay8LobbyClientImpl
{ {
IDirectPlay8LobbyClient IDirectPlay8LobbyClient_iface; IDirectPlay8LobbyClient IDirectPlay8LobbyClient_iface;
LONG ref; LONG ref;
PFNDPNMESSAGEHANDLER msghandler;
DWORD flags;
void *usercontext;
} IDirectPlay8LobbyClientImpl; } IDirectPlay8LobbyClientImpl;
static inline IDirectPlay8LobbyClientImpl *impl_from_IDirectPlay8LobbyClient(IDirectPlay8LobbyClient *iface) static inline IDirectPlay8LobbyClientImpl *impl_from_IDirectPlay8LobbyClient(IDirectPlay8LobbyClient *iface)
...@@ -427,9 +431,16 @@ static HRESULT WINAPI lobbyclient_Initialize(IDirectPlay8LobbyClient *iface, voi ...@@ -427,9 +431,16 @@ static HRESULT WINAPI lobbyclient_Initialize(IDirectPlay8LobbyClient *iface, voi
{ {
IDirectPlay8LobbyClientImpl *This = impl_from_IDirectPlay8LobbyClient(iface); IDirectPlay8LobbyClientImpl *This = impl_from_IDirectPlay8LobbyClient(iface);
FIXME("(%p)->(%p %p 0x%08x)\n", This, context, msghandler, flags); TRACE("(%p):(%p,%p,%x)\n", This, context, msghandler, flags);
return E_NOTIMPL; if(!msghandler)
return E_POINTER;
This->usercontext = context;
This->msghandler = msghandler;
This->flags = flags;
return DPN_OK;
} }
static HRESULT WINAPI lobbyclient_EnumLocalPrograms(IDirectPlay8LobbyClient *iface, GUID* guidapplication, static HRESULT WINAPI lobbyclient_EnumLocalPrograms(IDirectPlay8LobbyClient *iface, GUID* guidapplication,
......
...@@ -220,8 +220,11 @@ static void test_lobbyclient(void) ...@@ -220,8 +220,11 @@ static void test_lobbyclient(void)
ok(hr == S_OK, "Failed to create object\n"); ok(hr == S_OK, "Failed to create object\n");
if(SUCCEEDED(hr)) if(SUCCEEDED(hr))
{ {
hr = IDirectPlay8LobbyClient_Initialize(client, NULL, NULL, 0);
ok(hr == E_POINTER, "got 0x%08x\n", hr);
hr = IDirectPlay8LobbyClient_Initialize(client, NULL, DirectPlayLobbyClientMessageHandler, 0); hr = IDirectPlay8LobbyClient_Initialize(client, NULL, DirectPlayLobbyClientMessageHandler, 0);
todo_wine ok(hr == S_OK, "got 0x%08x\n", hr); ok(hr == S_OK, "got 0x%08x\n", hr);
hr = IDirectPlay8LobbyClient_Close(client, 0); hr = IDirectPlay8LobbyClient_Close(client, 0);
todo_wine ok(hr == S_OK, "got 0x%08x\n", hr); todo_wine ok(hr == S_OK, "got 0x%08x\n", hr);
......
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