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
December 2009
----- 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
3 participants
1233 discussions
Start a n
N
ew thread
Henri Verbeet : wined3d: Move IWineD3DDeviceImpl_RestoreWindow() to swapchain.c.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: cb076db8ccbcb0522f834189ffab5c41980ed56a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=cb076db8ccbcb0522f834189f…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Thu Dec 10 21:41:56 2009 +0100 wined3d: Move IWineD3DDeviceImpl_RestoreWindow() to swapchain.c. --- dlls/wined3d/device.c | 69 +--------------------------------------- dlls/wined3d/swapchain.c | 32 ++++++++++++++++++ dlls/wined3d/wined3d_private.h | 1 + 3 files changed, 34 insertions(+), 68 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index b871474..6529b23 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -919,73 +919,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateQuery(IWineD3DDevice *iface, WINE return WINED3D_OK; } -static LONG fullscreen_style(LONG orig_style) { - LONG style = orig_style; - style &= ~WS_CAPTION; - style &= ~WS_THICKFRAME; - - /* Make sure the window is managed, otherwise we won't get keyboard input */ - style |= WS_POPUP | WS_SYSMENU; - - return style; -} - -static LONG fullscreen_exStyle(LONG orig_exStyle) { - LONG exStyle = orig_exStyle; - - /* Filter out window decorations */ - exStyle &= ~WS_EX_WINDOWEDGE; - exStyle &= ~WS_EX_CLIENTEDGE; - - return exStyle; -} - -/***************************************************************************** - * IWineD3DDeviceImpl_RestoreWindow - * - * Helper function that restores a windows' properties when taking it out - * of fullscreen mode - * - * Params: - * iface: Pointer to the IWineD3DDevice interface - * window: Window to setup - * - *****************************************************************************/ -static void IWineD3DDeviceImpl_RestoreWindow(IWineD3DDevice *iface, HWND window) { - IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - LONG style, exStyle; - - /* This could be a DDSCL_NORMAL -> DDSCL_NORMAL - * switch, do nothing - */ - if (!This->style && !This->exStyle) return; - - TRACE("(%p): Restoring window settings of window %p to %08x, %08x\n", - This, window, This->style, This->exStyle); - - style = GetWindowLongW(window, GWL_STYLE); - exStyle = GetWindowLongW(window, GWL_EXSTYLE); - - /* Only restore the style if the application didn't modify it during the fullscreen phase. - * Some applications change it before calling Reset() when switching between windowed and - * fullscreen modes(HL2), some depend on the original style(Eve Online) - */ - if (style == fullscreen_style(This->style) && exStyle == fullscreen_exStyle(This->exStyle)) - { - SetWindowLongW(window, GWL_STYLE, This->style); - SetWindowLongW(window, GWL_EXSTYLE, This->exStyle); - } - - /* Delete the old values */ - This->style = 0; - This->exStyle = 0; - - /* Inform the window about the update */ - SetWindowPos(window, 0 /* InsertAfter, ignored */, - 0, 0, 0, 0, /* Pos, Size, ignored */ - SWP_FRAMECHANGED | SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER); -} - static HRESULT WINAPI IWineD3DDeviceImpl_CreateSwapChain(IWineD3DDevice *iface, WINED3DPRESENT_PARAMETERS *present_parameters, IWineD3DSwapChain **swapchain, IUnknown *parent, WINED3DSURFTYPE surface_type) @@ -6568,7 +6501,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Reset(IWineD3DDevice* iface, WINED3DPRE } } else if(swapchain->win_handle && !swapchain->presentParms.Windowed) { /* Fullscreen -> windowed switch */ - IWineD3DDeviceImpl_RestoreWindow(iface, swapchain->win_handle); + swapchain_restore_fullscreen_window(swapchain); } swapchain->presentParms.Windowed = pPresentationParameters->Windowed; } else if(!pPresentationParameters->Windowed) { diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c index 543c9aa..3e4da78 100644 --- a/dlls/wined3d/swapchain.c +++ b/dlls/wined3d/swapchain.c @@ -602,6 +602,38 @@ void swapchain_setup_fullscreen_window(IWineD3DSwapChainImpl *swapchain, UINT w, SetWindowPos(window, HWND_TOP, 0, 0, w, h, SWP_FRAMECHANGED | SWP_SHOWWINDOW); } +void swapchain_restore_fullscreen_window(IWineD3DSwapChainImpl *swapchain) +{ + IWineD3DDeviceImpl *device = swapchain->device; + HWND window = swapchain->win_handle; + LONG style, exstyle; + + if (!device->style && !device->exStyle) return; + + TRACE("Restoring window style of window %p to %08x, %08x.\n", + window, device->style, device->exStyle); + + style = GetWindowLongW(window, GWL_STYLE); + exstyle = GetWindowLongW(window, GWL_EXSTYLE); + + /* Only restore the style if the application didn't modify it during the + * fullscreen phase. Some applications change it before calling Reset() + * when switching between windowed and fullscreen modes (HL2), some + * depend on the original style (Eve Online). */ + if (style == fullscreen_style(device->style) && exstyle == fullscreen_exstyle(device->exStyle)) + { + SetWindowLongW(window, GWL_STYLE, device->style); + SetWindowLongW(window, GWL_EXSTYLE, device->exStyle); + } + + /* Delete the old values. */ + device->style = 0; + device->exStyle = 0; + + SetWindowPos(window, 0, 0, 0, 0, 0, SWP_FRAMECHANGED | SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER); +} + + HRESULT swapchain_init(IWineD3DSwapChainImpl *swapchain, WINED3DSURFTYPE surface_type, IWineD3DDeviceImpl *device, WINED3DPRESENT_PARAMETERS *present_parameters, IUnknown *parent) { diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 0d111c4..e0b4ab1 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2453,6 +2453,7 @@ struct wined3d_context *swapchain_create_context_for_thread(IWineD3DSwapChain *i HRESULT swapchain_init(IWineD3DSwapChainImpl *swapchain, WINED3DSURFTYPE surface_type, IWineD3DDeviceImpl *device, WINED3DPRESENT_PARAMETERS *present_parameters, IUnknown *parent) DECLSPEC_HIDDEN; void swapchain_setup_fullscreen_window(IWineD3DSwapChainImpl *swapchain, UINT w, UINT h) DECLSPEC_HIDDEN; +void swapchain_restore_fullscreen_window(IWineD3DSwapChainImpl *swapchain) DECLSPEC_HIDDEN; #define DEFAULT_REFRESH_RATE 0
1
0
0
0
Henri Verbeet : wined3d: Move IWineD3DDeviceImpl_SetupFullscreenWindow() to swapchain.c.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 542590cfc9b376bcf97dca54cbe56a615a15a874 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=542590cfc9b376bcf97dca54c…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Thu Dec 10 21:41:55 2009 +0100 wined3d: Move IWineD3DDeviceImpl_SetupFullscreenWindow() to swapchain.c. --- dlls/wined3d/device.c | 51 +++------------------------------------ dlls/wined3d/swapchain.c | 47 ++++++++++++++++++++++++++++++++++++- dlls/wined3d/wined3d_private.h | 2 +- 3 files changed, 51 insertions(+), 49 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index c49f70f..b871474 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -919,17 +919,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateQuery(IWineD3DDevice *iface, WINE return WINED3D_OK; } -/***************************************************************************** - * IWineD3DDeviceImpl_SetupFullscreenWindow - * - * Helper function that modifies a HWND's Style and ExStyle for proper - * fullscreen use. - * - * Params: - * iface: Pointer to the IWineD3DDevice interface - * window: Window to setup - * - *****************************************************************************/ static LONG fullscreen_style(LONG orig_style) { LONG style = orig_style; style &= ~WS_CAPTION; @@ -951,38 +940,6 @@ static LONG fullscreen_exStyle(LONG orig_exStyle) { return exStyle; } -void IWineD3DDeviceImpl_SetupFullscreenWindow(IWineD3DDeviceImpl *This, HWND window, UINT w, UINT h) -{ - LONG style, exStyle; - /* Don't do anything if an original style is stored. - * That shouldn't happen - */ - TRACE("(%p): Setting up window %p for exclusive mode\n", This, window); - if (This->style || This->exStyle) { - ERR("(%p): Want to change the window parameters of HWND %p, but " - "another style is stored for restoration afterwards\n", This, window); - } - - /* Get the parameters and save them */ - style = GetWindowLongW(window, GWL_STYLE); - exStyle = GetWindowLongW(window, GWL_EXSTYLE); - This->style = style; - This->exStyle = exStyle; - - style = fullscreen_style(style); - exStyle = fullscreen_exStyle(exStyle); - - TRACE("Old style was %08x,%08x, setting to %08x,%08x\n", - This->style, This->exStyle, style, exStyle); - - SetWindowLongW(window, GWL_STYLE, style); - SetWindowLongW(window, GWL_EXSTYLE, exStyle); - - /* Inform the window about the update. */ - SetWindowPos(window, HWND_TOP, 0, 0, - w, h, SWP_FRAMECHANGED | SWP_SHOWWINDOW); -} - /***************************************************************************** * IWineD3DDeviceImpl_RestoreWindow * @@ -6601,8 +6558,8 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Reset(IWineD3DDevice* iface, WINED3DPRE if(swapchain->win_handle && !pPresentationParameters->Windowed) { if(swapchain->presentParms.Windowed) { /* switch from windowed to fs */ - IWineD3DDeviceImpl_SetupFullscreenWindow(This, swapchain->win_handle, - pPresentationParameters->BackBufferWidth, pPresentationParameters->BackBufferHeight); + swapchain_setup_fullscreen_window(swapchain, pPresentationParameters->BackBufferWidth, + pPresentationParameters->BackBufferHeight); } else { /* Fullscreen -> fullscreen mode change */ MoveWindow(swapchain->win_handle, 0, 0, @@ -6622,8 +6579,8 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Reset(IWineD3DDevice* iface, WINED3DPRE */ This->style = 0; This->exStyle = 0; - IWineD3DDeviceImpl_SetupFullscreenWindow(This, swapchain->win_handle, - pPresentationParameters->BackBufferWidth, pPresentationParameters->BackBufferHeight); + swapchain_setup_fullscreen_window(swapchain, pPresentationParameters->BackBufferWidth, + pPresentationParameters->BackBufferHeight); This->style = style; This->exStyle = exStyle; } diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c index 51ee607..543c9aa 100644 --- a/dlls/wined3d/swapchain.c +++ b/dlls/wined3d/swapchain.c @@ -557,6 +557,51 @@ static const IWineD3DSwapChainVtbl IWineD3DSwapChain_Vtbl = IWineD3DBaseSwapChainImpl_GetGammaRamp }; +static LONG fullscreen_style(LONG style) +{ + /* Make sure the window is managed, otherwise we won't get keyboard input. */ + style |= WS_POPUP | WS_SYSMENU; + style &= ~(WS_CAPTION | WS_THICKFRAME); + + return style; +} + +static LONG fullscreen_exstyle(LONG exstyle) +{ + /* Filter out window decorations. */ + exstyle &= ~(WS_EX_WINDOWEDGE | WS_EX_CLIENTEDGE); + + return exstyle; +} + +void swapchain_setup_fullscreen_window(IWineD3DSwapChainImpl *swapchain, UINT w, UINT h) +{ + IWineD3DDeviceImpl *device = swapchain->device; + HWND window = swapchain->win_handle; + LONG style, exstyle; + + TRACE("Setting up window %p for fullscreen mode.\n", window); + + if (device->style || device->exStyle) + { + ERR("Changing the window style for window %p, but another style (%08x, %08x) is already stored.\n", + window, device->style, device->exStyle); + } + + device->style = GetWindowLongW(window, GWL_STYLE); + device->exStyle = GetWindowLongW(window, GWL_EXSTYLE); + + style = fullscreen_style(device->style); + exstyle = fullscreen_exstyle(device->exStyle); + + TRACE("Old style was %08x, %08x, setting to %08x, %08x.\n", + device->style, device->exStyle, style, exstyle); + + SetWindowLongW(window, GWL_STYLE, style); + SetWindowLongW(window, GWL_EXSTYLE, exstyle); + SetWindowPos(window, HWND_TOP, 0, 0, w, h, SWP_FRAMECHANGED | SWP_SHOWWINDOW); +} + HRESULT swapchain_init(IWineD3DSwapChainImpl *swapchain, WINED3DSURFTYPE surface_type, IWineD3DDeviceImpl *device, WINED3DPRESENT_PARAMETERS *present_parameters, IUnknown *parent) { @@ -606,7 +651,7 @@ HRESULT swapchain_init(IWineD3DSwapChainImpl *swapchain, WINED3DSURFTYPE surface if (!present_parameters->Windowed && window) { - IWineD3DDeviceImpl_SetupFullscreenWindow(device, window, present_parameters->BackBufferWidth, + swapchain_setup_fullscreen_window(swapchain, present_parameters->BackBufferWidth, present_parameters->BackBufferHeight); } diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 65e6e18..0d111c4 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -1598,7 +1598,6 @@ HRESULT IWineD3DDeviceImpl_ClearSurface(IWineD3DDeviceImpl *This, IWineD3DSurfac const WINED3DRECT *pRects, DWORD Flags, WINED3DCOLOR Color, float Z, DWORD Stencil) DECLSPEC_HIDDEN; void IWineD3DDeviceImpl_FindTexUnitMap(IWineD3DDeviceImpl *This) DECLSPEC_HIDDEN; void IWineD3DDeviceImpl_MarkStateDirty(IWineD3DDeviceImpl *This, DWORD state) DECLSPEC_HIDDEN; -void IWineD3DDeviceImpl_SetupFullscreenWindow(IWineD3DDeviceImpl *This, HWND window, UINT w, UINT h) DECLSPEC_HIDDEN; static inline BOOL isStateDirty(struct wined3d_context *context, DWORD state) { @@ -2453,6 +2452,7 @@ HRESULT WINAPI IWineD3DBaseSwapChainImpl_GetGammaRamp(IWineD3DSwapChain *iface, struct wined3d_context *swapchain_create_context_for_thread(IWineD3DSwapChain *iface) DECLSPEC_HIDDEN; HRESULT swapchain_init(IWineD3DSwapChainImpl *swapchain, WINED3DSURFTYPE surface_type, IWineD3DDeviceImpl *device, WINED3DPRESENT_PARAMETERS *present_parameters, IUnknown *parent) DECLSPEC_HIDDEN; +void swapchain_setup_fullscreen_window(IWineD3DSwapChainImpl *swapchain, UINT w, UINT h) DECLSPEC_HIDDEN; #define DEFAULT_REFRESH_RATE 0
1
0
0
0
Henri Verbeet : wined3d: Add a separate function for swapchain initialization.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: a9f2613d13a70c9152f1d72bce02287ccd8147f8 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a9f2613d13a70c9152f1d72bc…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Thu Dec 10 21:41:54 2009 +0100 wined3d: Add a separate function for swapchain initialization. --- dlls/wined3d/device.c | 325 +++------------------------------------- dlls/wined3d/swapchain.c | 278 ++++++++++++++++++++++++++++++++++- dlls/wined3d/wined3d_private.h | 5 +- 3 files changed, 303 insertions(+), 305 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=a9f2613d13a70c9152f1d…
1
0
0
0
Henri Verbeet : wined3d: Correctly calculate the extended style in IWineD3DDeviceImpl_RestoreWindow ().
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 75ef50e4354e764bf9b7ab6bcd8eccfe4354f4a3 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=75ef50e4354e764bf9b7ab6bc…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Thu Dec 10 21:41:53 2009 +0100 wined3d: Correctly calculate the extended style in IWineD3DDeviceImpl_RestoreWindow(). --- dlls/wined3d/device.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index c04f32b..029884c 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -1014,8 +1014,8 @@ static void IWineD3DDeviceImpl_RestoreWindow(IWineD3DDevice *iface, HWND window) * Some applications change it before calling Reset() when switching between windowed and * fullscreen modes(HL2), some depend on the original style(Eve Online) */ - if(style == fullscreen_style(This->style) && - exStyle == fullscreen_style(This->exStyle)) { + if (style == fullscreen_style(This->style) && exStyle == fullscreen_exStyle(This->exStyle)) + { SetWindowLongW(window, GWL_STYLE, This->style); SetWindowLongW(window, GWL_EXSTYLE, This->exStyle); }
1
0
0
0
Henri Verbeet : wined3d: Properly invalidate the context' s draw buffer in color_fill_fbo().
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 840b5af77e7e387d32b24a6f7d48f0a0e8d32ad3 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=840b5af77e7e387d32b24a6f7…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Thu Dec 10 21:41:52 2009 +0100 wined3d: Properly invalidate the context's draw buffer in color_fill_fbo(). --- dlls/wined3d/context.c | 8 ++++++++ dlls/wined3d/device.c | 13 ++++++------- dlls/wined3d/wined3d_private.h | 1 + 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c index 8a2a522..0debd2e 100644 --- a/dlls/wined3d/context.c +++ b/dlls/wined3d/context.c @@ -2097,6 +2097,14 @@ static void context_apply_draw_buffer(struct wined3d_context *context, BOOL blit } } +/* GL locking is done by the caller. */ +void context_set_draw_buffer(struct wined3d_context *context, GLenum buffer) +{ + glDrawBuffer(buffer); + checkGLcall("glDrawBuffer()"); + context->draw_buffer_dirty = TRUE; +} + /***************************************************************************** * context_acquire * diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index a4eacba..c04f32b 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -5696,18 +5696,17 @@ static void color_fill_fbo(IWineD3DDevice *iface, IWineD3DSurface *surface, IWineD3DSwapChain *swapchain; swapchain = get_swapchain(surface); - if (!surface_is_offscreen(surface)) { - GLenum buffer; - + if (!surface_is_offscreen(surface)) + { TRACE("Surface %p is onscreen\n", surface); context = context_acquire(This, surface, CTXUSAGE_RESOURCELOAD); ENTER_GL(); context_bind_fbo(context, GL_FRAMEBUFFER, NULL); - buffer = surface_get_gl_buffer(surface, swapchain); - glDrawBuffer(buffer); - checkGLcall("glDrawBuffer()"); - } else { + context_set_draw_buffer(context, surface_get_gl_buffer(surface, swapchain)); + } + else + { TRACE("Surface %p is offscreen\n", surface); context = context_acquire(This, NULL, CTXUSAGE_RESOURCELOAD); diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 35887f7..9cecc97 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -1187,6 +1187,7 @@ struct wined3d_context *context_get_current(void) DECLSPEC_HIDDEN; DWORD context_get_tls_idx(void) DECLSPEC_HIDDEN; void context_release(struct wined3d_context *context) DECLSPEC_HIDDEN; BOOL context_set_current(struct wined3d_context *ctx) DECLSPEC_HIDDEN; +void context_set_draw_buffer(struct wined3d_context *context, GLenum buffer) DECLSPEC_HIDDEN; void context_set_tls_idx(DWORD idx) DECLSPEC_HIDDEN; void delete_opengl_contexts(IWineD3DDevice *iface, IWineD3DSwapChain *swapchain) DECLSPEC_HIDDEN;
1
0
0
0
Aric Stewart : shlwapi/tests: Testing framework and IConnection point tests .
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 23cea50db2ffed0fd6c1f0acdd950b7efe516335 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=23cea50db2ffed0fd6c1f0acd…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Thu Dec 10 13:16:34 2009 -0600 shlwapi/tests: Testing framework and IConnection point tests. --- dlls/shlwapi/tests/ordinal.c | 686 ++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 686 insertions(+), 0 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=23cea50db2ffed0fd6c1f…
1
0
0
0
Aric Stewart : shlwapi: Release rgcd.pUnk returned by enumeration.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: deef2c5ac26a6bfb70b8a4b9f241d6a7f86accba URL:
http://source.winehq.org/git/wine.git/?a=commit;h=deef2c5ac26a6bfb70b8a4b9f…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Thu Dec 10 13:16:26 2009 -0600 shlwapi: Release rgcd.pUnk returned by enumeration. --- dlls/shlwapi/ordinal.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/dlls/shlwapi/ordinal.c b/dlls/shlwapi/ordinal.c index 6b0a9bc..73d0f7e 100644 --- a/dlls/shlwapi/ordinal.c +++ b/dlls/shlwapi/ordinal.c @@ -2950,6 +2950,7 @@ static HRESULT SHLWAPI_InvokeByIID( IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, params, NULL, NULL, NULL); IDispatch_Release(dispIface); } + IUnknown_Release(rgcd.pUnk); } IEnumConnections_Release(enumerator);
1
0
0
0
Aric Stewart : shlwapi: DISPPARAMS on Invoke are never NULL.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: ec2a78c30a8e91fae0ba49f0066f8cde526033be URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ec2a78c30a8e91fae0ba49f00…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Thu Dec 10 13:16:14 2009 -0600 shlwapi: DISPPARAMS on Invoke are never NULL. --- dlls/shlwapi/ordinal.c | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/dlls/shlwapi/ordinal.c b/dlls/shlwapi/ordinal.c index 0b9999e..6b0a9bc 100644 --- a/dlls/shlwapi/ordinal.c +++ b/dlls/shlwapi/ordinal.c @@ -2930,18 +2930,24 @@ static HRESULT SHLWAPI_InvokeByIID( { IEnumConnections *enumerator; CONNECTDATA rgcd; + static DISPPARAMS empty = {NULL, NULL, 0, 0}; + DISPPARAMS* params = dispParams; HRESULT result = IConnectionPoint_EnumConnections(iCP, &enumerator); if (FAILED(result)) return result; + /* Invoke is never happening with an NULL dispParams */ + if (!params) + params = ∅ + while(IEnumConnections_Next(enumerator, 1, &rgcd, NULL)==S_OK) { IDispatch *dispIface; if ((iid && SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, iid, (LPVOID*)&dispIface))) || SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, &IID_IDispatch, (LPVOID*)&dispIface))) { - IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, dispParams, NULL, NULL, NULL); + IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, params, NULL, NULL, NULL); IDispatch_Release(dispIface); } }
1
0
0
0
Aric Stewart : shlwapi: Failure in IConnectionPoint_GetConnectionInterface does not prevent Invoking .
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 3dbc0b066707e73c823a766f5ba5706dc29f9312 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=3dbc0b066707e73c823a766f5…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Thu Dec 10 13:16:06 2009 -0600 shlwapi: Failure in IConnectionPoint_GetConnectionInterface does not prevent Invoking. --- dlls/shlwapi/ordinal.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/dlls/shlwapi/ordinal.c b/dlls/shlwapi/ordinal.c index ba614d3..0b9999e 100644 --- a/dlls/shlwapi/ordinal.c +++ b/dlls/shlwapi/ordinal.c @@ -2938,7 +2938,7 @@ static HRESULT SHLWAPI_InvokeByIID( while(IEnumConnections_Next(enumerator, 1, &rgcd, NULL)==S_OK) { IDispatch *dispIface; - if (SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, iid, (LPVOID*)&dispIface)) || + if ((iid && SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, iid, (LPVOID*)&dispIface))) || SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, &IID_IDispatch, (LPVOID*)&dispIface))) { IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, dispParams, NULL, NULL, NULL); @@ -2966,6 +2966,8 @@ HRESULT WINAPI IConnectionPoint_InvokeWithCancel( IConnectionPoint* iCP, result = IConnectionPoint_GetConnectionInterface(iCP, &iid); if (SUCCEEDED(result)) result = SHLWAPI_InvokeByIID(iCP, &iid, dispId, dispParams); + else + result = SHLWAPI_InvokeByIID(iCP, NULL, dispId, dispParams); return result; } @@ -2989,6 +2991,8 @@ HRESULT WINAPI IConnectionPoint_SimpleInvoke( result = IConnectionPoint_GetConnectionInterface(iCP, &iid); if (SUCCEEDED(result)) result = SHLWAPI_InvokeByIID(iCP, &iid, dispId, dispParams); + else + result = SHLWAPI_InvokeByIID(iCP, NULL, dispId, dispParams); return result; }
1
0
0
0
Aric Stewart : shlwapi: Rename ConnectToConnectionPoint bAdviseOnly to fConnect as MSDN.
by Alexandre Julliard
11 Dec '09
11 Dec '09
Module: wine Branch: master Commit: 56d1a7c00357498b485dd79128ae38f906e56944 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=56d1a7c00357498b485dd7912…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Thu Dec 10 13:15:58 2009 -0600 shlwapi: Rename ConnectToConnectionPoint bAdviseOnly to fConnect as MSDN. --- dlls/shlwapi/ordinal.c | 11 ++++++----- 1 files changed, 6 insertions(+), 5 deletions(-) diff --git a/dlls/shlwapi/ordinal.c b/dlls/shlwapi/ordinal.c index 0ecbab8..ba614d3 100644 --- a/dlls/shlwapi/ordinal.c +++ b/dlls/shlwapi/ordinal.c @@ -1128,7 +1128,7 @@ HWND WINAPI SHSetParentHwnd(HWND hWnd, HWND hWndParent) * PARAMS * lpUnkSink [I] Sink for the connection point advise call * riid [I] REFIID of connection point to advise - * bAdviseOnly [I] TRUE = Advise only, FALSE = Unadvise first + * fConnect [I] TRUE = Connection being establisted, FALSE = broken * lpUnknown [I] Object supporting the IConnectionPointContainer interface * lpCookie [O] Pointer to connection point cookie * lppCP [O] Destination for the IConnectionPoint found @@ -1140,7 +1140,7 @@ HWND WINAPI SHSetParentHwnd(HWND hWnd, HWND hWndParent) * E_NOINTERFACE, if lpUnknown isn't an IConnectionPointContainer, * Or an HRESULT error code if any call fails. */ -HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL bAdviseOnly, +HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL fConnect, IUnknown* lpUnknown, LPDWORD lpCookie, IConnectionPoint **lppCP) { @@ -1148,7 +1148,7 @@ HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL b IConnectionPointContainer* lpContainer; IConnectionPoint *lpCP; - if(!lpUnknown || (bAdviseOnly && !lpUnkSink)) + if(!lpUnknown || (fConnect && !lpUnkSink)) return E_FAIL; if(lppCP) @@ -1162,9 +1162,10 @@ HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL b if (SUCCEEDED(hRet)) { - if(!bAdviseOnly) + if(!fConnect) hRet = IConnectionPoint_Unadvise(lpCP, *lpCookie); - hRet = IConnectionPoint_Advise(lpCP, lpUnkSink, lpCookie); + else + hRet = IConnectionPoint_Advise(lpCP, lpUnkSink, lpCookie); if (FAILED(hRet)) *lpCookie = 0;
1
0
0
0
← Newer
1
...
72
73
74
75
76
77
78
...
124
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
Results per page:
10
25
50
100
200