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
May 2023
----- 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
1 participants
775 discussions
Start a n
N
ew thread
Davide Beatrici : wineoss: Use mmdevapi's AudioClient2.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: c899cc82150e76f850e085562b1e2f6037eeb672 URL:
https://gitlab.winehq.org/wine/wine/-/commit/c899cc82150e76f850e085562b1e2f…
Author: Davide Beatrici <git(a)davidebeatrici.dev> Date: Thu May 25 10:26:19 2023 +0200 wineoss: Use mmdevapi's AudioClient2. --- dlls/wineoss.drv/mmdevdrv.c | 66 +++++++-------------------------------------- 1 file changed, 9 insertions(+), 57 deletions(-) diff --git a/dlls/wineoss.drv/mmdevdrv.c b/dlls/wineoss.drv/mmdevdrv.c index ef6eb77a9cf..c282fb88831 100644 --- a/dlls/wineoss.drv/mmdevdrv.c +++ b/dlls/wineoss.drv/mmdevdrv.c @@ -941,63 +941,15 @@ static HRESULT WINAPI AudioClient_GetService(IAudioClient3 *iface, REFIID riid, return E_NOINTERFACE; } -static HRESULT WINAPI AudioClient_IsOffloadCapable(IAudioClient3 *iface, - AUDIO_STREAM_CATEGORY category, BOOL *offload_capable) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - TRACE("(%p)->(0x%x, %p)\n", This, category, offload_capable); - - if(!offload_capable) - return E_INVALIDARG; - - *offload_capable = FALSE; - - return S_OK; -} - -static HRESULT WINAPI AudioClient_SetClientProperties(IAudioClient3 *iface, - const AudioClientProperties *prop) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - const Win8AudioClientProperties *legacy_prop = (const Win8AudioClientProperties *)prop; - - TRACE("(%p)->(%p)\n", This, prop); - - if(!legacy_prop) - return E_POINTER; - - if(legacy_prop->cbSize == sizeof(AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x, Options: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory, - prop->Options); - }else if(legacy_prop->cbSize == sizeof(Win8AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory); - }else{ - WARN("Unsupported Size = %d\n", legacy_prop->cbSize); - return E_INVALIDARG; - } - - - if(legacy_prop->bIsOffload) - return AUDCLNT_E_ENDPOINT_OFFLOAD_NOT_CAPABLE; +extern HRESULT WINAPI client_IsOffloadCapable(IAudioClient3 *iface, + AUDIO_STREAM_CATEGORY category, BOOL *offload_capable); - return S_OK; -} +extern HRESULT WINAPI client_SetClientProperties(IAudioClient3 *iface, + const AudioClientProperties *prop); -static HRESULT WINAPI AudioClient_GetBufferSizeLimits(IAudioClient3 *iface, +extern HRESULT WINAPI client_GetBufferSizeLimits(IAudioClient3 *iface, const WAVEFORMATEX *format, BOOL event_driven, REFERENCE_TIME *min_duration, - REFERENCE_TIME *max_duration) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - FIXME("(%p)->(%p, %u, %p, %p)\n", This, format, event_driven, min_duration, max_duration); - - return E_NOTIMPL; -} + REFERENCE_TIME *max_duration); extern HRESULT WINAPI client_GetSharedModeEnginePeriod(IAudioClient3 *iface, const WAVEFORMATEX *format, UINT32 *default_period_frames, UINT32 *unit_period_frames, @@ -1027,9 +979,9 @@ static const IAudioClient3Vtbl AudioClient3_Vtbl = AudioClient_Reset, AudioClient_SetEventHandle, AudioClient_GetService, - AudioClient_IsOffloadCapable, - AudioClient_SetClientProperties, - AudioClient_GetBufferSizeLimits, + client_IsOffloadCapable, + client_SetClientProperties, + client_GetBufferSizeLimits, client_GetSharedModeEnginePeriod, client_GetCurrentSharedModeEnginePeriod, client_InitializeSharedAudioStream,
1
0
0
0
Davide Beatrici : winecoreaudio: Use mmdevapi's AudioClient2.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 1d8e1716744f1428a587c3206e9caf9c29f47828 URL:
https://gitlab.winehq.org/wine/wine/-/commit/1d8e1716744f1428a587c3206e9caf…
Author: Davide Beatrici <git(a)davidebeatrici.dev> Date: Thu May 25 10:23:30 2023 +0200 winecoreaudio: Use mmdevapi's AudioClient2. --- dlls/winecoreaudio.drv/mmdevdrv.c | 66 ++++++--------------------------------- 1 file changed, 9 insertions(+), 57 deletions(-) diff --git a/dlls/winecoreaudio.drv/mmdevdrv.c b/dlls/winecoreaudio.drv/mmdevdrv.c index 66f7b658e24..67bf7b122a4 100644 --- a/dlls/winecoreaudio.drv/mmdevdrv.c +++ b/dlls/winecoreaudio.drv/mmdevdrv.c @@ -943,63 +943,15 @@ end: return hr; } -static HRESULT WINAPI AudioClient_IsOffloadCapable(IAudioClient3 *iface, - AUDIO_STREAM_CATEGORY category, BOOL *offload_capable) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - TRACE("(%p)->(0x%x, %p)\n", This, category, offload_capable); - - if(!offload_capable) - return E_INVALIDARG; - - *offload_capable = FALSE; - - return S_OK; -} - -static HRESULT WINAPI AudioClient_SetClientProperties(IAudioClient3 *iface, - const AudioClientProperties *prop) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - const Win8AudioClientProperties *legacy_prop = (const Win8AudioClientProperties *)prop; - - TRACE("(%p)->(%p)\n", This, prop); - - if(!legacy_prop) - return E_POINTER; - - if(legacy_prop->cbSize == sizeof(AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x, Options: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory, - prop->Options); - }else if(legacy_prop->cbSize == sizeof(Win8AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory); - }else{ - WARN("Unsupported Size = %d\n", legacy_prop->cbSize); - return E_INVALIDARG; - } - - - if(legacy_prop->bIsOffload) - return AUDCLNT_E_ENDPOINT_OFFLOAD_NOT_CAPABLE; +extern HRESULT WINAPI client_IsOffloadCapable(IAudioClient3 *iface, + AUDIO_STREAM_CATEGORY category, BOOL *offload_capable); - return S_OK; -} +extern HRESULT WINAPI client_SetClientProperties(IAudioClient3 *iface, + const AudioClientProperties *prop); -static HRESULT WINAPI AudioClient_GetBufferSizeLimits(IAudioClient3 *iface, +extern HRESULT WINAPI client_GetBufferSizeLimits(IAudioClient3 *iface, const WAVEFORMATEX *format, BOOL event_driven, REFERENCE_TIME *min_duration, - REFERENCE_TIME *max_duration) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - FIXME("(%p)->(%p, %u, %p, %p)\n", This, format, event_driven, min_duration, max_duration); - - return E_NOTIMPL; -} + REFERENCE_TIME *max_duration); extern HRESULT WINAPI client_GetSharedModeEnginePeriod(IAudioClient3 *iface, const WAVEFORMATEX *format, UINT32 *default_period_frames, UINT32 *unit_period_frames, @@ -1029,9 +981,9 @@ static const IAudioClient3Vtbl AudioClient3_Vtbl = AudioClient_Reset, AudioClient_SetEventHandle, AudioClient_GetService, - AudioClient_IsOffloadCapable, - AudioClient_SetClientProperties, - AudioClient_GetBufferSizeLimits, + client_IsOffloadCapable, + client_SetClientProperties, + client_GetBufferSizeLimits, client_GetSharedModeEnginePeriod, client_GetCurrentSharedModeEnginePeriod, client_InitializeSharedAudioStream,
1
0
0
0
Davide Beatrici : winealsa: Use mmdevapi's AudioClient2.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 9b8e23b69b093a6c091de0f3261ac47787528465 URL:
https://gitlab.winehq.org/wine/wine/-/commit/9b8e23b69b093a6c091de0f3261ac4…
Author: Davide Beatrici <git(a)davidebeatrici.dev> Date: Thu May 25 10:20:37 2023 +0200 winealsa: Use mmdevapi's AudioClient2. --- dlls/winealsa.drv/mmdevdrv.c | 66 ++++++-------------------------------------- 1 file changed, 9 insertions(+), 57 deletions(-) diff --git a/dlls/winealsa.drv/mmdevdrv.c b/dlls/winealsa.drv/mmdevdrv.c index 2793a01b2fc..8961f1a3c1d 100644 --- a/dlls/winealsa.drv/mmdevdrv.c +++ b/dlls/winealsa.drv/mmdevdrv.c @@ -978,63 +978,15 @@ static HRESULT WINAPI AudioClient_GetService(IAudioClient3 *iface, REFIID riid, return E_NOINTERFACE; } -static HRESULT WINAPI AudioClient_IsOffloadCapable(IAudioClient3 *iface, - AUDIO_STREAM_CATEGORY category, BOOL *offload_capable) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - TRACE("(%p)->(0x%x, %p)\n", This, category, offload_capable); - - if(!offload_capable) - return E_INVALIDARG; - - *offload_capable = FALSE; - - return S_OK; -} - -static HRESULT WINAPI AudioClient_SetClientProperties(IAudioClient3 *iface, - const AudioClientProperties *prop) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - const Win8AudioClientProperties *legacy_prop = (const Win8AudioClientProperties *)prop; - - TRACE("(%p)->(%p)\n", This, prop); - - if(!legacy_prop) - return E_POINTER; - - if(legacy_prop->cbSize == sizeof(AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x, Options: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory, - prop->Options); - }else if(legacy_prop->cbSize == sizeof(Win8AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory); - }else{ - WARN("Unsupported Size = %d\n", legacy_prop->cbSize); - return E_INVALIDARG; - } - - - if(legacy_prop->bIsOffload) - return AUDCLNT_E_ENDPOINT_OFFLOAD_NOT_CAPABLE; +extern HRESULT WINAPI client_IsOffloadCapable(IAudioClient3 *iface, + AUDIO_STREAM_CATEGORY category, BOOL *offload_capable); - return S_OK; -} +extern HRESULT WINAPI client_SetClientProperties(IAudioClient3 *iface, + const AudioClientProperties *prop); -static HRESULT WINAPI AudioClient_GetBufferSizeLimits(IAudioClient3 *iface, +extern HRESULT WINAPI client_GetBufferSizeLimits(IAudioClient3 *iface, const WAVEFORMATEX *format, BOOL event_driven, REFERENCE_TIME *min_duration, - REFERENCE_TIME *max_duration) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - FIXME("(%p)->(%p, %u, %p, %p)\n", This, format, event_driven, min_duration, max_duration); - - return E_NOTIMPL; -} + REFERENCE_TIME *max_duration); extern HRESULT WINAPI client_GetSharedModeEnginePeriod(IAudioClient3 *iface, const WAVEFORMATEX *format, UINT32 *default_period_frames, UINT32 *unit_period_frames, @@ -1064,9 +1016,9 @@ static const IAudioClient3Vtbl AudioClient3_Vtbl = AudioClient_Reset, AudioClient_SetEventHandle, AudioClient_GetService, - AudioClient_IsOffloadCapable, - AudioClient_SetClientProperties, - AudioClient_GetBufferSizeLimits, + client_IsOffloadCapable, + client_SetClientProperties, + client_GetBufferSizeLimits, client_GetSharedModeEnginePeriod, client_GetCurrentSharedModeEnginePeriod, client_InitializeSharedAudioStream,
1
0
0
0
Davide Beatrici : winepulse: Move AudioClient2 into mmdevapi.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: e054f7294334c985f2ca709a0f8eb975be3cfc26 URL:
https://gitlab.winehq.org/wine/wine/-/commit/e054f7294334c985f2ca709a0f8eb9…
Author: Davide Beatrici <git(a)davidebeatrici.dev> Date: Thu May 25 10:14:58 2023 +0200 winepulse: Move AudioClient2 into mmdevapi. --- dlls/mmdevapi/client.c | 53 ++++++++++++++++++++++++++++++++++ dlls/winepulse.drv/mmdevdrv.c | 66 ++++++------------------------------------- 2 files changed, 62 insertions(+), 57 deletions(-) diff --git a/dlls/mmdevapi/client.c b/dlls/mmdevapi/client.c index eebae0d3dca..87bc3fef0e5 100644 --- a/dlls/mmdevapi/client.c +++ b/dlls/mmdevapi/client.c @@ -194,6 +194,59 @@ const IAudioCaptureClientVtbl AudioCaptureClient_Vtbl = capture_GetNextPacketSize }; +HRESULT WINAPI client_IsOffloadCapable(IAudioClient3 *iface, AUDIO_STREAM_CATEGORY category, + BOOL *offload_capable) +{ + struct audio_client *This = impl_from_IAudioClient3(iface); + + TRACE("(%p)->(0x%x, %p)\n", This, category, offload_capable); + + if (!offload_capable) + return E_INVALIDARG; + + *offload_capable = FALSE; + + return S_OK; +} + +HRESULT WINAPI client_SetClientProperties(IAudioClient3 *iface, + const AudioClientProperties *prop) +{ + struct audio_client *This = impl_from_IAudioClient3(iface); + const Win8AudioClientProperties *legacy_prop = (const Win8AudioClientProperties *)prop; + + TRACE("(%p)->(%p)\n", This, prop); + + if (!legacy_prop) + return E_POINTER; + + if (legacy_prop->cbSize == sizeof(AudioClientProperties)) { + TRACE("{ bIsOffload: %u, eCategory: 0x%x, Options: 0x%x }\n", legacy_prop->bIsOffload, + legacy_prop->eCategory, + prop->Options); + } else if(legacy_prop->cbSize == sizeof(Win8AudioClientProperties)) { + TRACE("{ bIsOffload: %u, eCategory: 0x%x }\n", legacy_prop->bIsOffload, + legacy_prop->eCategory); + } else { + WARN("Unsupported Size = %d\n", legacy_prop->cbSize); + return E_INVALIDARG; + } + + if (legacy_prop->bIsOffload) + return AUDCLNT_E_ENDPOINT_OFFLOAD_NOT_CAPABLE; + + return S_OK; +} + +HRESULT WINAPI client_GetBufferSizeLimits(IAudioClient3 *iface, const WAVEFORMATEX *format, + BOOL event_driven, REFERENCE_TIME *min_duration, + REFERENCE_TIME *max_duration) +{ + struct audio_client *This = impl_from_IAudioClient3(iface); + FIXME("(%p)->(%p, %u, %p, %p) - stub\n", This, format, event_driven, min_duration, max_duration); + return E_NOTIMPL; +} + HRESULT WINAPI client_GetSharedModeEnginePeriod(IAudioClient3 *iface, const WAVEFORMATEX *format, UINT32 *default_period_frames, diff --git a/dlls/winepulse.drv/mmdevdrv.c b/dlls/winepulse.drv/mmdevdrv.c index 99be7ccb43e..def79d7f961 100644 --- a/dlls/winepulse.drv/mmdevdrv.c +++ b/dlls/winepulse.drv/mmdevdrv.c @@ -1071,63 +1071,15 @@ static HRESULT WINAPI AudioClient_GetService(IAudioClient3 *iface, REFIID riid, return E_NOINTERFACE; } -static HRESULT WINAPI AudioClient_IsOffloadCapable(IAudioClient3 *iface, - AUDIO_STREAM_CATEGORY category, BOOL *offload_capable) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - TRACE("(%p)->(0x%x, %p)\n", This, category, offload_capable); - - if(!offload_capable) - return E_INVALIDARG; - - *offload_capable = FALSE; - - return S_OK; -} +extern HRESULT WINAPI client_IsOffloadCapable(IAudioClient3 *iface, + AUDIO_STREAM_CATEGORY category, BOOL *offload_capable); -static HRESULT WINAPI AudioClient_SetClientProperties(IAudioClient3 *iface, - const AudioClientProperties *prop) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - const Win8AudioClientProperties *legacy_prop = (const Win8AudioClientProperties *)prop; - - TRACE("(%p)->(%p)\n", This, prop); - - if(!legacy_prop) - return E_POINTER; +extern HRESULT WINAPI client_SetClientProperties(IAudioClient3 *iface, + const AudioClientProperties *prop); - if(legacy_prop->cbSize == sizeof(AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x, Options: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory, - prop->Options); - }else if(legacy_prop->cbSize == sizeof(Win8AudioClientProperties)){ - TRACE("{ bIsOffload: %u, eCategory: 0x%x }\n", - legacy_prop->bIsOffload, - legacy_prop->eCategory); - }else{ - WARN("Unsupported Size = %d\n", legacy_prop->cbSize); - return E_INVALIDARG; - } - - - if(legacy_prop->bIsOffload) - return AUDCLNT_E_ENDPOINT_OFFLOAD_NOT_CAPABLE; - - return S_OK; -} - -static HRESULT WINAPI AudioClient_GetBufferSizeLimits(IAudioClient3 *iface, +extern HRESULT WINAPI client_GetBufferSizeLimits(IAudioClient3 *iface, const WAVEFORMATEX *format, BOOL event_driven, REFERENCE_TIME *min_duration, - REFERENCE_TIME *max_duration) -{ - ACImpl *This = impl_from_IAudioClient3(iface); - - FIXME("(%p)->(%p, %u, %p, %p)\n", This, format, event_driven, min_duration, max_duration); - - return E_NOTIMPL; -} + REFERENCE_TIME *max_duration); extern HRESULT WINAPI client_GetSharedModeEnginePeriod(IAudioClient3 *iface, const WAVEFORMATEX *format, UINT32 *default_period_frames, UINT32 *unit_period_frames, @@ -1157,9 +1109,9 @@ static const IAudioClient3Vtbl AudioClient3_Vtbl = AudioClient_Reset, AudioClient_SetEventHandle, AudioClient_GetService, - AudioClient_IsOffloadCapable, - AudioClient_SetClientProperties, - AudioClient_GetBufferSizeLimits, + client_IsOffloadCapable, + client_SetClientProperties, + client_GetBufferSizeLimits, client_GetSharedModeEnginePeriod, client_GetCurrentSharedModeEnginePeriod, client_InitializeSharedAudioStream,
1
0
0
0
Alex Henrie : iphlpapi: Add GetCurrentThreadCompartmentId stub and a test.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 4050ceb22f6cb935f535502dfa8dbbd1afe2c28f URL:
https://gitlab.winehq.org/wine/wine/-/commit/4050ceb22f6cb935f535502dfa8dbb…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Tue May 30 21:20:27 2023 -0600 iphlpapi: Add GetCurrentThreadCompartmentId stub and a test. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=54599
--- dlls/iphlpapi/iphlpapi.spec | 2 +- dlls/iphlpapi/iphlpapi_main.c | 9 +++++++++ dlls/iphlpapi/tests/iphlpapi.c | 9 +++++++++ include/netioapi.h | 1 + 4 files changed, 20 insertions(+), 1 deletion(-) diff --git a/dlls/iphlpapi/iphlpapi.spec b/dlls/iphlpapi/iphlpapi.spec index 90bf290c9bd..76701d686e0 100644 --- a/dlls/iphlpapi/iphlpapi.spec +++ b/dlls/iphlpapi/iphlpapi.spec @@ -80,7 +80,7 @@ @ stdcall GetBestRoute( long long ptr ) @ stdcall GetBestRoute2( ptr long ptr ptr long ptr ptr ) @ stub GetBestRouteFromStack -#@ stub GetCurrentThreadCompartmentId +@ stdcall GetCurrentThreadCompartmentId() @ stdcall GetExtendedTcpTable( ptr ptr long long long long ) @ stdcall GetExtendedUdpTable( ptr ptr long long long long ) @ stdcall GetFriendlyIfIndex( long ) diff --git a/dlls/iphlpapi/iphlpapi_main.c b/dlls/iphlpapi/iphlpapi_main.c index d22209ff719..c4921d4a5ac 100644 --- a/dlls/iphlpapi/iphlpapi_main.c +++ b/dlls/iphlpapi/iphlpapi_main.c @@ -4750,3 +4750,12 @@ DWORD WINAPI Icmp6SendEcho2( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc_ro SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); return 0; } + +/*********************************************************************** + * GetCurrentThreadCompartmentId (IPHLPAPI.@) + */ +NET_IF_COMPARTMENT_ID WINAPI GetCurrentThreadCompartmentId( void ) +{ + FIXME( "stub\n" ); + return NET_IF_COMPARTMENT_ID_PRIMARY; +} diff --git a/dlls/iphlpapi/tests/iphlpapi.c b/dlls/iphlpapi/tests/iphlpapi.c index 5301a409126..8002afc0a89 100644 --- a/dlls/iphlpapi/tests/iphlpapi.c +++ b/dlls/iphlpapi/tests/iphlpapi.c @@ -2893,6 +2893,14 @@ static void test_ConvertGuidToString( void ) ok( err == ERROR_INVALID_PARAMETER, "got %ld\n", err ); } +static void test_compartments(void) +{ + NET_IF_COMPARTMENT_ID id; + + id = GetCurrentThreadCompartmentId(); + ok(id == NET_IF_COMPARTMENT_ID_PRIMARY, "got %u\n", id); +} + START_TEST(iphlpapi) { @@ -2927,6 +2935,7 @@ START_TEST(iphlpapi) test_ParseNetworkString(); test_NotifyUnicastIpAddressChange(); test_ConvertGuidToString(); + test_compartments(); freeIPHlpApi(); } } diff --git a/include/netioapi.h b/include/netioapi.h index 6005e58e216..40f0674c1d8 100644 --- a/include/netioapi.h +++ b/include/netioapi.h @@ -250,6 +250,7 @@ DWORD WINAPI ConvertInterfaceNameToLuidA(const char*,NET_LUID*); DWORD WINAPI ConvertInterfaceNameToLuidW(const WCHAR*,NET_LUID*); DWORD WINAPI ConvertLengthToIpv4Mask(ULONG,ULONG*); void WINAPI FreeMibTable(void*); +NET_IF_COMPARTMENT_ID WINAPI GetCurrentThreadCompartmentId(void); DWORD WINAPI GetIfEntry2(MIB_IF_ROW2*); DWORD WINAPI GetIfEntry2Ex(MIB_IF_TABLE_LEVEL,MIB_IF_ROW2*); DWORD WINAPI GetIfTable2(MIB_IF_TABLE2**);
1
0
0
0
Rémi Bernon : win32u: Use WM_WINE_CLIPCURSOR / TRUE for empty clipping rect.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 900ba826540f4b10ad834109e520b097e2dbf415 URL:
https://gitlab.winehq.org/wine/wine/-/commit/900ba826540f4b10ad834109e520b0…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Wed May 31 11:23:40 2023 +0200 win32u: Use WM_WINE_CLIPCURSOR / TRUE for empty clipping rect. --- dlls/win32u/message.c | 2 +- server/queue.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/win32u/message.c b/dlls/win32u/message.c index dfe9eadd34a..44cd0640434 100644 --- a/dlls/win32u/message.c +++ b/dlls/win32u/message.c @@ -1272,7 +1272,7 @@ static LRESULT handle_internal_message( HWND hwnd, UINT msg, WPARAM wparam, LPAR return call_current_hook( h_extra->handle, HC_ACTION, wparam, h_extra->lparam ); } case WM_WINE_CLIPCURSOR: - return process_wine_clipcursor( !wparam ); + return process_wine_clipcursor( wparam ); case WM_WINE_UPDATEWINDOWSTATE: update_window_state( hwnd ); return 0; diff --git a/server/queue.c b/server/queue.c index 746316a4286..e27727a3173 100644 --- a/server/queue.c +++ b/server/queue.c @@ -468,7 +468,7 @@ static void set_clip_rectangle( struct desktop *desktop, const rectangle_t *rect } else desktop->cursor.clip = top_rect; - if (send_clip_msg) post_desktop_message( desktop, WM_WINE_CLIPCURSOR, rect != NULL, 0 ); + if (send_clip_msg) post_desktop_message( desktop, WM_WINE_CLIPCURSOR, rect == NULL, 0 ); /* warp the mouse to be inside the clip rect */ x = max( min( desktop->cursor.x, desktop->cursor.clip.right - 1 ), desktop->cursor.clip.left );
1
0
0
0
Rémi Bernon : win32u: Add a separate function to process WM_WINE_CLIPCURSOR.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 3bce247bd2c6b678d23c271fb5a8c8867a1be3f2 URL:
https://gitlab.winehq.org/wine/wine/-/commit/3bce247bd2c6b678d23c271fb5a8c8…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Fri May 26 22:18:32 2023 +0200 win32u: Add a separate function to process WM_WINE_CLIPCURSOR. --- dlls/win32u/input.c | 12 ++++++++++++ dlls/win32u/message.c | 8 +------- dlls/win32u/win32u_private.h | 1 + 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/dlls/win32u/input.c b/dlls/win32u/input.c index 3fc7c85aaa2..22f371969b9 100644 --- a/dlls/win32u/input.c +++ b/dlls/win32u/input.c @@ -2497,6 +2497,18 @@ BOOL get_clip_cursor( RECT *rect ) return ret; } +BOOL process_wine_clipcursor( BOOL empty ) +{ + RECT rect; + + TRACE( "empty %u\n", empty ); + + if (empty) return user_driver->pClipCursor( NULL ); + + get_clip_cursor( &rect ); + return user_driver->pClipCursor( &rect ); +} + /*********************************************************************** * NtUserClipCursor (win32u.@) */ diff --git a/dlls/win32u/message.c b/dlls/win32u/message.c index b3d94120455..dfe9eadd34a 100644 --- a/dlls/win32u/message.c +++ b/dlls/win32u/message.c @@ -1272,13 +1272,7 @@ static LRESULT handle_internal_message( HWND hwnd, UINT msg, WPARAM wparam, LPAR return call_current_hook( h_extra->handle, HC_ACTION, wparam, h_extra->lparam ); } case WM_WINE_CLIPCURSOR: - if (wparam) - { - RECT rect; - get_clip_cursor( &rect ); - return user_driver->pClipCursor( &rect ); - } - return user_driver->pClipCursor( NULL ); + return process_wine_clipcursor( !wparam ); case WM_WINE_UPDATEWINDOWSTATE: update_window_state( hwnd ); return 0; diff --git a/dlls/win32u/win32u_private.h b/dlls/win32u/win32u_private.h index 4116cda449a..a459db75d94 100644 --- a/dlls/win32u/win32u_private.h +++ b/dlls/win32u/win32u_private.h @@ -101,6 +101,7 @@ extern BOOL set_foreground_window( HWND hwnd, BOOL mouse ) DECLSPEC_HIDDEN; extern void toggle_caret( HWND hwnd ) DECLSPEC_HIDDEN; extern void update_mouse_tracking_info( HWND hwnd ) DECLSPEC_HIDDEN; extern BOOL get_clip_cursor( RECT *rect ) DECLSPEC_HIDDEN; +extern BOOL process_wine_clipcursor( BOOL empty ) DECLSPEC_HIDDEN; /* menu.c */ extern HMENU create_menu( BOOL is_popup ) DECLSPEC_HIDDEN;
1
0
0
0
Rémi Bernon : win32u: Move cursor clipping functions to input.c.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 1cea2be9e822d25b508f8b709d58602768b37d2d URL:
https://gitlab.winehq.org/wine/wine/-/commit/1cea2be9e822d25b508f8b709d5860…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Fri May 26 22:04:20 2023 +0200 win32u: Move cursor clipping functions to input.c. --- dlls/win32u/cursoricon.c | 75 -------------------------------------------- dlls/win32u/input.c | 75 ++++++++++++++++++++++++++++++++++++++++++++ dlls/win32u/win32u_private.h | 2 +- 3 files changed, 76 insertions(+), 76 deletions(-) diff --git a/dlls/win32u/cursoricon.c b/dlls/win32u/cursoricon.c index 584a2cffca7..ae9dc6f6b8b 100644 --- a/dlls/win32u/cursoricon.c +++ b/dlls/win32u/cursoricon.c @@ -150,81 +150,6 @@ HCURSOR WINAPI NtUserGetCursor(void) return ret; } -/*********************************************************************** - * NtUserClipCursor (win32u.@) - */ -BOOL WINAPI NtUserClipCursor( const RECT *rect ) -{ - UINT dpi; - BOOL ret; - RECT new_rect; - - TRACE( "Clipping to %s\n", wine_dbgstr_rect(rect) ); - - if (rect) - { - if (rect->left > rect->right || rect->top > rect->bottom) return FALSE; - if ((dpi = get_thread_dpi())) - { - HMONITOR monitor = monitor_from_rect( rect, MONITOR_DEFAULTTOPRIMARY, dpi ); - new_rect = map_dpi_rect( *rect, dpi, get_monitor_dpi( monitor )); - rect = &new_rect; - } - } - - SERVER_START_REQ( set_cursor ) - { - if (rect) - { - req->flags = SET_CURSOR_CLIP; - req->clip.left = rect->left; - req->clip.top = rect->top; - req->clip.right = rect->right; - req->clip.bottom = rect->bottom; - } - else req->flags = SET_CURSOR_NOCLIP; - - if ((ret = !wine_server_call( req ))) - { - new_rect.left = reply->new_clip.left; - new_rect.top = reply->new_clip.top; - new_rect.right = reply->new_clip.right; - new_rect.bottom = reply->new_clip.bottom; - } - } - SERVER_END_REQ; - if (ret) user_driver->pClipCursor( &new_rect ); - return ret; -} - -BOOL get_clip_cursor( RECT *rect ) -{ - UINT dpi; - BOOL ret; - - if (!rect) return FALSE; - - SERVER_START_REQ( set_cursor ) - { - req->flags = 0; - if ((ret = !wine_server_call( req ))) - { - rect->left = reply->new_clip.left; - rect->top = reply->new_clip.top; - rect->right = reply->new_clip.right; - rect->bottom = reply->new_clip.bottom; - } - } - SERVER_END_REQ; - - if (ret && (dpi = get_thread_dpi())) - { - HMONITOR monitor = monitor_from_rect( rect, MONITOR_DEFAULTTOPRIMARY, 0 ); - *rect = map_dpi_rect( *rect, get_monitor_dpi( monitor ), dpi ); - } - return ret; -} - HICON alloc_cursoricon_handle( BOOL is_icon ) { struct cursoricon_object *obj; diff --git a/dlls/win32u/input.c b/dlls/win32u/input.c index d4bc76874ea..3fc7c85aaa2 100644 --- a/dlls/win32u/input.c +++ b/dlls/win32u/input.c @@ -2468,3 +2468,78 @@ BOOL WINAPI NtUserGetPointerInfoList( UINT32 id, POINTER_INPUT_TYPE type, UINT_P RtlSetLastWin32Error( ERROR_CALL_NOT_IMPLEMENTED ); return FALSE; } + +BOOL get_clip_cursor( RECT *rect ) +{ + UINT dpi; + BOOL ret; + + if (!rect) return FALSE; + + SERVER_START_REQ( set_cursor ) + { + req->flags = 0; + if ((ret = !wine_server_call( req ))) + { + rect->left = reply->new_clip.left; + rect->top = reply->new_clip.top; + rect->right = reply->new_clip.right; + rect->bottom = reply->new_clip.bottom; + } + } + SERVER_END_REQ; + + if (ret && (dpi = get_thread_dpi())) + { + HMONITOR monitor = monitor_from_rect( rect, MONITOR_DEFAULTTOPRIMARY, 0 ); + *rect = map_dpi_rect( *rect, get_monitor_dpi( monitor ), dpi ); + } + return ret; +} + +/*********************************************************************** + * NtUserClipCursor (win32u.@) + */ +BOOL WINAPI NtUserClipCursor( const RECT *rect ) +{ + UINT dpi; + BOOL ret; + RECT new_rect; + + TRACE( "Clipping to %s\n", wine_dbgstr_rect(rect) ); + + if (rect) + { + if (rect->left > rect->right || rect->top > rect->bottom) return FALSE; + if ((dpi = get_thread_dpi())) + { + HMONITOR monitor = monitor_from_rect( rect, MONITOR_DEFAULTTOPRIMARY, dpi ); + new_rect = map_dpi_rect( *rect, dpi, get_monitor_dpi( monitor )); + rect = &new_rect; + } + } + + SERVER_START_REQ( set_cursor ) + { + if (rect) + { + req->flags = SET_CURSOR_CLIP; + req->clip.left = rect->left; + req->clip.top = rect->top; + req->clip.right = rect->right; + req->clip.bottom = rect->bottom; + } + else req->flags = SET_CURSOR_NOCLIP; + + if ((ret = !wine_server_call( req ))) + { + new_rect.left = reply->new_clip.left; + new_rect.top = reply->new_clip.top; + new_rect.right = reply->new_clip.right; + new_rect.bottom = reply->new_clip.bottom; + } + } + SERVER_END_REQ; + if (ret) user_driver->pClipCursor( &new_rect ); + return ret; +} diff --git a/dlls/win32u/win32u_private.h b/dlls/win32u/win32u_private.h index bd0adba276c..4116cda449a 100644 --- a/dlls/win32u/win32u_private.h +++ b/dlls/win32u/win32u_private.h @@ -39,7 +39,6 @@ extern void release_clipboard_owner( HWND hwnd ) DECLSPEC_HIDDEN; /* cursoricon.c */ extern HICON alloc_cursoricon_handle( BOOL is_icon ) DECLSPEC_HIDDEN; -extern BOOL get_clip_cursor( RECT *rect ) DECLSPEC_HIDDEN; extern ULONG_PTR get_icon_param( HICON handle ) DECLSPEC_HIDDEN; extern ULONG_PTR set_icon_param( HICON handle, ULONG_PTR param ) DECLSPEC_HIDDEN; @@ -101,6 +100,7 @@ extern BOOL set_caret_pos( int x, int y ) DECLSPEC_HIDDEN; extern BOOL set_foreground_window( HWND hwnd, BOOL mouse ) DECLSPEC_HIDDEN; extern void toggle_caret( HWND hwnd ) DECLSPEC_HIDDEN; extern void update_mouse_tracking_info( HWND hwnd ) DECLSPEC_HIDDEN; +extern BOOL get_clip_cursor( RECT *rect ) DECLSPEC_HIDDEN; /* menu.c */ extern HMENU create_menu( BOOL is_popup ) DECLSPEC_HIDDEN;
1
0
0
0
Rémi Bernon : win32u: Move some window functions to window.c.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: c22c10d6e923ea3fb53412b3f218bf9eeeef4cb2 URL:
https://gitlab.winehq.org/wine/wine/-/commit/c22c10d6e923ea3fb53412b3f218bf…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Fri May 26 22:03:34 2023 +0200 win32u: Move some window functions to window.c. --- dlls/win32u/input.c | 112 ------------------------------------------ dlls/win32u/win32u_private.h | 10 ++-- dlls/win32u/window.c | 113 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 118 insertions(+), 117 deletions(-) diff --git a/dlls/win32u/input.c b/dlls/win32u/input.c index f75ca3b0a64..d4bc76874ea 100644 --- a/dlls/win32u/input.c +++ b/dlls/win32u/input.c @@ -2468,115 +2468,3 @@ BOOL WINAPI NtUserGetPointerInfoList( UINT32 id, POINTER_INPUT_TYPE type, UINT_P RtlSetLastWin32Error( ERROR_CALL_NOT_IMPLEMENTED ); return FALSE; } - -HWND get_shell_window(void) -{ - HWND hwnd = 0; - - SERVER_START_REQ(set_global_windows) - { - req->flags = 0; - if (!wine_server_call_err(req)) - hwnd = wine_server_ptr_handle( reply->old_shell_window ); - } - SERVER_END_REQ; - - return hwnd; -} - -/*********************************************************************** -* NtUserSetShellWindowEx (win32u.@) -*/ -BOOL WINAPI NtUserSetShellWindowEx( HWND shell, HWND list_view ) -{ - BOOL ret; - - /* shell = Progman[Program Manager] - * |-> SHELLDLL_DefView - * list_view = | |-> SysListView32 - * | | |-> tooltips_class32 - * | | - * | |-> SysHeader32 - * | - * |-> ProxyTarget - */ - - if (get_shell_window()) - return FALSE; - - if (get_window_long( shell, GWL_EXSTYLE ) & WS_EX_TOPMOST) - return FALSE; - - if (list_view != shell && (get_window_long( list_view, GWL_EXSTYLE ) & WS_EX_TOPMOST)) - return FALSE; - - if (list_view && list_view != shell) - NtUserSetWindowPos( list_view, HWND_BOTTOM, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE ); - - NtUserSetWindowPos( shell, HWND_BOTTOM, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE ); - - SERVER_START_REQ(set_global_windows) - { - req->flags = SET_GLOBAL_SHELL_WINDOWS; - req->shell_window = wine_server_user_handle( shell ); - req->shell_listview = wine_server_user_handle( list_view ); - ret = !wine_server_call_err(req); - } - SERVER_END_REQ; - return ret; -} - -HWND get_progman_window(void) -{ - HWND ret = 0; - - SERVER_START_REQ(set_global_windows) - { - req->flags = 0; - if (!wine_server_call_err(req)) - ret = wine_server_ptr_handle( reply->old_progman_window ); - } - SERVER_END_REQ; - return ret; -} - -HWND set_progman_window( HWND hwnd ) -{ - SERVER_START_REQ(set_global_windows) - { - req->flags = SET_GLOBAL_PROGMAN_WINDOW; - req->progman_window = wine_server_user_handle( hwnd ); - if (wine_server_call_err( req )) hwnd = 0; - } - SERVER_END_REQ; - return hwnd; -} - -HWND get_taskman_window(void) -{ - HWND ret = 0; - - SERVER_START_REQ(set_global_windows) - { - req->flags = 0; - if (!wine_server_call_err(req)) - ret = wine_server_ptr_handle( reply->old_taskman_window ); - } - SERVER_END_REQ; - return ret; -} - -HWND set_taskman_window( HWND hwnd ) -{ - /* hwnd = MSTaskSwWClass - * |-> SysTabControl32 - */ - SERVER_START_REQ(set_global_windows) - { - req->flags = SET_GLOBAL_TASKMAN_WINDOW; - req->taskman_window = wine_server_user_handle( hwnd ); - if (wine_server_call_err( req )) hwnd = 0; - } - SERVER_END_REQ; - return hwnd; -} diff --git a/dlls/win32u/win32u_private.h b/dlls/win32u/win32u_private.h index 4f648993199..bd0adba276c 100644 --- a/dlls/win32u/win32u_private.h +++ b/dlls/win32u/win32u_private.h @@ -94,16 +94,11 @@ extern HWND get_capture(void) DECLSPEC_HIDDEN; extern BOOL get_cursor_pos( POINT *pt ) DECLSPEC_HIDDEN; extern HWND get_focus(void) DECLSPEC_HIDDEN; extern DWORD get_input_state(void) DECLSPEC_HIDDEN; -extern HWND get_progman_window(void) DECLSPEC_HIDDEN; -extern HWND get_shell_window(void) DECLSPEC_HIDDEN; -extern HWND get_taskman_window(void) DECLSPEC_HIDDEN; extern BOOL release_capture(void) DECLSPEC_HIDDEN; extern BOOL set_capture_window( HWND hwnd, UINT gui_flags, HWND *prev_ret ) DECLSPEC_HIDDEN; extern BOOL set_caret_blink_time( unsigned int time ) DECLSPEC_HIDDEN; extern BOOL set_caret_pos( int x, int y ) DECLSPEC_HIDDEN; extern BOOL set_foreground_window( HWND hwnd, BOOL mouse ) DECLSPEC_HIDDEN; -extern HWND set_progman_window( HWND hwnd ) DECLSPEC_HIDDEN; -extern HWND set_taskman_window( HWND hwnd ) DECLSPEC_HIDDEN; extern void toggle_caret( HWND hwnd ) DECLSPEC_HIDDEN; extern void update_mouse_tracking_info( HWND hwnd ) DECLSPEC_HIDDEN; @@ -232,6 +227,11 @@ extern ULONG set_window_style( HWND hwnd, ULONG set_bits, ULONG clear_bits ) DEC extern BOOL show_owned_popups( HWND owner, BOOL show ) DECLSPEC_HIDDEN; extern void update_window_state( HWND hwnd ) DECLSPEC_HIDDEN; extern HWND window_from_point( HWND hwnd, POINT pt, INT *hittest ) DECLSPEC_HIDDEN; +extern HWND get_shell_window(void) DECLSPEC_HIDDEN; +extern HWND get_progman_window(void) DECLSPEC_HIDDEN; +extern HWND set_progman_window( HWND hwnd ) DECLSPEC_HIDDEN; +extern HWND get_taskman_window(void) DECLSPEC_HIDDEN; +extern HWND set_taskman_window( HWND hwnd ) DECLSPEC_HIDDEN; /* to release pointers retrieved by win_get_ptr */ static inline void release_win_ptr( struct tagWND *ptr ) diff --git a/dlls/win32u/window.c b/dlls/win32u/window.c index e1cd80f8a36..871227645a7 100644 --- a/dlls/win32u/window.c +++ b/dlls/win32u/window.c @@ -5644,3 +5644,116 @@ DWORD WINAPI NtUserDragObject( HWND parent, HWND hwnd, UINT fmt, ULONG_PTR data, return 0; } + + +HWND get_shell_window(void) +{ + HWND hwnd = 0; + + SERVER_START_REQ(set_global_windows) + { + req->flags = 0; + if (!wine_server_call_err(req)) + hwnd = wine_server_ptr_handle( reply->old_shell_window ); + } + SERVER_END_REQ; + + return hwnd; +} + +/*********************************************************************** +* NtUserSetShellWindowEx (win32u.@) +*/ +BOOL WINAPI NtUserSetShellWindowEx( HWND shell, HWND list_view ) +{ + BOOL ret; + + /* shell = Progman[Program Manager] + * |-> SHELLDLL_DefView + * list_view = | |-> SysListView32 + * | | |-> tooltips_class32 + * | | + * | |-> SysHeader32 + * | + * |-> ProxyTarget + */ + + if (get_shell_window()) + return FALSE; + + if (get_window_long( shell, GWL_EXSTYLE ) & WS_EX_TOPMOST) + return FALSE; + + if (list_view != shell && (get_window_long( list_view, GWL_EXSTYLE ) & WS_EX_TOPMOST)) + return FALSE; + + if (list_view && list_view != shell) + NtUserSetWindowPos( list_view, HWND_BOTTOM, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE ); + + NtUserSetWindowPos( shell, HWND_BOTTOM, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE ); + + SERVER_START_REQ(set_global_windows) + { + req->flags = SET_GLOBAL_SHELL_WINDOWS; + req->shell_window = wine_server_user_handle( shell ); + req->shell_listview = wine_server_user_handle( list_view ); + ret = !wine_server_call_err(req); + } + SERVER_END_REQ; + return ret; +} + +HWND get_progman_window(void) +{ + HWND ret = 0; + + SERVER_START_REQ(set_global_windows) + { + req->flags = 0; + if (!wine_server_call_err(req)) + ret = wine_server_ptr_handle( reply->old_progman_window ); + } + SERVER_END_REQ; + return ret; +} + +HWND set_progman_window( HWND hwnd ) +{ + SERVER_START_REQ(set_global_windows) + { + req->flags = SET_GLOBAL_PROGMAN_WINDOW; + req->progman_window = wine_server_user_handle( hwnd ); + if (wine_server_call_err( req )) hwnd = 0; + } + SERVER_END_REQ; + return hwnd; +} + +HWND get_taskman_window(void) +{ + HWND ret = 0; + + SERVER_START_REQ(set_global_windows) + { + req->flags = 0; + if (!wine_server_call_err(req)) + ret = wine_server_ptr_handle( reply->old_taskman_window ); + } + SERVER_END_REQ; + return ret; +} + +HWND set_taskman_window( HWND hwnd ) +{ + /* hwnd = MSTaskSwWClass + * |-> SysTabControl32 + */ + SERVER_START_REQ(set_global_windows) + { + req->flags = SET_GLOBAL_TASKMAN_WINDOW; + req->taskman_window = wine_server_user_handle( hwnd ); + if (wine_server_call_err( req )) hwnd = 0; + } + SERVER_END_REQ; + return hwnd; +}
1
0
0
0
Rémi Bernon : server: Use get_hardware_msg_bit consistently to classify messages.
by Alexandre Julliard
31 May '23
31 May '23
Module: wine Branch: master Commit: 8f9610fdff41b26c5129ee7a46c05ecbbf73042f URL:
https://gitlab.winehq.org/wine/wine/-/commit/8f9610fdff41b26c5129ee7a46c05e…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Thu Jan 26 21:26:45 2023 +0100 server: Use get_hardware_msg_bit consistently to classify messages. --- server/queue.c | 53 +++++++++++++++++++++++++---------------------------- 1 file changed, 25 insertions(+), 28 deletions(-) diff --git a/server/queue.c b/server/queue.c index 22842ff286f..746316a4286 100644 --- a/server/queue.c +++ b/server/queue.c @@ -531,12 +531,6 @@ static inline void clear_queue_bits( struct msg_queue *queue, unsigned int bits } } -/* check whether msg is a keyboard message */ -static inline int is_keyboard_msg( struct message *msg ) -{ - return (msg->msg >= WM_KEYFIRST && msg->msg <= WM_KEYLAST); -} - /* check if message is matched by the filter */ static inline int check_msg_filter( unsigned int msg, unsigned int first, unsigned int last ) { @@ -563,7 +557,7 @@ static inline int get_hardware_msg_bit( struct message *msg ) { if (msg->msg == WM_INPUT_DEVICE_CHANGE || msg->msg == WM_INPUT) return QS_RAWINPUT; if (msg->msg == WM_MOUSEMOVE || msg->msg == WM_NCMOUSEMOVE) return QS_MOUSEMOVE; - if (is_keyboard_msg( msg )) return QS_KEY; + if (msg->msg >= WM_KEYFIRST && msg->msg <= WM_KEYLAST) return QS_KEY; return QS_MOUSEBUTTON; } @@ -1507,24 +1501,27 @@ static user_handle_t find_hardware_message_window( struct desktop *desktop, stru *thread = NULL; *msg_code = msg->msg; - if (msg->msg == WM_INPUT || msg->msg == WM_INPUT_DEVICE_CHANGE) + switch (get_hardware_msg_bit( msg )) { + case QS_RAWINPUT: if (!(win = msg->win) && input) win = input->focus; - } - else if (is_keyboard_msg( msg )) - { + break; + case QS_KEY: if (input && !(win = input->focus)) { win = input->active; if (*msg_code < WM_SYSKEYDOWN) *msg_code += WM_SYSKEYDOWN - WM_KEYDOWN; } - } - else if (!input || !(win = input->capture)) /* mouse message */ - { - if (is_window_visible( msg->win ) && !is_window_transparent( msg->win )) win = msg->win; - else win = shallow_window_from_point( desktop, msg->x, msg->y ); - - *thread = window_thread_from_point( win, msg->x, msg->y ); + break; + case QS_MOUSEMOVE: + case QS_MOUSEBUTTON: + if (!input || !(win = input->capture)) + { + if (is_window_visible( msg->win ) && !is_window_transparent( msg->win )) win = msg->win; + else win = shallow_window_from_point( desktop, msg->x, msg->y ); + *thread = window_thread_from_point( win, msg->x, msg->y ); + } + break; } if (!*thread) @@ -1568,20 +1565,19 @@ static void queue_hardware_message( struct desktop *desktop, struct message *msg last_input_time = get_tick_count(); if (msg->msg != WM_MOUSEMOVE) always_queue = 1; - if (is_keyboard_msg( msg )) + switch (get_hardware_msg_bit( msg )) { + case QS_KEY: if (queue_hotkey_message( desktop, msg )) return; if (desktop->keystate[VK_MENU] & 0x80) msg->lparam |= KF_ALTDOWN << 16; if (msg->wparam == VK_SHIFT || msg->wparam == VK_LSHIFT || msg->wparam == VK_RSHIFT) msg->lparam &= ~(KF_EXTENDED << 16); - } - else if (msg->msg != WM_INPUT && msg->msg != WM_INPUT_DEVICE_CHANGE) - { - if (msg->msg == WM_MOUSEMOVE) - { - prepend_cursor_history( msg->x, msg->y, msg->time, msg_data->info ); - if (update_desktop_cursor_pos( desktop, msg->x, msg->y )) always_queue = 1; - } + break; + case QS_MOUSEMOVE: + prepend_cursor_history( msg->x, msg->y, msg->time, msg_data->info ); + if (update_desktop_cursor_pos( desktop, msg->x, msg->y )) always_queue = 1; + /* fallthrough */ + case QS_MOUSEBUTTON: if (desktop->keystate[VK_LBUTTON] & 0x80) msg->wparam |= MK_LBUTTON; if (desktop->keystate[VK_MBUTTON] & 0x80) msg->wparam |= MK_MBUTTON; if (desktop->keystate[VK_RBUTTON] & 0x80) msg->wparam |= MK_RBUTTON; @@ -1589,6 +1585,7 @@ static void queue_hardware_message( struct desktop *desktop, struct message *msg if (desktop->keystate[VK_CONTROL] & 0x80) msg->wparam |= MK_CONTROL; if (desktop->keystate[VK_XBUTTON1] & 0x80) msg->wparam |= MK_XBUTTON1; if (desktop->keystate[VK_XBUTTON2] & 0x80) msg->wparam |= MK_XBUTTON2; + break; } msg->x = desktop->cursor.x; msg->y = desktop->cursor.y; @@ -2186,7 +2183,7 @@ static int get_hardware_message( struct thread *thread, unsigned int hw_id, user data->hw_id = msg->unique_id; set_reply_data( msg->data, msg->data_size ); - if ((msg->msg == WM_INPUT || msg->msg == WM_INPUT_DEVICE_CHANGE) && (flags & PM_REMOVE)) + if (get_hardware_msg_bit( msg ) == QS_RAWINPUT && (flags & PM_REMOVE)) release_hardware_message( current->queue, data->hw_id ); return 1; }
1
0
0
0
← Newer
1
2
3
4
5
...
78
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
Results per page:
10
25
50
100
200