Module: wine Branch: master Commit: a8d08e2ad7749b5b97e6cd509854cd21bdef4a17 URL: http://source.winehq.org/git/wine.git/?a=commit;h=a8d08e2ad7749b5b97e6cd5098...
Author: Vincent Povirk vincent@codeweavers.com Date: Thu Nov 6 16:07:54 2014 -0600
windowscodecs: Implement MetadataReaderInfo_GetContainerFormats.
---
dlls/windowscodecs/info.c | 8 +++++--- dlls/windowscodecs/tests/info.c | 2 -- 2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/dlls/windowscodecs/info.c b/dlls/windowscodecs/info.c index d42d726..ea81dba 100644 --- a/dlls/windowscodecs/info.c +++ b/dlls/windowscodecs/info.c @@ -56,6 +56,7 @@ static const WCHAR supportstransparency_valuename[] = {'S','u','p','p','o','r',' static const WCHAR requiresfullstream_valuename[] = {'R','e','q','u','i','r','e','s','F','u','l','l','S','t','r','e','a','m',0}; static const WCHAR supportspadding_valuename[] = {'S','u','p','p','o','r','t','s','P','a','d','d','i','n','g',0}; static const WCHAR fileextensions_valuename[] = {'F','i','l','e','E','x','t','e','n','s','i','o','n','s',0}; +static const WCHAR containers_keyname[] = {'C','o','n','t','a','i','n','e','r','s',0};
static HRESULT ComponentInfo_GetStringValue(HKEY classkey, LPCWSTR value, UINT buffer_size, WCHAR *buffer, UINT *actual_size) @@ -1635,10 +1636,11 @@ static HRESULT WINAPI MetadataReaderInfo_GetMetadataFormat(IWICMetadataReaderInf static HRESULT WINAPI MetadataReaderInfo_GetContainerFormats(IWICMetadataReaderInfo *iface, UINT length, GUID *formats, UINT *actual_length) { - if (!actual_length) return E_INVALIDARG; + MetadataReaderInfo *This = impl_from_IWICMetadataReaderInfo(iface); + TRACE("(%p,%u,%p,%p)\n", iface, length, formats, actual_length);
- FIXME("(%p,%u,%p,%p): stub\n", iface, length, formats, actual_length); - return E_NOTIMPL; + return ComponentInfo_GetGuidList(This->classkey, containers_keyname, length, + formats, actual_length); }
static HRESULT WINAPI MetadataReaderInfo_GetDeviceManufacturer(IWICMetadataReaderInfo *iface, diff --git a/dlls/windowscodecs/tests/info.c b/dlls/windowscodecs/tests/info.c index 5753f6b..98c06ec 100644 --- a/dlls/windowscodecs/tests/info.c +++ b/dlls/windowscodecs/tests/info.c @@ -415,9 +415,7 @@ static void test_reader_info(void)
count = 0xdeadbeef; hr = IWICMetadataReaderInfo_GetContainerFormats(reader_info, 0, NULL, &count); -todo_wine ok(hr == S_OK, "GetContainerFormats failed, hr=%x\n", hr); -todo_wine ok(count == 0, "unexpected count %d\n", count);
hr = IWICMetadataReaderInfo_GetPatterns(reader_info, &GUID_ContainerFormatPng,