winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
November 2012
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
708 discussions
Start a n
N
ew thread
Hans Leidekker : windowscodecs: Implement IWICColorContext:: InitializeFromMemory.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: 7712c0e8cd7061e6abf3ab5ab1049b55e8949f8a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7712c0e8cd7061e6abf3ab5ab…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Thu Nov 15 14:07:49 2012 +0100 windowscodecs: Implement IWICColorContext::InitializeFromMemory. --- dlls/windowscodecs/colorcontext.c | 22 ++++++++++++++++++++-- 1 files changed, 20 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/colorcontext.c b/dlls/windowscodecs/colorcontext.c index 1c772c0..2678fc2 100644 --- a/dlls/windowscodecs/colorcontext.c +++ b/dlls/windowscodecs/colorcontext.c @@ -37,6 +37,8 @@ typedef struct ColorContext { IWICColorContext IWICColorContext_iface; LONG ref; WICColorContextType type; + BYTE *profile; + UINT profile_len; } ColorContext; static inline ColorContext *impl_from_IWICColorContext(IWICColorContext *iface) @@ -86,6 +88,7 @@ static ULONG WINAPI ColorContext_Release(IWICColorContext *iface) if (ref == 0) { + HeapFree(GetProcessHeap(), 0, This->profile); HeapFree(GetProcessHeap(), 0, This); } @@ -102,8 +105,21 @@ static HRESULT WINAPI ColorContext_InitializeFromFilename(IWICColorContext *ifac static HRESULT WINAPI ColorContext_InitializeFromMemory(IWICColorContext *iface, const BYTE *pbBuffer, UINT cbBufferSize) { - FIXME("(%p,%p,%u)\n", iface, pbBuffer, cbBufferSize); - return E_NOTIMPL; + ColorContext *This = impl_from_IWICColorContext(iface); + TRACE("(%p,%p,%u)\n", iface, pbBuffer, cbBufferSize); + + if (This->type != WICColorContextUninitialized) + return WINCODEC_ERR_WRONGSTATE; + + HeapFree(GetProcessHeap(), 0, This->profile); + if (!(This->profile = HeapAlloc(GetProcessHeap(), 0, cbBufferSize))) + return E_OUTOFMEMORY; + + memcpy(This->profile, pbBuffer, cbBufferSize); + This->profile_len = cbBufferSize; + This->type = WICColorContextProfile; + + return S_OK; } static HRESULT WINAPI ColorContext_InitializeFromExifColorSpace(IWICColorContext *iface, @@ -159,6 +175,8 @@ HRESULT ColorContext_Create(IWICColorContext **colorcontext) This->IWICColorContext_iface.lpVtbl = &ColorContext_Vtbl; This->ref = 1; This->type = 0; + This->profile = NULL; + This->profile_len = 0; *colorcontext = &This->IWICColorContext_iface;
1
0
0
0
Hans Leidekker : windowscodecs: Implement IWICColorContext::GetType.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: c9acbecdf0780c3bcb61a6dae48ab6345994c376 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c9acbecdf0780c3bcb61a6dae…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Thu Nov 15 14:07:23 2012 +0100 windowscodecs: Implement IWICColorContext::GetType. --- dlls/windowscodecs/colorcontext.c | 9 +++++++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/colorcontext.c b/dlls/windowscodecs/colorcontext.c index 9517988..1c772c0 100644 --- a/dlls/windowscodecs/colorcontext.c +++ b/dlls/windowscodecs/colorcontext.c @@ -36,6 +36,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); typedef struct ColorContext { IWICColorContext IWICColorContext_iface; LONG ref; + WICColorContextType type; } ColorContext; static inline ColorContext *impl_from_IWICColorContext(IWICColorContext *iface) @@ -115,8 +116,11 @@ static HRESULT WINAPI ColorContext_InitializeFromExifColorSpace(IWICColorContext static HRESULT WINAPI ColorContext_GetType(IWICColorContext *iface, WICColorContextType *pType) { - FIXME("(%p,%p)\n", iface, pType); - return E_NOTIMPL; + ColorContext *This = impl_from_IWICColorContext(iface); + TRACE("(%p,%p)\n", iface, pType); + + *pType = This->type; + return S_OK; } static HRESULT WINAPI ColorContext_GetProfileBytes(IWICColorContext *iface, @@ -154,6 +158,7 @@ HRESULT ColorContext_Create(IWICColorContext **colorcontext) This->IWICColorContext_iface.lpVtbl = &ColorContext_Vtbl; This->ref = 1; + This->type = 0; *colorcontext = &This->IWICColorContext_iface;
1
0
0
0
Hans Leidekker : windowscodecs: Implement IWICBitmapFrameDecode:: GetColorContexts for PNG images.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: cfb91803c28d6de75cedca90c1f1eb903ee8c6e7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=cfb91803c28d6de75cedca90c…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Thu Nov 15 14:07:00 2012 +0100 windowscodecs: Implement IWICBitmapFrameDecode::GetColorContexts for PNG images. --- dlls/windowscodecs/pngformat.c | 35 ++++++++++++++++++++++++++++++++--- 1 files changed, 32 insertions(+), 3 deletions(-) diff --git a/dlls/windowscodecs/pngformat.c b/dlls/windowscodecs/pngformat.c index 686f9c6..89f092e 100644 --- a/dlls/windowscodecs/pngformat.c +++ b/dlls/windowscodecs/pngformat.c @@ -166,6 +166,7 @@ MAKE_FUNCPTR(png_error); MAKE_FUNCPTR(png_get_bit_depth); MAKE_FUNCPTR(png_get_color_type); MAKE_FUNCPTR(png_get_error_ptr); +MAKE_FUNCPTR(png_get_iCCP); MAKE_FUNCPTR(png_get_image_height); MAKE_FUNCPTR(png_get_image_width); MAKE_FUNCPTR(png_get_io_ptr); @@ -213,6 +214,7 @@ static void *load_libpng(void) LOAD_FUNCPTR(png_get_bit_depth); LOAD_FUNCPTR(png_get_color_type); LOAD_FUNCPTR(png_get_error_ptr); + LOAD_FUNCPTR(png_get_iCCP); LOAD_FUNCPTR(png_get_image_height); LOAD_FUNCPTR(png_get_image_width); LOAD_FUNCPTR(png_get_io_ptr); @@ -624,7 +626,7 @@ static HRESULT WINAPI PngDecoder_GetPreview(IWICBitmapDecoder *iface, static HRESULT WINAPI PngDecoder_GetColorContexts(IWICBitmapDecoder *iface, UINT cCount, IWICColorContext **ppIColorContexts, UINT *pcActualCount) { - FIXME("(%p,%u,%p,%p)\n", iface, cCount, ppIColorContexts, pcActualCount); + TRACE("(%p,%u,%p,%p)\n", iface, cCount, ppIColorContexts, pcActualCount); return WINCODEC_ERR_UNSUPPORTEDOPERATION; } @@ -844,8 +846,35 @@ static HRESULT WINAPI PngDecoder_Frame_GetMetadataQueryReader(IWICBitmapFrameDec static HRESULT WINAPI PngDecoder_Frame_GetColorContexts(IWICBitmapFrameDecode *iface, UINT cCount, IWICColorContext **ppIColorContexts, UINT *pcActualCount) { - FIXME("(%p,%u,%p,%p): stub\n", iface, cCount, ppIColorContexts, pcActualCount); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; + PngDecoder *This = impl_from_IWICBitmapFrameDecode(iface); + png_charp name, profile; + png_uint_32 len; + int compression_type; + HRESULT hr; + + TRACE("(%p,%u,%p,%p)\n", iface, cCount, ppIColorContexts, pcActualCount); + + EnterCriticalSection(&This->lock); + + if (ppng_get_iCCP(This->png_ptr, This->info_ptr, &name, &compression_type, &profile, &len)) + { + if (cCount && ppIColorContexts) + { + hr = IWICColorContext_InitializeFromMemory(*ppIColorContexts, (const BYTE *)profile, len); + if (FAILED(hr)) + { + LeaveCriticalSection(&This->lock); + return hr; + } + } + *pcActualCount = 1; + } + else + *pcActualCount = 0; + + LeaveCriticalSection(&This->lock); + + return S_OK; } static HRESULT WINAPI PngDecoder_Frame_GetThumbnail(IWICBitmapFrameDecode *iface,
1
0
0
0
Hans Leidekker : windowscodecs: Add a stub IWICColorContext implementation.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: 96ebc618b5029723d1f2401dc54e5e0fac5e060f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=96ebc618b5029723d1f2401dc…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Thu Nov 15 14:06:25 2012 +0100 windowscodecs: Add a stub IWICColorContext implementation. --- dlls/windowscodecs/Makefile.in | 1 + dlls/windowscodecs/colorcontext.c | 161 ++++++++++++++++++++++++++++++++ dlls/windowscodecs/imgfactory.c | 4 +- dlls/windowscodecs/wincodecs_private.h | 1 + 4 files changed, 165 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/Makefile.in b/dlls/windowscodecs/Makefile.in index 65cd913..d031daa 100644 --- a/dlls/windowscodecs/Makefile.in +++ b/dlls/windowscodecs/Makefile.in @@ -10,6 +10,7 @@ C_SRCS = \ bmpdecode.c \ bmpencode.c \ clsfactory.c \ + colorcontext.c \ converter.c \ fliprotate.c \ gifformat.c \ diff --git a/dlls/windowscodecs/colorcontext.c b/dlls/windowscodecs/colorcontext.c new file mode 100644 index 0000000..9517988 --- /dev/null +++ b/dlls/windowscodecs/colorcontext.c @@ -0,0 +1,161 @@ +/* + * Copyright 2012 Hans Leidekker for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" + +#include <stdarg.h> + +#define COBJMACROS + +#include "windef.h" +#include "winbase.h" +#include "objbase.h" +#include "wincodec.h" + +#include "wincodecs_private.h" + +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); + +typedef struct ColorContext { + IWICColorContext IWICColorContext_iface; + LONG ref; +} ColorContext; + +static inline ColorContext *impl_from_IWICColorContext(IWICColorContext *iface) +{ + return CONTAINING_RECORD(iface, ColorContext, IWICColorContext_iface); +} + +static HRESULT WINAPI ColorContext_QueryInterface(IWICColorContext *iface, REFIID iid, + void **ppv) +{ + ColorContext *This = impl_from_IWICColorContext(iface); + TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); + + if (!ppv) return E_INVALIDARG; + + if (IsEqualIID(&IID_IUnknown, iid) || + IsEqualIID(&IID_IWICColorContext, iid)) + { + *ppv = &This->IWICColorContext_iface; + } + else + { + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI ColorContext_AddRef(IWICColorContext *iface) +{ + ColorContext *This = impl_from_IWICColorContext(iface); + ULONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) refcount=%u\n", iface, ref); + + return ref; +} + +static ULONG WINAPI ColorContext_Release(IWICColorContext *iface) +{ + ColorContext *This = impl_from_IWICColorContext(iface); + ULONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) refcount=%u\n", iface, ref); + + if (ref == 0) + { + HeapFree(GetProcessHeap(), 0, This); + } + + return ref; +} + +static HRESULT WINAPI ColorContext_InitializeFromFilename(IWICColorContext *iface, + LPCWSTR wzFilename) +{ + FIXME("(%p,%s)\n", iface, debugstr_w(wzFilename)); + return E_NOTIMPL; +} + +static HRESULT WINAPI ColorContext_InitializeFromMemory(IWICColorContext *iface, + const BYTE *pbBuffer, UINT cbBufferSize) +{ + FIXME("(%p,%p,%u)\n", iface, pbBuffer, cbBufferSize); + return E_NOTIMPL; +} + +static HRESULT WINAPI ColorContext_InitializeFromExifColorSpace(IWICColorContext *iface, + UINT value) +{ + FIXME("(%p,%u)\n", iface, value); + return E_NOTIMPL; +} + +static HRESULT WINAPI ColorContext_GetType(IWICColorContext *iface, + WICColorContextType *pType) +{ + FIXME("(%p,%p)\n", iface, pType); + return E_NOTIMPL; +} + +static HRESULT WINAPI ColorContext_GetProfileBytes(IWICColorContext *iface, + UINT cbBuffer, BYTE *pbBuffer, UINT *pcbActual) +{ + FIXME("(%p,%u,%p,%p)\n", iface, cbBuffer, pbBuffer, pcbActual); + return E_NOTIMPL; +} + +static HRESULT WINAPI ColorContext_GetExifColorSpace(IWICColorContext *iface, + UINT *pValue) +{ + FIXME("(%p,%p)\n", iface, pValue); + return E_NOTIMPL; +} + +static const IWICColorContextVtbl ColorContext_Vtbl = { + ColorContext_QueryInterface, + ColorContext_AddRef, + ColorContext_Release, + ColorContext_InitializeFromFilename, + ColorContext_InitializeFromMemory, + ColorContext_InitializeFromExifColorSpace, + ColorContext_GetType, + ColorContext_GetProfileBytes, + ColorContext_GetExifColorSpace +}; + +HRESULT ColorContext_Create(IWICColorContext **colorcontext) +{ + ColorContext *This; + + This = HeapAlloc(GetProcessHeap(), 0, sizeof(ColorContext)); + if (!This) return E_OUTOFMEMORY; + + This->IWICColorContext_iface.lpVtbl = &ColorContext_Vtbl; + This->ref = 1; + + *colorcontext = &This->IWICColorContext_iface; + + return S_OK; +} diff --git a/dlls/windowscodecs/imgfactory.c b/dlls/windowscodecs/imgfactory.c index 8ba0a1d..54b390b 100644 --- a/dlls/windowscodecs/imgfactory.c +++ b/dlls/windowscodecs/imgfactory.c @@ -442,8 +442,8 @@ static HRESULT WINAPI ComponentFactory_CreateStream(IWICComponentFactory *iface, static HRESULT WINAPI ComponentFactory_CreateColorContext(IWICComponentFactory *iface, IWICColorContext **ppIColorContext) { - FIXME("(%p,%p): stub\n", iface, ppIColorContext); - return E_NOTIMPL; + TRACE("(%p,%p)\n", iface, ppIColorContext); + return ColorContext_Create(ppIColorContext); } static HRESULT WINAPI ComponentFactory_CreateColorTransformer(IWICComponentFactory *iface, diff --git a/dlls/windowscodecs/wincodecs_private.h b/dlls/windowscodecs/wincodecs_private.h index 41d2d80..6857176 100644 --- a/dlls/windowscodecs/wincodecs_private.h +++ b/dlls/windowscodecs/wincodecs_private.h @@ -51,6 +51,7 @@ extern HRESULT BitmapScaler_Create(IWICBitmapScaler **scaler) DECLSPEC_HIDDEN; extern HRESULT FlipRotator_Create(IWICBitmapFlipRotator **fliprotator) DECLSPEC_HIDDEN; extern HRESULT PaletteImpl_Create(IWICPalette **palette) DECLSPEC_HIDDEN; extern HRESULT StreamImpl_Create(IWICStream **stream) DECLSPEC_HIDDEN; +extern HRESULT ColorContext_Create(IWICColorContext **context) DECLSPEC_HIDDEN; extern HRESULT copy_pixels(UINT bpp, const BYTE *srcbuffer, UINT srcwidth, UINT srcheight, INT srcstride,
1
0
0
0
Hans Leidekker : windowscodecs: Implement WICCreateColorContext_Proxy.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: 1b762afa63ec6541425ae827090cde03ee152997 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1b762afa63ec6541425ae8270…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Thu Nov 15 14:06:10 2012 +0100 windowscodecs: Implement WICCreateColorContext_Proxy. --- dlls/windowscodecs/proxy.c | 7 +++++++ dlls/windowscodecs/windowscodecs.spec | 2 +- 2 files changed, 8 insertions(+), 1 deletions(-) diff --git a/dlls/windowscodecs/proxy.c b/dlls/windowscodecs/proxy.c index 4ee12c2..2f727b4 100644 --- a/dlls/windowscodecs/proxy.c +++ b/dlls/windowscodecs/proxy.c @@ -620,6 +620,13 @@ HRESULT WINAPI IWICStream_InitializeFromMemory_Proxy_W(IWICStream *iface, return IWICStream_InitializeFromMemory(iface, pbBuffer, cbBufferSize); } +HRESULT WINAPI WICCreateColorContext_Proxy(IWICImagingFactory *iface, IWICColorContext **ppIWICColorContext) +{ + TRACE("%p, %p\n", iface, ppIWICColorContext); + + return IWICImagingFactory_CreateColorContext(iface, ppIWICColorContext); +} + HRESULT WINAPI WICCreateImagingFactory_Proxy(UINT SDKVersion, IWICImagingFactory **ppIImagingFactory) { TRACE("%x, %p\n", SDKVersion, ppIImagingFactory); diff --git a/dlls/windowscodecs/windowscodecs.spec b/dlls/windowscodecs/windowscodecs.spec index 453a84e..3d70084 100644 --- a/dlls/windowscodecs/windowscodecs.spec +++ b/dlls/windowscodecs/windowscodecs.spec @@ -106,7 +106,7 @@ @ stdcall IWICStream_InitializeFromMemory_Proxy(ptr ptr long) IWICStream_InitializeFromMemory_Proxy_W @ stdcall WICConvertBitmapSource(ptr ptr ptr) @ stub WICCreateBitmapFromSection -@ stub WICCreateColorContext_Proxy +@ stdcall WICCreateColorContext_Proxy(ptr ptr) @ stdcall WICCreateImagingFactory_Proxy(long ptr) @ stub WICGetMetadataContentSize @ stub WICMapGuidToShortName
1
0
0
0
Jacek Caban : cmd: Make allocation unfailable.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: c6d24089dbc284f0fef5e1ce37b75ac04c6ebd94 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c6d24089dbc284f0fef5e1ce3…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Thu Nov 15 12:32:21 2012 +0100 cmd: Make allocation unfailable. --- programs/cmd/batch.c | 5 +- programs/cmd/builtins.c | 43 ++++++----------- programs/cmd/directory.c | 31 ++++-------- programs/cmd/wcmd.h | 18 +++++++- programs/cmd/wcmdmain.c | 116 ++++++++++++++++++++-------------------------- 5 files changed, 96 insertions(+), 117 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=c6d24089dbc284f0fef5e…
1
0
0
0
Jacek Caban : atl: Properly fail on an aggregation attempt.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: efd0eead07b81ea01abbbcb97ba3cd7536448f4a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=efd0eead07b81ea01abbbcb97…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Thu Nov 15 11:21:57 2012 +0100 atl: Properly fail on an aggregation attempt. --- dlls/atl/registrar.c | 49 ++++++++++++++++++++++++++++++------------- dlls/atl/tests/registrar.c | 12 ++++++++++ 2 files changed, 46 insertions(+), 15 deletions(-) diff --git a/dlls/atl/registrar.c b/dlls/atl/registrar.c index 7b1fe30..028f35e 100644 --- a/dlls/atl/registrar.c +++ b/dlls/atl/registrar.c @@ -698,21 +698,22 @@ static const IRegistrarVtbl RegistrarVtbl = { Registrar_ResourceUnregister, }; -static HRESULT Registrar_create(const IUnknown *pUnkOuter, REFIID riid, void **ppvObject) +/* Exported only by newer ATL versions */ +static HRESULT AtlCreateRegistrar(IRegistrar **ret) { - Registrar *ret; + Registrar *registrar; - if(!IsEqualGUID(&IID_IUnknown, riid) && !IsEqualGUID(&IID_IRegistrar, riid)) - return E_NOINTERFACE; + registrar = HeapAlloc(GetProcessHeap(), 0, sizeof(*registrar)); + if(!registrar) + return E_OUTOFMEMORY; - ret = HeapAlloc(GetProcessHeap(), 0, sizeof(Registrar)); - ret->IRegistrar_iface.lpVtbl = &RegistrarVtbl; - ret->ref = 1; - ret->rep = NULL; - *ppvObject = ret; + registrar->IRegistrar_iface.lpVtbl = &RegistrarVtbl; + registrar->ref = 1; + registrar->rep = NULL; InterlockedIncrement(&dll_count); + *ret = ®istrar->IRegistrar_iface; return S_OK; } @@ -746,10 +747,25 @@ static ULONG WINAPI RegistrarCF_Release(IClassFactory *iface) } static HRESULT WINAPI RegistrarCF_CreateInstance(IClassFactory *iface, LPUNKNOWN pUnkOuter, - REFIID riid, void **ppvObject) + REFIID riid, void **ppv) { - TRACE("(%p)->(%s %p)\n", iface, debugstr_guid(riid), ppvObject); - return Registrar_create(pUnkOuter, riid, ppvObject); + IRegistrar *registrar; + HRESULT hres; + + TRACE("(%p)->(%s %p)\n", iface, debugstr_guid(riid), ppv); + + if(pUnkOuter) { + *ppv = NULL; + return CLASS_E_NOAGGREGATION; + } + + hres = AtlCreateRegistrar(®istrar); + if(FAILED(hres)) + return hres; + + hres = IRegistrar_QueryInterface(registrar, riid, ppv); + IRegistrar_Release(registrar); + return hres; } static HRESULT WINAPI RegistrarCF_LockServer(IClassFactory *iface, BOOL lock) @@ -801,10 +817,13 @@ static HRESULT do_register_dll_server(IRegistrar *pRegistrar, LPCOLESTR wszDll, static const WCHAR wszModule[] = {'M','O','D','U','L','E',0}; static const WCHAR wszRegistry[] = {'R','E','G','I','S','T','R','Y',0}; - if (pRegistrar) + if(pRegistrar) { registrar = pRegistrar; - else - Registrar_create(NULL, &IID_IRegistrar, (void**)®istrar); + }else { + hres = AtlCreateRegistrar(®istrar); + if(FAILED(hres)) + return hres; + } IRegistrar_AddReplacement(registrar, wszModule, wszDll); diff --git a/dlls/atl/tests/registrar.c b/dlls/atl/tests/registrar.c index 9c5dd23..1b1c797 100644 --- a/dlls/atl/tests/registrar.c +++ b/dlls/atl/tests/registrar.c @@ -135,11 +135,23 @@ static void test_registrar(void) IRegistrar_Release(registrar); } +static void test_aggregation(void) +{ + IUnknown *unk = (IUnknown*)0xdeadbeef; + HRESULT hres; + + hres = CoCreateInstance(&CLSID_Registrar, (IUnknown*)0xdeadbeef, CLSCTX_INPROC_SERVER|CLSCTX_INPROC_HANDLER, + &IID_IUnknown, (void**)&unk); + ok(hres == CLASS_E_NOAGGREGATION, "CoCreateInstance failed: %08x, expected CLASS_E_NOAGGREGATION\n", hres); + ok(!unk, "unk = %p\n", unk); +} + START_TEST(registrar) { CoInitialize(NULL); test_registrar(); + test_aggregation(); CoUninitialize(); }
1
0
0
0
Dmitry Timoshkov : fonts: Update 10-pixel cyrillic bitmaps for Tahoma.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: e070173ac6316cd9afc2755087d8e6b95b6cdafe URL:
http://source.winehq.org/git/wine.git/?a=commit;h=e070173ac6316cd9afc275508…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Thu Nov 15 16:44:43 2012 +0800 fonts: Update 10-pixel cyrillic bitmaps for Tahoma. --- fonts/tahoma.sfd | 352 ++++++++++++++++++++++++++++-------------------------- fonts/tahoma.ttf | Bin 101036 -> 101052 bytes 2 files changed, 180 insertions(+), 172 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=e070173ac6316cd9afc27…
1
0
0
0
Alexandre Julliard : winex11: Move the screen saver support to a new SystemParametersInfo entry point.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: 67d16ddee3ba20ea0aa794a4153fcbbb67869a66 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=67d16ddee3ba20ea0aa794a41…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Thu Nov 15 17:46:37 2012 +0100 winex11: Move the screen saver support to a new SystemParametersInfo entry point. --- dlls/winex11.drv/winex11.drv.spec | 3 +- dlls/winex11.drv/x11drv_main.c | 58 +++++++++++++++++++----------------- 2 files changed, 32 insertions(+), 29 deletions(-) diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec index db3e4f5..f14be21 100644 --- a/dlls/winex11.drv/winex11.drv.spec +++ b/dlls/winex11.drv/winex11.drv.spec @@ -19,8 +19,6 @@ @ cdecl GetCursorPos(ptr) X11DRV_GetCursorPos @ cdecl SetCursorPos(long long) X11DRV_SetCursorPos @ cdecl ClipCursor(ptr) X11DRV_ClipCursor -@ cdecl GetScreenSaveActive() X11DRV_GetScreenSaveActive -@ cdecl SetScreenSaveActive(long) X11DRV_SetScreenSaveActive @ cdecl ChangeDisplaySettingsEx(ptr ptr long long long) X11DRV_ChangeDisplaySettingsEx @ cdecl EnumDisplayMonitors(long ptr ptr long) X11DRV_EnumDisplayMonitors @ cdecl EnumDisplaySettingsEx(ptr long ptr long) X11DRV_EnumDisplaySettingsEx @@ -54,6 +52,7 @@ @ cdecl WindowMessage(long long long long) X11DRV_WindowMessage @ cdecl WindowPosChanging(long long long ptr ptr ptr ptr) X11DRV_WindowPosChanging @ cdecl WindowPosChanged(long long long ptr ptr ptr ptr ptr) X11DRV_WindowPosChanged +@ cdecl SystemParametersInfo(long long ptr long) X11DRV_SystemParametersInfo # WinTab32 @ cdecl AttachEventQueueToTablet(long) X11DRV_AttachEventQueueToTablet diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index 3ff4233..ef6b1a9 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -696,35 +696,39 @@ BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved ) return ret; } -/*********************************************************************** - * GetScreenSaveActive (X11DRV.@) - * - * Returns the active status of the screen saver - */ -BOOL CDECL X11DRV_GetScreenSaveActive(void) -{ - int timeout, temp; - XGetScreenSaver(gdi_display, &timeout, &temp, &temp, &temp); - return timeout != 0; -} /*********************************************************************** - * SetScreenSaveActive (X11DRV.@) - * - * Activate/Deactivate the screen saver + * SystemParametersInfo (X11DRV.@) */ -void CDECL X11DRV_SetScreenSaveActive(BOOL bActivate) +BOOL CDECL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, UINT flags ) { - int timeout, interval, prefer_blanking, allow_exposures; - static int last_timeout = 15 * 60; - - XLockDisplay( gdi_display ); - XGetScreenSaver(gdi_display, &timeout, &interval, &prefer_blanking, - &allow_exposures); - if (timeout) last_timeout = timeout; - - timeout = bActivate ? last_timeout : 0; - XSetScreenSaver(gdi_display, timeout, interval, prefer_blanking, - allow_exposures); - XUnlockDisplay( gdi_display ); + switch (action) + { + case SPI_GETSCREENSAVEACTIVE: + if (ptr_param) + { + int timeout, temp; + XGetScreenSaver(gdi_display, &timeout, &temp, &temp, &temp); + *(BOOL *)ptr_param = timeout != 0; + return TRUE; + } + break; + case SPI_SETSCREENSAVEACTIVE: + { + int timeout, interval, prefer_blanking, allow_exposures; + static int last_timeout = 15 * 60; + + XLockDisplay( gdi_display ); + XGetScreenSaver(gdi_display, &timeout, &interval, &prefer_blanking, + &allow_exposures); + if (timeout) last_timeout = timeout; + + timeout = int_param ? last_timeout : 0; + XSetScreenSaver(gdi_display, timeout, interval, prefer_blanking, + allow_exposures); + XUnlockDisplay( gdi_display ); + } + break; + } + return FALSE; /* let user32 handle it */ }
1
0
0
0
Alexandre Julliard : user32: Forward SystemParametersInfo calls to the user driver first.
by Alexandre Julliard
15 Nov '12
15 Nov '12
Module: wine Branch: master Commit: 13fbce5627c759ba260618e665436c6315d592da URL:
http://source.winehq.org/git/wine.git/?a=commit;h=13fbce5627c759ba260618e66…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Thu Nov 15 17:38:21 2012 +0100 user32: Forward SystemParametersInfo calls to the user driver first. --- dlls/user32/driver.c | 46 +++++--------- dlls/user32/sysparams.c | 139 +++++++++++++++----------------------------- dlls/user32/user_private.h | 5 +- 3 files changed, 66 insertions(+), 124 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=13fbce5627c759ba26061…
1
0
0
0
← Newer
1
...
36
37
38
39
40
41
42
...
71
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
Results per page:
10
25
50
100
200