Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/windows.globalization/main.c | 6 ++-- .../tests/globalization.c | 36 ++++++++++++++++++- 2 files changed, 38 insertions(+), 4 deletions(-)
diff --git a/dlls/windows.globalization/main.c b/dlls/windows.globalization/main.c index 0b60add92f4..8a6775813f4 100644 --- a/dlls/windows.globalization/main.c +++ b/dlls/windows.globalization/main.c @@ -375,21 +375,21 @@ static HRESULT STDMETHODCALLTYPE globalization_preferences_get_Calendars( IGlobalizationPreferencesStatics *iface, IVectorView_HSTRING **out) { FIXME("iface %p, out %p stub!\n", iface, out); - return E_NOTIMPL; + return hstring_vector_create(NULL, 0, out); }
static HRESULT STDMETHODCALLTYPE globalization_preferences_get_Clocks( IGlobalizationPreferencesStatics *iface, IVectorView_HSTRING **out) { FIXME("iface %p, out %p stub!\n", iface, out); - return E_NOTIMPL; + return hstring_vector_create(NULL, 0, out); }
static HRESULT STDMETHODCALLTYPE globalization_preferences_get_Currencies( IGlobalizationPreferencesStatics *iface, IVectorView_HSTRING **out) { FIXME("iface %p, out %p stub!\n", iface, out); - return E_NOTIMPL; + return hstring_vector_create(NULL, 0, out); }
static HRESULT STDMETHODCALLTYPE globalization_preferences_get_Languages( diff --git a/dlls/windows.globalization/tests/globalization.c b/dlls/windows.globalization/tests/globalization.c index a2b47e53be5..b824cfdf8ae 100644 --- a/dlls/windows.globalization/tests/globalization.c +++ b/dlls/windows.globalization/tests/globalization.c @@ -47,7 +47,7 @@ static void test_GlobalizationPreferences(void) static const WCHAR *class_name = L"Windows.System.UserProfile.GlobalizationPreferences";
IGlobalizationPreferencesStatics *preferences_statics = NULL; - IVectorView_HSTRING *languages = NULL; + IVectorView_HSTRING *languages = NULL, *calendars, *clocks, *currencies; IActivationFactory *factory = NULL; IInspectable *inspectable = NULL, *tmp_inspectable = NULL; IAgileObject *agile_object = NULL, *tmp_agile_object = NULL; @@ -178,6 +178,40 @@ static void test_GlobalizationPreferences(void)
IVectorView_HSTRING_Release(languages);
+ + hr = IGlobalizationPreferencesStatics_get_Calendars(preferences_statics, &calendars); + ok(hr == S_OK, "IGlobalizationPreferencesStatics_get_Calendars failed, hr %#x\n", hr); + + size = 0xdeadbeef; + hr = IVectorView_HSTRING_get_Size(calendars, &size); + ok(hr == S_OK, "IVectorView_HSTRING_get_Size failed, hr %#x\n", hr); + todo_wine ok(size != 0 && size != 0xdeadbeef, "IVectorView_HSTRING_get_Size returned %u\n", size); + + IVectorView_HSTRING_Release(calendars); + + + hr = IGlobalizationPreferencesStatics_get_Clocks(preferences_statics, &clocks); + ok(hr == S_OK, "IGlobalizationPreferencesStatics_get_Clocks failed, hr %#x\n", hr); + + size = 0xdeadbeef; + hr = IVectorView_HSTRING_get_Size(clocks, &size); + ok(hr == S_OK, "IVectorView_HSTRING_get_Size failed, hr %#x\n", hr); + todo_wine ok(size != 0 && size != 0xdeadbeef, "IVectorView_HSTRING_get_Size returned %u\n", size); + + IVectorView_HSTRING_Release(clocks); + + + hr = IGlobalizationPreferencesStatics_get_Currencies(preferences_statics, ¤cies); + ok(hr == S_OK, "IGlobalizationPreferencesStatics_get_Currencies failed, hr %#x\n", hr); + + size = 0xdeadbeef; + hr = IVectorView_HSTRING_get_Size(currencies, &size); + ok(hr == S_OK, "IVectorView_HSTRING_get_Size failed, hr %#x\n", hr); + todo_wine ok(size != 0 && size != 0xdeadbeef, "IVectorView_HSTRING_get_Size returned %u\n", size); + + IVectorView_HSTRING_Release(currencies); + + IGlobalizationPreferencesStatics_Release(preferences_statics);
IAgileObject_Release(agile_object);