From 78110088d421af54f01725b2f2eaecdefa76a3c9 Mon Sep 17 00:00:00 2001 From: Andrew Nguyen Date: Tue, 15 Feb 2011 12:36:28 -0600 Subject: [PATCH] propsys: Add a PSRefreshPropertySchema stub. --- dlls/propsys/propsys.spec | 2 +- dlls/propsys/propsys_main.c | 6 ++++++ dlls/propsys/tests/propsys.c | 19 +++++++++++++++++++ include/propsys.idl | 1 + 4 files changed, 27 insertions(+), 1 deletion(-) diff --git a/dlls/propsys/propsys.spec b/dlls/propsys/propsys.spec index 3e99b94c976..3726facc089 100644 --- a/dlls/propsys/propsys.spec +++ b/dlls/propsys/propsys.spec @@ -88,7 +88,7 @@ @ stub PSGetPropertyValue @ stub PSLookupPropertyHandlerCLSID @ stdcall PSPropertyKeyFromString(wstr ptr) -@ stub PSRefreshPropertySchema +@ stdcall PSRefreshPropertySchema() @ stdcall PSRegisterPropertySchema(wstr) @ stub PSSetPropertyValue @ stdcall PSStringFromPropertyKey(ptr ptr long) diff --git a/dlls/propsys/propsys_main.c b/dlls/propsys/propsys_main.c index 631c49ea54e..3c2c3ed4450 100644 --- a/dlls/propsys/propsys_main.c +++ b/dlls/propsys/propsys_main.c @@ -72,6 +72,12 @@ HRESULT WINAPI PSGetPropertyDescription(REFPROPERTYKEY propkey, REFIID riid, voi return E_NOTIMPL; } +HRESULT WINAPI PSRefreshPropertySchema(void) +{ + FIXME("\n"); + return S_OK; +} + HRESULT WINAPI PSStringFromPropertyKey(REFPROPERTYKEY pkey, LPWSTR psz, UINT cch) { static const WCHAR guid_fmtW[] = {'{','%','0','8','X','-','%','0','4','X','-', diff --git a/dlls/propsys/tests/propsys.c b/dlls/propsys/tests/propsys.c index d734029149d..e0895f3b607 100644 --- a/dlls/propsys/tests/propsys.c +++ b/dlls/propsys/tests/propsys.c @@ -432,8 +432,27 @@ static void test_PSPropertyKeyFromString(void) } } +static void test_PSRefreshPropertySchema(void) +{ + HRESULT ret; + + ret = PSRefreshPropertySchema(); + todo_wine + ok(ret == CO_E_NOTINITIALIZED, + "Expected PSRefreshPropertySchema to return CO_E_NOTINITIALIZED, got 0x%08x\n", ret); + + CoInitialize(NULL); + + ret = PSRefreshPropertySchema(); + ok(ret == S_OK, + "Expected PSRefreshPropertySchema to return S_OK, got 0x%08x\n", ret); + + CoUninitialize(); +} + START_TEST(propsys) { test_PSStringFromPropertyKey(); test_PSPropertyKeyFromString(); + test_PSRefreshPropertySchema(); } diff --git a/include/propsys.idl b/include/propsys.idl index ef9ecfc912a..993686de1bb 100644 --- a/include/propsys.idl +++ b/include/propsys.idl @@ -802,6 +802,7 @@ cpp_quote("#define PKEYSTR_MAX (GUIDSTRING_MAX + 1 + PKEY_PIDSTR_MAX)") cpp_quote("HRESULT WINAPI PSStringFromPropertyKey(REFPROPERTYKEY,LPWSTR,UINT);") cpp_quote("HRESULT WINAPI PSPropertyKeyFromString(LPCWSTR,PROPERTYKEY*);") cpp_quote("HRESULT WINAPI PSGetPropertyDescription(REFPROPERTYKEY,REFIID,void **);") +cpp_quote("HRESULT WINAPI PSRefreshPropertySchema(void);") /* TODO: Add remainder of the C api here */