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
October 2022
----- 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
537 discussions
Start a n
N
ew thread
Nikolay Sivov : dxva2/tests: Add another render target format to fix a test failure.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: 3adf638c610cad80a1e9758f990bb6c889b6c357 URL:
https://gitlab.winehq.org/wine/wine/-/commit/3adf638c610cad80a1e9758f990bb6…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Fri Oct 14 22:04:13 2022 +0300 dxva2/tests: Add another render target format to fix a test failure. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> --- dlls/dxva2/tests/dxva2.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/dxva2/tests/dxva2.c b/dlls/dxva2/tests/dxva2.c index cc5bc3cd76f..db48f331772 100644 --- a/dlls/dxva2/tests/dxva2.c +++ b/dlls/dxva2/tests/dxva2.c @@ -580,11 +580,12 @@ static void test_progressive_device(void) MAKEFOURCC('N','V','1','2'), }; - static const D3DFORMAT support_rt_formats[] = + static const D3DFORMAT supported_rt_formats[] = { D3DFMT_X8R8G8B8, MAKEFOURCC('N','V','1','2'), D3DFMT_YUY2, + D3DFMT_A2R10G10B10, }; window = create_window(); @@ -647,7 +648,7 @@ static void test_progressive_device(void) ok(count > 0, "Unexpected format count %u.\n", count); for (j = 0; j < count; ++j) { - ok(check_format_list(rt_formats[j], support_rt_formats, ARRAY_SIZE(support_rt_formats)), + ok(check_format_list(rt_formats[j], supported_rt_formats, ARRAY_SIZE(supported_rt_formats)), "Unexpected rt format %#x for input format %#x.\n", rt_formats[j], input_formats[i]); } CoTaskMemFree(rt_formats);
1
0
0
0
Huw Davies : nsi: Update struct nsi_tcp_conn_dynamic for Windows 11.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: fad925d582801a662bbbb01a4e57d5640a324960 URL:
https://gitlab.winehq.org/wine/wine/-/commit/fad925d582801a662bbbb01a4e57d5…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Oct 14 10:09:29 2022 -0500 nsi: Update struct nsi_tcp_conn_dynamic for Windows 11. --- dlls/nsi/tests/nsi.c | 3 ++- include/wine/nsi.h | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/nsi/tests/nsi.c b/dlls/nsi/tests/nsi.c index b6dd8f2416d..4cf49993ea1 100644 --- a/dlls/nsi/tests/nsi.c +++ b/dlls/nsi/tests/nsi.c @@ -842,7 +842,8 @@ static void test_tcp_stats( int family ) static void test_tcp_tables( int family, int table_type ) { - DWORD dyn_sizes[] = { FIELD_OFFSET(struct nsi_tcp_conn_dynamic, unk[2]), sizeof(struct nsi_tcp_conn_dynamic) }; + DWORD dyn_sizes[] = { FIELD_OFFSET(struct nsi_tcp_conn_dynamic, unk[2]), FIELD_OFFSET(struct nsi_tcp_conn_dynamic, unk[3]), + sizeof(struct nsi_tcp_conn_dynamic) }; DWORD i, err, count, table_num, dyn_size, size; struct nsi_tcp_conn_key *keys; struct nsi_tcp_conn_dynamic *dyn_tbl, *dyn; diff --git a/include/wine/nsi.h b/include/wine/nsi.h index 0e20490e2a8..af35593b29c 100644 --- a/include/wine/nsi.h +++ b/include/wine/nsi.h @@ -334,7 +334,7 @@ struct nsi_tcp_conn_key struct nsi_tcp_conn_dynamic { UINT state; - UINT unk[3]; + UINT unk[4]; }; struct nsi_tcp_conn_static
1
0
0
0
Rémi Bernon : winegstreamer: Implement AAC decoder MFT.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: a21e7c46d0b418a69c2a24033ee43300c41f7447 URL:
https://gitlab.winehq.org/wine/wine/-/commit/a21e7c46d0b418a69c2a24033ee433…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Fri Aug 12 09:52:53 2022 +0200 winegstreamer: Implement AAC decoder MFT. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=47084
--- dlls/mf/tests/transform.c | 9 +- dlls/winegstreamer/aac_decoder.c | 418 ++++++++++++++++++++++++++++++++++++--- 2 files changed, 395 insertions(+), 32 deletions(-)
1
0
0
0
Rémi Bernon : winegstreamer: Support MPEG4 (AAC) compressed audio format.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: 4199bb7fab8e2e2eb0bea844733787f517e693d7 URL:
https://gitlab.winehq.org/wine/wine/-/commit/4199bb7fab8e2e2eb0bea844733787…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Mon Sep 26 12:45:14 2022 +0200 winegstreamer: Support MPEG4 (AAC) compressed audio format. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=47084
--- dlls/winegstreamer/mfplat.c | 48 ++++++++++++++++++++++++++++++++++++++ dlls/winegstreamer/quartz_parser.c | 2 ++ dlls/winegstreamer/unixlib.h | 7 ++++++ dlls/winegstreamer/wg_format.c | 34 +++++++++++++++++++++++++++ dlls/winegstreamer/wg_transform.c | 2 ++ dlls/winegstreamer/wm_reader.c | 4 ++++ 6 files changed, 97 insertions(+) diff --git a/dlls/winegstreamer/mfplat.c b/dlls/winegstreamer/mfplat.c index 9e6a43a3414..d7d6810965e 100644 --- a/dlls/winegstreamer/mfplat.c +++ b/dlls/winegstreamer/mfplat.c @@ -550,6 +550,7 @@ IMFMediaType *mf_media_type_from_wg_format(const struct wg_format *format) switch (format->major_type) { case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_CINEPAK: case WG_MAJOR_TYPE_VIDEO_H264: @@ -618,6 +619,51 @@ static void mf_media_type_to_wg_format_audio(IMFMediaType *type, const GUID *sub FIXME("Unrecognized audio subtype %s, depth %u.\n", debugstr_guid(subtype), depth); } +static void mf_media_type_to_wg_format_audio_mpeg4(IMFMediaType *type, struct wg_format *format) +{ + /* Audio specific config is stored at after HEAACWAVEINFO in MF_MT_USER_DATA + *
https://docs.microsoft.com/en-us/windows/win32/api/mmreg/ns-mmreg-heaacwave…
+ */ + typedef struct + { + WORD wPayloadType; + WORD wAudioProfileLevelIndication; + WORD wStructType; + WORD wReserved1; + DWORD dwReserved2; + } HEAACWAVEINFO; + typedef struct + { + HEAACWAVEINFO wfInfo; + BYTE pbAudioSpecificConfig[1]; + } HEAACWAVEFORMAT; + + BYTE buffer[64]; + HEAACWAVEFORMAT *user_data = (HEAACWAVEFORMAT *)buffer; + UINT32 codec_data_size; + + if (FAILED(IMFMediaType_GetBlob(type, &MF_MT_USER_DATA, buffer, sizeof(buffer), &codec_data_size))) + { + FIXME("Codec data is not set.\n"); + return; + } + + codec_data_size -= min(codec_data_size, offsetof(HEAACWAVEFORMAT, pbAudioSpecificConfig)); + if (codec_data_size > sizeof(format->u.audio_mpeg4.codec_data)) + { + FIXME("Codec data needs %u bytes.\n", codec_data_size); + return; + } + + format->major_type = WG_MAJOR_TYPE_AUDIO_MPEG4; + + if (FAILED(IMFMediaType_GetUINT32(type, &MF_MT_AAC_PAYLOAD_TYPE, &format->u.audio_mpeg4.payload_type))) + format->u.audio_mpeg4.payload_type = -1; + + format->u.audio_mpeg4.codec_data_len = codec_data_size; + memcpy(format->u.audio_mpeg4.codec_data, user_data->pbAudioSpecificConfig, codec_data_size); +} + static void mf_media_type_to_wg_format_video(IMFMediaType *type, const GUID *subtype, struct wg_format *format) { UINT64 frame_rate, frame_size; @@ -781,6 +827,8 @@ void mf_media_type_to_wg_format(IMFMediaType *type, struct wg_format *format) IsEqualGUID(&subtype, &MFAudioFormat_WMAudioV9) || IsEqualGUID(&subtype, &MFAudioFormat_WMAudio_Lossless)) mf_media_type_to_wg_format_audio_wma(type, &subtype, format); + else if (IsEqualGUID(&subtype, &MFAudioFormat_AAC)) + mf_media_type_to_wg_format_audio_mpeg4(type, format); else mf_media_type_to_wg_format_audio(type, &subtype, format); } diff --git a/dlls/winegstreamer/quartz_parser.c b/dlls/winegstreamer/quartz_parser.c index 55e5988e880..9369b529642 100644 --- a/dlls/winegstreamer/quartz_parser.c +++ b/dlls/winegstreamer/quartz_parser.c @@ -359,6 +359,7 @@ unsigned int wg_format_get_max_size(const struct wg_format *format) } break; + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_H264: FIXME("Format %u not implemented!\n", format->major_type); @@ -528,6 +529,7 @@ bool amt_from_wg_format(AM_MEDIA_TYPE *mt, const struct wg_format *format, bool switch (format->major_type) { + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_H264: FIXME("Format %u not implemented!\n", format->major_type); diff --git a/dlls/winegstreamer/unixlib.h b/dlls/winegstreamer/unixlib.h index 8e6c5e4cc0e..9c53ecbfbc3 100644 --- a/dlls/winegstreamer/unixlib.h +++ b/dlls/winegstreamer/unixlib.h @@ -37,6 +37,7 @@ struct wg_format WG_MAJOR_TYPE_UNKNOWN = 0, WG_MAJOR_TYPE_AUDIO, WG_MAJOR_TYPE_AUDIO_MPEG1, + WG_MAJOR_TYPE_AUDIO_MPEG4, WG_MAJOR_TYPE_AUDIO_WMA, WG_MAJOR_TYPE_VIDEO, WG_MAJOR_TYPE_VIDEO_CINEPAK, @@ -70,6 +71,12 @@ struct wg_format uint32_t channels; } audio_mpeg1; struct + { + uint32_t payload_type; + uint32_t codec_data_len; + unsigned char codec_data[64]; + } audio_mpeg4; + struct { uint32_t version; uint32_t bitrate; diff --git a/dlls/winegstreamer/wg_format.c b/dlls/winegstreamer/wg_format.c index b67c820dd71..7f28b4d2c90 100644 --- a/dlls/winegstreamer/wg_format.c +++ b/dlls/winegstreamer/wg_format.c @@ -346,6 +346,37 @@ static GstCaps *wg_format_to_caps_audio_mpeg1(const struct wg_format *format) return caps; } +static GstCaps *wg_format_to_caps_audio_mpeg4(const struct wg_format *format) +{ + GstBuffer *buffer; + GstCaps *caps; + + if (!(caps = gst_caps_new_empty_simple("audio/mpeg"))) + return NULL; + + gst_caps_set_simple(caps, "mpegversion", G_TYPE_INT, 4, NULL); + + switch (format->u.audio_mpeg4.payload_type) + { + case 0: gst_caps_set_simple(caps, "stream-format", G_TYPE_STRING, "raw", NULL); break; + case 1: gst_caps_set_simple(caps, "stream-format", G_TYPE_STRING, "adts", NULL); break; + case 2: gst_caps_set_simple(caps, "stream-format", G_TYPE_STRING, "adif", NULL); break; + case 3: gst_caps_set_simple(caps, "stream-format", G_TYPE_STRING, "loas", NULL); break; + } + + /* FIXME: Use gst_codec_utils_aac_caps_set_level_and_profile from GStreamer pbutils library */ + + if (format->u.audio_mpeg4.codec_data_len) + { + buffer = gst_buffer_new_and_alloc(format->u.audio_mpeg4.codec_data_len); + gst_buffer_fill(buffer, 0, format->u.audio_mpeg4.codec_data, format->u.audio_mpeg4.codec_data_len); + gst_caps_set_simple(caps, "codec_data", GST_TYPE_BUFFER, buffer, NULL); + gst_buffer_unref(buffer); + } + + return caps; +} + static GstCaps *wg_format_to_caps_audio(const struct wg_format *format) { GstAudioChannelPosition positions[32]; @@ -533,6 +564,8 @@ GstCaps *wg_format_to_caps(const struct wg_format *format) return wg_format_to_caps_audio(format); case WG_MAJOR_TYPE_AUDIO_MPEG1: return wg_format_to_caps_audio_mpeg1(format); + case WG_MAJOR_TYPE_AUDIO_MPEG4: + return wg_format_to_caps_audio_mpeg4(format); case WG_MAJOR_TYPE_AUDIO_WMA: return wg_format_to_caps_audio_wma(format); case WG_MAJOR_TYPE_VIDEO: @@ -554,6 +587,7 @@ bool wg_format_compare(const struct wg_format *a, const struct wg_format *b) switch (a->major_type) { case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_H264: GST_FIXME("Format %u not implemented!", a->major_type); diff --git a/dlls/winegstreamer/wg_transform.c b/dlls/winegstreamer/wg_transform.c index 486562fdff6..34b8d25c2e5 100644 --- a/dlls/winegstreamer/wg_transform.c +++ b/dlls/winegstreamer/wg_transform.c @@ -424,6 +424,7 @@ NTSTATUS wg_transform_create(void *args) goto out; /* fallthrough */ case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_CINEPAK: if (!(element = transform_find_element(GST_ELEMENT_FACTORY_TYPE_DECODER, src_caps, raw_caps)) @@ -474,6 +475,7 @@ NTSTATUS wg_transform_create(void *args) break; case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_CINEPAK: case WG_MAJOR_TYPE_VIDEO_H264: diff --git a/dlls/winegstreamer/wm_reader.c b/dlls/winegstreamer/wm_reader.c index e68e0a7d0ca..55d98671931 100644 --- a/dlls/winegstreamer/wm_reader.c +++ b/dlls/winegstreamer/wm_reader.c @@ -1555,6 +1555,8 @@ static const char *get_major_type_string(enum wg_major_type type) return "audio"; case WG_MAJOR_TYPE_AUDIO_MPEG1: return "mpeg1-audio"; + case WG_MAJOR_TYPE_AUDIO_MPEG4: + return "mpeg4-audio"; case WG_MAJOR_TYPE_AUDIO_WMA: return "wma"; case WG_MAJOR_TYPE_VIDEO: @@ -1971,6 +1973,7 @@ static HRESULT WINAPI reader_GetOutputFormat(IWMSyncReader2 *iface, break; case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_CINEPAK: case WG_MAJOR_TYPE_VIDEO_H264: @@ -2010,6 +2013,7 @@ static HRESULT WINAPI reader_GetOutputFormatCount(IWMSyncReader2 *iface, DWORD o break; case WG_MAJOR_TYPE_AUDIO_MPEG1: + case WG_MAJOR_TYPE_AUDIO_MPEG4: case WG_MAJOR_TYPE_AUDIO_WMA: case WG_MAJOR_TYPE_VIDEO_CINEPAK: case WG_MAJOR_TYPE_VIDEO_H264:
1
0
0
0
Henri Verbeet : wined3d: Use the supplied context in wined3d_device_context_blt().
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: b3b2a5599454d2e8373819271a883981f09ef73c URL:
https://gitlab.winehq.org/wine/wine/-/commit/b3b2a5599454d2e8373819271a8839…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Oct 12 14:55:39 2022 +0200 wined3d: Use the supplied context in wined3d_device_context_blt(). Applications calling wined3d_device_context_resolve_sub_resource() on a deferred context would instead get this scheduled on the immediate context. Worse, because the original call was intended for a deferred context, we'd do this without taking the mutex required for immediate contexts, potentially corrupting the command stream. --- dlls/wined3d/texture.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index c76a50ea6ae..f385394497b 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -4168,8 +4168,8 @@ HRESULT CDECL wined3d_device_context_blt(struct wined3d_device_context *context, return E_NOTIMPL; } - wined3d_device_context_emit_blt_sub_resource(&dst_texture->resource.device->cs->c, &dst_texture->resource, - dst_sub_resource_idx, &dst_box, &src_texture->resource, src_sub_resource_idx, &src_box, flags, fx, filter); + wined3d_device_context_emit_blt_sub_resource(context, &dst_texture->resource, dst_sub_resource_idx, + &dst_box, &src_texture->resource, src_sub_resource_idx, &src_box, flags, fx, filter); if (dst_texture->dirty_regions) wined3d_texture_add_dirty_region(dst_texture, dst_sub_resource_idx, &dst_box);
1
0
0
0
Henri Verbeet : wined3d: Handle VKD3D_SHADER_RESOURCE_DATA_MIXED in wined3d_data_type_from_vkd3d().
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: 00187d64f07e02c438f6a8fcdf4df76ecd2a699a URL:
https://gitlab.winehq.org/wine/wine/-/commit/00187d64f07e02c438f6a8fcdf4df7…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Oct 12 14:55:39 2022 +0200 wined3d: Handle VKD3D_SHADER_RESOURCE_DATA_MIXED in wined3d_data_type_from_vkd3d(). --- dlls/wined3d/shader_spirv.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/dlls/wined3d/shader_spirv.c b/dlls/wined3d/shader_spirv.c index 42be7541d67..fe1cc03e9f4 100644 --- a/dlls/wined3d/shader_spirv.c +++ b/dlls/wined3d/shader_spirv.c @@ -25,6 +25,11 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d_shader); static const struct wined3d_shader_backend_ops spirv_shader_backend_vk; +static const struct vkd3d_shader_compile_option spirv_compile_options[] = +{ + {VKD3D_SHADER_COMPILE_OPTION_API_VERSION, VKD3D_SHADER_API_VERSION_1_3}, +}; + struct shader_spirv_resource_bindings { struct vkd3d_shader_resource_binding *bindings; @@ -266,8 +271,8 @@ static VkShaderModule shader_spirv_compile_shader(struct wined3d_context_vk *con info.source.size = shader_desc->byte_code_size; info.source_type = VKD3D_SHADER_SOURCE_DXBC_TPF; info.target_type = VKD3D_SHADER_TARGET_SPIRV_BINARY; - info.options = NULL; - info.option_count = 0; + info.options = spirv_compile_options; + info.option_count = ARRAY_SIZE(spirv_compile_options); info.log_level = VKD3D_SHADER_LOG_WARNING; info.source_name = NULL; @@ -596,6 +601,8 @@ static enum wined3d_data_type wined3d_data_type_from_vkd3d(enum vkd3d_shader_res return WINED3D_DATA_UINT; case VKD3D_SHADER_RESOURCE_DATA_FLOAT: return WINED3D_DATA_FLOAT; + case VKD3D_SHADER_RESOURCE_DATA_MIXED: + return WINED3D_DATA_UINT; default: FIXME("Unhandled resource data type %#x.\n", t); return WINED3D_DATA_FLOAT; @@ -703,8 +710,8 @@ static void shader_spirv_scan_shader(struct wined3d_shader *shader, info.source.size = shader->byte_code_size; info.source_type = VKD3D_SHADER_SOURCE_DXBC_TPF; info.target_type = VKD3D_SHADER_TARGET_SPIRV_BINARY; - info.options = NULL; - info.option_count = 0; + info.options = spirv_compile_options; + info.option_count = ARRAY_SIZE(spirv_compile_options); info.log_level = VKD3D_SHADER_LOG_WARNING; info.source_name = NULL;
1
0
0
0
Piotr Caban : comctl32: Don't cast HPROPSHEETPAGE to PROPSHEETPAGEW*.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: d75deeec384fe7c5a163ffba1118c422210b83db URL:
https://gitlab.winehq.org/wine/wine/-/commit/d75deeec384fe7c5a163ffba1118c4…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Wed Aug 31 19:53:39 2022 +0200 comctl32: Don't cast HPROPSHEETPAGE to PROPSHEETPAGEW*. --- dlls/comctl32/propsheet.c | 45 +++++++++++++++++++-------------------------- 1 file changed, 19 insertions(+), 26 deletions(-) diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index 0791e4896fa..b0a011b2c55 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -281,10 +281,8 @@ static INT PROPSHEET_FindPageByResId(const PropSheetInfo * psInfo, LRESULT resId for (i = 0; i < psInfo->nPages; i++) { - LPCPROPSHEETPAGEA lppsp = (LPCPROPSHEETPAGEA)psInfo->proppage[i].hpage; - /* Fixme: if resource ID is a string shall we use strcmp ??? */ - if (lppsp->u.pszTemplate == (LPVOID)resId) + if (psInfo->proppage[i].hpage->psp.u.pszTemplate == (LPVOID)resId) break; } @@ -1514,7 +1512,6 @@ static BOOL PROPSHEET_ShowPage(HWND hwndDlg, int index, PropSheetInfo * psInfo) HWND hwndTabCtrl; HWND hwndLineHeader; HWND control; - LPCPROPSHEETPAGEW ppshpage; TRACE("active_page %d, index %d\n", psInfo->active_page, index); if (index == psInfo->active_page) @@ -1555,9 +1552,9 @@ static BOOL PROPSHEET_ShowPage(HWND hwndDlg, int index, PropSheetInfo * psInfo) if (psInfo->ppshheader.dwFlags & (PSH_WIZARD97_OLD | PSH_WIZARD97_NEW) ) { hwndLineHeader = GetDlgItem(hwndDlg, IDC_SUNKEN_LINEHEADER); - ppshpage = (LPCPROPSHEETPAGEW)psInfo->proppage[index].hpage; - if ((ppshpage->dwFlags & PSP_HIDEHEADER) || (!(psInfo->ppshheader.dwFlags & PSH_HEADER)) ) + if ((psInfo->proppage[index].hpage->psp.dwFlags & PSP_HIDEHEADER) || + (!(psInfo->ppshheader.dwFlags & PSH_HEADER)) ) ShowWindow(hwndLineHeader, SW_HIDE); else ShowWindow(hwndLineHeader, SW_SHOW); @@ -2399,9 +2396,9 @@ static BOOL PROPSHEET_RemovePage(HWND hwndDlg, psInfo->active_page--; /* Unsubclass the page dialog window */ - if((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD) && + if((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD)) && (psInfo->ppshheader.dwFlags & PSH_WATERMARK) && - ((PROPSHEETPAGEW*)psInfo->proppage[index].hpage)->dwFlags & PSP_HIDEHEADER)) + (psInfo->proppage[index].hpage->psp.dwFlags & PSP_HIDEHEADER)) { RemoveWindowSubclass(psInfo->proppage[index].hwndPage, PROPSHEET_WizardSubclassProc, 1); @@ -2413,9 +2410,7 @@ static BOOL PROPSHEET_RemovePage(HWND hwndDlg, /* Free page resources */ if(psInfo->proppage[index].hpage) { - PROPSHEETPAGEW* psp = (PROPSHEETPAGEW*)psInfo->proppage[index].hpage; - - if (psp->dwFlags & PSP_USETITLE) + if (psInfo->proppage[index].hpage->psp.dwFlags & PSP_USETITLE) Free ((LPVOID)psInfo->proppage[index].pszText); DestroyPropertySheetPage(psInfo->proppage[index].hpage); @@ -2505,7 +2500,7 @@ static void PROPSHEET_SetHeaderTitleW(HWND hwndDlg, UINT page_index, const WCHAR if (page_index >= psInfo->nPages) return; - page = (PROPSHEETPAGEW *)psInfo->proppage[page_index].hpage; + page = &psInfo->proppage[page_index].hpage->psp; if (!IS_INTRESOURCE(page->pszHeaderTitle)) Free((void *)page->pszHeaderTitle); @@ -2541,7 +2536,7 @@ static void PROPSHEET_SetHeaderSubTitleW(HWND hwndDlg, UINT page_index, const WC if (page_index >= psInfo->nPages) return; - page = (PROPSHEETPAGEW *)psInfo->proppage[page_index].hpage; + page = &psInfo->proppage[page_index].hpage->psp; if (!IS_INTRESOURCE(page->pszHeaderSubTitle)) Free((void *)page->pszHeaderSubTitle); @@ -2629,12 +2624,10 @@ static LRESULT PROPSHEET_IndexToPage(HWND hwndDlg, int iPageIndex) static LRESULT PROPSHEET_IdToIndex(HWND hwndDlg, int iPageId) { int index; - LPCPROPSHEETPAGEW psp; PropSheetInfo * psInfo = GetPropW(hwndDlg, PropSheetInfoStr); TRACE("(%p, %d)\n", hwndDlg, iPageId); for (index = 0; index < psInfo->nPages; index++) { - psp = (LPCPROPSHEETPAGEW)psInfo->proppage[index].hpage; - if (psp->u.pszTemplate == MAKEINTRESOURCEW(iPageId)) + if (psInfo->proppage[index].hpage->psp.u.pszTemplate == MAKEINTRESOURCEW(iPageId)) return index; } @@ -2653,7 +2646,7 @@ static LRESULT PROPSHEET_IndexToId(HWND hwndDlg, int iPageIndex) WARN("%d out of range.\n", iPageIndex); return 0; } - psp = (LPCPROPSHEETPAGEW)psInfo->proppage[iPageIndex].hpage; + psp = &psInfo->proppage[iPageIndex].hpage->psp; if (psp->dwFlags & PSP_DLGINDIRECT || !IS_INTRESOURCE(psp->u.pszTemplate)) { return 0; } @@ -2713,7 +2706,7 @@ static void PROPSHEET_CleanUp(HWND hwndDlg) for (i = 0; i < psInfo->nPages; i++) { - PROPSHEETPAGEA* psp = (PROPSHEETPAGEA*)psInfo->proppage[i].hpage; + PROPSHEETPAGEW* psp = &psInfo->proppage[i].hpage->psp; /* Unsubclass the page dialog window */ if((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD)) && @@ -3100,28 +3093,28 @@ HPROPSHEETPAGE WINAPI CreatePropertySheetPageW(LPCPROPSHEETPAGEW lpPropSheetPage */ BOOL WINAPI DestroyPropertySheetPage(HPROPSHEETPAGE hPropPage) { - PROPSHEETPAGEW *psp = (PROPSHEETPAGEW *)hPropPage; + PROPSHEETPAGEW *psp = &hPropPage->psp; if (!hPropPage) return FALSE; if ((psp->dwFlags & PSP_USECALLBACK) && psp->pfnCallback) - psp->pfnCallback(0, PSPCB_RELEASE, psp + 1); + psp->pfnCallback(0, PSPCB_RELEASE, &hPropPage->callback_psp); if (!(psp->dwFlags & PSP_DLGINDIRECT) && !IS_INTRESOURCE( psp->u.pszTemplate )) - Free ((LPVOID)psp->u.pszTemplate); + Free((void*)psp->u.pszTemplate); if ((psp->dwFlags & PSP_USEICONID) && !IS_INTRESOURCE( psp->u2.pszIcon )) - Free ((LPVOID)psp->u2.pszIcon); + Free((void*)psp->u2.pszIcon); if ((psp->dwFlags & PSP_USETITLE) && !IS_INTRESOURCE( psp->pszTitle )) - Free ((LPVOID)psp->pszTitle); + Free((void*)psp->pszTitle); if ((psp->dwFlags & PSP_USEHEADERTITLE) && !IS_INTRESOURCE( psp->pszHeaderTitle )) - Free ((LPVOID)psp->pszHeaderTitle); + Free((void*)psp->pszHeaderTitle); if ((psp->dwFlags & PSP_USEHEADERSUBTITLE) && !IS_INTRESOURCE( psp->pszHeaderSubTitle )) - Free ((LPVOID)psp->pszHeaderSubTitle); + Free((void*)psp->pszHeaderSubTitle); Free(hPropPage); @@ -3272,7 +3265,7 @@ static LRESULT PROPSHEET_Paint(HWND hwnd, HDC hdcParam) if (psInfo->active_page < 0) ppshpage = NULL; else - ppshpage = (LPCPROPSHEETPAGEW)psInfo->proppage[psInfo->active_page].hpage; + ppshpage = &psInfo->proppage[psInfo->active_page].hpage->psp; if ( (ppshpage && !(ppshpage->dwFlags & PSP_HIDEHEADER)) && (psInfo->ppshheader.dwFlags & (PSH_WIZARD97_OLD | PSH_WIZARD97_NEW)) &&
1
0
0
0
Piotr Caban : comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_GetPageRect.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: fd6c1d597c9bdb799f2352e69b6f15f60cc04830 URL:
https://gitlab.winehq.org/wine/wine/-/commit/fd6c1d597c9bdb799f2352e69b6f15…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Wed Aug 31 19:26:25 2022 +0200 comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_GetPageRect. --- dlls/comctl32/propsheet.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index 5ca19102f61..0791e4896fa 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -232,7 +232,7 @@ static VOID PROPSHEET_UnImplementedFlags(DWORD dwFlags) * Retrieve rect from tab control and map into the dialog for SetWindowPos */ static void PROPSHEET_GetPageRect(const PropSheetInfo * psInfo, HWND hwndDlg, - RECT *rc, LPCPROPSHEETPAGEW ppshpage) + RECT *rc, HPROPSHEETPAGE hpsp) { if (psInfo->ppshheader.dwFlags & INTRNL_ANY_WIZARD) { HWND hwndChild; @@ -240,7 +240,7 @@ static void PROPSHEET_GetPageRect(const PropSheetInfo * psInfo, HWND hwndDlg, if (((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD)) && (psInfo->ppshheader.dwFlags & PSH_HEADER) && - !(ppshpage->dwFlags & PSP_HIDEHEADER)) || + !(hpsp->psp.dwFlags & PSP_HIDEHEADER)) || (psInfo->ppshheader.dwFlags & PSH_WIZARD)) { rc->left = rc->top = WIZARD_PADDING; @@ -255,7 +255,7 @@ static void PROPSHEET_GetPageRect(const PropSheetInfo * psInfo, HWND hwndDlg, if ((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD)) && (psInfo->ppshheader.dwFlags & PSH_HEADER) && - !(ppshpage->dwFlags & PSP_HIDEHEADER)) + !(hpsp->psp.dwFlags & PSP_HIDEHEADER)) { hwndChild = GetDlgItem(hwndDlg, IDC_SUNKEN_LINEHEADER); GetClientRect(hwndChild, &r); @@ -1996,7 +1996,6 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg, int result; PSHNOTIFY psn; RECT rc; - LPCPROPSHEETPAGEW ppshpage = (LPCPROPSHEETPAGEW)psInfo->proppage[index].hpage; if (hwndTabControl) SendMessageW(hwndTabControl, TCM_SETCURSEL, index, 0); @@ -2029,7 +2028,7 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg, * wizards). * NOTE: The resizing happens every time the page is selected and * not only when it's created (some applications depend on it). */ - PROPSHEET_GetPageRect(psInfo, hwndDlg, &rc, ppshpage); + PROPSHEET_GetPageRect(psInfo, hwndDlg, &rc, psInfo->proppage[index].hpage); TRACE("setting page %p, rc (%s) w=%ld, h=%ld\n", psInfo->proppage[index].hwndPage, wine_dbgstr_rect(&rc), rc.right - rc.left, rc.bottom - rc.top);
1
0
0
0
Piotr Caban : comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_CreatePage.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: aefd67ff608bff33bbcc2c4cfc9d190952196ce7 URL:
https://gitlab.winehq.org/wine/wine/-/commit/aefd67ff608bff33bbcc2c4cfc9d19…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Wed Aug 31 19:24:04 2022 +0200 comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_CreatePage. --- dlls/comctl32/propsheet.c | 55 ++++++++++++++++++++++------------------------- 1 file changed, 26 insertions(+), 29 deletions(-) diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index e32ac063ea4..5ca19102f61 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -1341,7 +1341,7 @@ static UINT GetTemplateSize(const DLGTEMPLATE* pTemplate) static BOOL PROPSHEET_CreatePage(HWND hwndParent, int index, const PropSheetInfo * psInfo, - LPCPROPSHEETPAGEW ppshpage) + HPROPSHEETPAGE hpsp) { const DLGTEMPLATE* pTemplate; HWND hwndPage; @@ -1350,30 +1350,30 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent, TRACE("index %d\n", index); - if (ppshpage == NULL) + if (hpsp == NULL) { return FALSE; } - if (ppshpage->dwFlags & PSP_DLGINDIRECT) + if (hpsp->psp.dwFlags & PSP_DLGINDIRECT) { - pTemplate = ppshpage->u.pResource; + pTemplate = hpsp->psp.u.pResource; resSize = GetTemplateSize(pTemplate); } - else if(ppshpage->dwFlags & PSP_INTERNAL_UNICODE) + else if(hpsp->psp.dwFlags & PSP_INTERNAL_UNICODE) { HRSRC hResource; HANDLE hTemplate; - hResource = FindResourceW(ppshpage->hInstance, - ppshpage->u.pszTemplate, + hResource = FindResourceW(hpsp->psp.hInstance, + hpsp->psp.u.pszTemplate, (LPWSTR)RT_DIALOG); if(!hResource) return FALSE; - resSize = SizeofResource(ppshpage->hInstance, hResource); + resSize = SizeofResource(hpsp->psp.hInstance, hResource); - hTemplate = LoadResource(ppshpage->hInstance, hResource); + hTemplate = LoadResource(hpsp->psp.hInstance, hResource); if(!hTemplate) return FALSE; @@ -1387,15 +1387,15 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent, HRSRC hResource; HANDLE hTemplate; - hResource = FindResourceA(ppshpage->hInstance, - (LPCSTR)ppshpage->u.pszTemplate, + hResource = FindResourceA(hpsp->psp.hInstance, + (LPCSTR)hpsp->psp.u.pszTemplate, (LPSTR)RT_DIALOG); if(!hResource) return FALSE; - resSize = SizeofResource(ppshpage->hInstance, hResource); + resSize = SizeofResource(hpsp->psp.hInstance, hResource); - hTemplate = LoadResource(ppshpage->hInstance, hResource); + hTemplate = LoadResource(hpsp->psp.hInstance, hResource); if(!hTemplate) return FALSE; @@ -1439,21 +1439,20 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent, } if (psInfo->proppage[index].useCallback) - (*(ppshpage->pfnCallback))(0, PSPCB_CREATE, - (LPPROPSHEETPAGEW)ppshpage); + (*(hpsp->psp.pfnCallback))(0, PSPCB_CREATE, &hpsp->psp); - if(ppshpage->dwFlags & PSP_INTERNAL_UNICODE) - hwndPage = CreateDialogIndirectParamW(ppshpage->hInstance, + if(hpsp->psp.dwFlags & PSP_INTERNAL_UNICODE) + hwndPage = CreateDialogIndirectParamW(hpsp->psp.hInstance, pTemplateCopy, hwndParent, - ppshpage->pfnDlgProc, - (LPARAM)ppshpage); + hpsp->psp.pfnDlgProc, + (LPARAM)&hpsp->psp); else - hwndPage = CreateDialogIndirectParamA(ppshpage->hInstance, + hwndPage = CreateDialogIndirectParamA(hpsp->psp.hInstance, pTemplateCopy, hwndParent, - ppshpage->pfnDlgProc, - (LPARAM)ppshpage); + hpsp->psp.pfnDlgProc, + (LPARAM)&hpsp->psp); /* Free a no more needed copy */ Free(pTemplateCopy); @@ -1465,7 +1464,7 @@ static BOOL PROPSHEET_CreatePage(HWND hwndParent, /* Subclass exterior wizard pages */ if((psInfo->ppshheader.dwFlags & (PSH_WIZARD97_NEW | PSH_WIZARD97_OLD)) && (psInfo->ppshheader.dwFlags & PSH_WATERMARK) && - (ppshpage->dwFlags & PSP_HIDEHEADER)) + (hpsp->psp.dwFlags & PSP_HIDEHEADER)) { SetWindowSubclass(hwndPage, PROPSHEET_WizardSubclassProc, 1, 0); } @@ -1525,10 +1524,9 @@ static BOOL PROPSHEET_ShowPage(HWND hwndDlg, int index, PropSheetInfo * psInfo) return TRUE; } - ppshpage = (LPCPROPSHEETPAGEW)psInfo->proppage[index].hpage; if (psInfo->proppage[index].hwndPage == 0) { - PROPSHEET_CreatePage(hwndDlg, index, psInfo, ppshpage); + PROPSHEET_CreatePage(hwndDlg, index, psInfo, psInfo->proppage[index].hpage); } if (psInfo->ppshheader.dwFlags & INTRNL_ANY_WIZARD) @@ -2009,7 +2007,7 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg, psn.lParam = 0; if (!psInfo->proppage[index].hwndPage) { - if(!PROPSHEET_CreatePage(hwndDlg, index, psInfo, ppshpage)) { + if(!PROPSHEET_CreatePage(hwndDlg, index, psInfo, psInfo->proppage[index].hpage)) { PROPSHEET_RemovePage(hwndDlg, index, NULL); if (!psInfo->isModeless) @@ -2247,7 +2245,6 @@ static BOOL PROPSHEET_InsertPage(HWND hwndDlg, HPROPSHEETPAGE hpageInsertAfter, PropSheetInfo *psInfo = GetPropW(hwndDlg, PropSheetInfoStr); PropPageInfo *ppi, *prev_ppi = psInfo->proppage; HWND hwndTabControl = GetDlgItem(hwndDlg, IDC_TABCONTROL); - LPCPROPSHEETPAGEW ppsp = (LPCPROPSHEETPAGEW)hpage; TCITEMW item; int index; @@ -2292,10 +2289,10 @@ static BOOL PROPSHEET_InsertPage(HWND hwndDlg, HPROPSHEETPAGE hpageInsertAfter, psInfo->proppage[index].hpage = hpage; - if (ppsp->dwFlags & PSP_PREMATURE) + if (hpage->psp.dwFlags & PSP_PREMATURE) { /* Create the page but don't show it */ - if (!PROPSHEET_CreatePage(hwndDlg, index, psInfo, ppsp)) + if (!PROPSHEET_CreatePage(hwndDlg, index, psInfo, hpage)) { psInfo->proppage = prev_ppi; Free(ppi);
1
0
0
0
Piotr Caban : comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_CollectPageInfo.
by Alexandre Julliard
14 Oct '22
14 Oct '22
Module: wine Branch: master Commit: c7b5108c02bcb9973203f49fe4cd4d492b5d78c7 URL:
https://gitlab.winehq.org/wine/wine/-/commit/c7b5108c02bcb9973203f49fe4cd4d…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Wed Aug 31 19:16:55 2022 +0200 comctl32: Use HPROPSHEETPAGE directly in PROPSHEET_CollectPageInfo. --- dlls/comctl32/propsheet.c | 44 +++++++++++++++++++++----------------------- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index bdd99c51dde..e32ac063ea4 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -400,7 +400,7 @@ static void PROPSHEET_CollectSheetInfoW(LPCPROPSHEETHEADERW lppsh, * Collect property sheet data. * With code taken from DIALOG_ParseTemplate32. */ -static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, +static BOOL PROPSHEET_CollectPageInfo(HPROPSHEETPAGE hpsp, PropSheetInfo * psInfo, int index, BOOL resize) { @@ -409,19 +409,19 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, DWORD dwFlags; int width, height; - if (!lppsp) + if (!hpsp) return FALSE; TRACE("\n"); - psInfo->proppage[index].hpage = (HPROPSHEETPAGE)lppsp; + psInfo->proppage[index].hpage = hpsp; psInfo->proppage[index].hwndPage = 0; psInfo->proppage[index].isDirty = FALSE; /* * Process property page flags. */ - dwFlags = lppsp->dwFlags; - psInfo->proppage[index].useCallback = (dwFlags & PSP_USECALLBACK) && (lppsp->pfnCallback); + dwFlags = hpsp->psp.dwFlags; + psInfo->proppage[index].useCallback = (dwFlags & PSP_USECALLBACK) && (hpsp->psp.pfnCallback); psInfo->proppage[index].hasHelp = dwFlags & PSP_HASHELP; psInfo->proppage[index].hasIcon = dwFlags & (PSP_USEHICON | PSP_USEICONID); @@ -433,22 +433,22 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, * Process page template. */ if (dwFlags & PSP_DLGINDIRECT) - pTemplate = lppsp->u.pResource; + pTemplate = hpsp->psp.u.pResource; else if(dwFlags & PSP_INTERNAL_UNICODE ) { - HRSRC hResource = FindResourceW(lppsp->hInstance, - lppsp->u.pszTemplate, + HRSRC hResource = FindResourceW(hpsp->psp.hInstance, + hpsp->psp.u.pszTemplate, (LPWSTR)RT_DIALOG); - HGLOBAL hTemplate = LoadResource(lppsp->hInstance, + HGLOBAL hTemplate = LoadResource(hpsp->psp.hInstance, hResource); pTemplate = LockResource(hTemplate); } else { - HRSRC hResource = FindResourceA(lppsp->hInstance, - (LPCSTR)lppsp->u.pszTemplate, + HRSRC hResource = FindResourceA(hpsp->psp.hInstance, + (LPCSTR)hpsp->psp.u.pszTemplate, (LPSTR)RT_DIALOG); - HGLOBAL hTemplate = LoadResource(lppsp->hInstance, + HGLOBAL hTemplate = LoadResource(hpsp->psp.hInstance, hResource); pTemplate = LockResource(hTemplate); } @@ -485,7 +485,7 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, width = (WORD)*p; p++; height = (WORD)*p; p++; - if (lppsp->dwFlags & (PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE)) + if (hpsp->psp.dwFlags & (PSP_USEHEADERTITLE | PSP_USEHEADERSUBTITLE)) psInfo->ppshheader.dwFlags |= PSH_HEADER; /* Special calculation for interior wizard pages so the largest page is @@ -552,9 +552,9 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, WCHAR szTitle[256]; const WCHAR *pTitle; - if (IS_INTRESOURCE( lppsp->pszTitle )) + if (IS_INTRESOURCE( hpsp->psp.pszTitle )) { - if (LoadStringW( lppsp->hInstance, (DWORD_PTR)lppsp->pszTitle, szTitle, ARRAY_SIZE(szTitle))) + if (LoadStringW( hpsp->psp.hInstance, (DWORD_PTR)hpsp->psp.pszTitle, szTitle, ARRAY_SIZE(szTitle))) pTitle = szTitle; else if (*p) pTitle = p; @@ -562,7 +562,7 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, pTitle = L"(null)"; } else - pTitle = lppsp->pszTitle; + pTitle = hpsp->psp.pszTitle; psInfo->proppage[index].pszText = heap_strdupW( pTitle ); } @@ -577,10 +577,10 @@ static BOOL PROPSHEET_CollectPageInfo(LPCPROPSHEETPAGEW lppsp, int icon_cy = GetSystemMetrics(SM_CYSMICON); if (dwFlags & PSP_USEICONID) - hIcon = LoadImageW(lppsp->hInstance, lppsp->u2.pszIcon, IMAGE_ICON, + hIcon = LoadImageW(hpsp->psp.hInstance, hpsp->psp.u2.pszIcon, IMAGE_ICON, icon_cx, icon_cy, LR_DEFAULTCOLOR); else - hIcon = lppsp->u2.hIcon; + hIcon = hpsp->psp.u2.hIcon; if ( hIcon ) { @@ -2283,7 +2283,7 @@ static BOOL PROPSHEET_InsertPage(HWND hwndDlg, HPROPSHEETPAGE hpageInsertAfter, memcpy(&ppi[index + 1], &prev_ppi[index], (psInfo->nPages - index) * sizeof(PropPageInfo)); psInfo->proppage = ppi; - if (!PROPSHEET_CollectPageInfo(ppsp, psInfo, index, FALSE)) + if (!PROPSHEET_CollectPageInfo(hpage, psInfo, index, FALSE)) { psInfo->proppage = prev_ppi; Free(ppi); @@ -2851,8 +2851,7 @@ INT_PTR WINAPI PropertySheetA(LPCPROPSHEETHEADERA lppsh) pByte += ((LPCPROPSHEETPAGEA)pByte)->dwSize; } - if (!PROPSHEET_CollectPageInfo((LPCPROPSHEETPAGEW)psInfo->proppage[n].hpage, - psInfo, n, TRUE)) + if (!PROPSHEET_CollectPageInfo(psInfo->proppage[n].hpage, psInfo, n, TRUE)) { if (psInfo->usePropPage) DestroyPropertySheetPage(psInfo->proppage[n].hpage); @@ -2892,8 +2891,7 @@ INT_PTR WINAPI PropertySheetW(LPCPROPSHEETHEADERW lppsh) pByte += ((LPCPROPSHEETPAGEW)pByte)->dwSize; } - if (!PROPSHEET_CollectPageInfo((LPCPROPSHEETPAGEW)psInfo->proppage[n].hpage, - psInfo, n, TRUE)) + if (!PROPSHEET_CollectPageInfo(psInfo->proppage[n].hpage, psInfo, n, TRUE)) { if (psInfo->usePropPage) DestroyPropertySheetPage(psInfo->proppage[n].hpage);
1
0
0
0
← Newer
1
...
35
36
37
38
39
40
41
...
54
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
Results per page:
10
25
50
100
200