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
July
June
May
April
March
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
March 2016
----- 2025 -----
July 2025
June 2025
May 2025
April 2025
March 2025
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
722 discussions
Start a n
N
ew thread
Piotr Caban : msvcrt: Fix exception parameters number validation in x86_64 __CxxDetectRethrow.
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: 1a8015cb4d945dbb4495ea114f3a80abe8d32068 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1a8015cb4d945dbb4495ea114…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Mon Mar 21 18:23:06 2016 +0100 msvcrt: Fix exception parameters number validation in x86_64 __CxxDetectRethrow. Signed-off-by: Piotr Caban <piotr(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msvcrt/except_x86_64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/msvcrt/except_x86_64.c b/dlls/msvcrt/except_x86_64.c index 27d0a15..119680e 100644 --- a/dlls/msvcrt/except_x86_64.c +++ b/dlls/msvcrt/except_x86_64.c @@ -106,7 +106,7 @@ BOOL CDECL __CxxDetectRethrow(PEXCEPTION_POINTERS ptrs) rec = ptrs->ExceptionRecord; if (rec->ExceptionCode == CXX_EXCEPTION && - rec->NumberParameters == 3 && + rec->NumberParameters == 4 && rec->ExceptionInformation[0] == CXX_FRAME_MAGIC_VC6 && rec->ExceptionInformation[2]) {
1
0
0
0
Stefan Dösinger : wined3d: Avoid storing a transformation matrix pointer in struct wined3d_cs_set_transform.
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: 1422add1dfca731d7558fa6f9c1a5205952ab07f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1422add1dfca731d7558fa6f9…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Mon Mar 21 17:40:15 2016 +0100 wined3d: Avoid storing a transformation matrix pointer in struct wined3d_cs_set_transform. Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/cs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c index 6809aa2..e36429d 100644 --- a/dlls/wined3d/cs.c +++ b/dlls/wined3d/cs.c @@ -229,7 +229,7 @@ struct wined3d_cs_set_transform { enum wined3d_cs_op opcode; enum wined3d_transform_state state; - const struct wined3d_matrix *matrix; + struct wined3d_matrix matrix; }; struct wined3d_cs_set_clip_plane @@ -854,7 +854,7 @@ static void wined3d_cs_exec_set_transform(struct wined3d_cs *cs, const void *dat { const struct wined3d_cs_set_transform *op = data; - cs->state.transforms[op->state] = *op->matrix; + cs->state.transforms[op->state] = op->matrix; if (op->state < WINED3D_TS_WORLD_MATRIX(cs->device->adapter->d3d_info.limits.ffp_vertex_blend_matrices)) device_invalidate_state(cs->device, STATE_TRANSFORM(op->state)); } @@ -867,7 +867,7 @@ void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform op = cs->ops->require_space(cs, sizeof(*op)); op->opcode = WINED3D_CS_OP_SET_TRANSFORM; op->state = state; - op->matrix = matrix; + op->matrix = *matrix; cs->ops->submit(cs); }
1
0
0
0
Henri Verbeet : d3drm/tests: Properly initialise context.obj in test_Viewport().
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: d868f85ee8fcbf812906e484745df35a54b95eee URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d868f85ee8fcbf812906e4847…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Mon Mar 21 17:40:14 2016 +0100 d3drm/tests: Properly initialise context.obj in test_Viewport(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3drm/tests/d3drm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dlls/d3drm/tests/d3drm.c b/dlls/d3drm/tests/d3drm.c index 8a125fc..d973d88 100644 --- a/dlls/d3drm/tests/d3drm.c +++ b/dlls/d3drm/tests/d3drm.c @@ -1372,6 +1372,9 @@ static void test_Viewport(void) ok(hr == D3DRM_OK, "expected D3DRM_OK (hr = %x)\n", hr); context.called = 0; + hr = IDirect3DRMViewport_QueryInterface(viewport, &IID_IDirect3DRMObject, (void**)&context.obj); + ok(hr == D3DRM_OK, "expected D3DRM_OK (hr = %x)\n", hr); + IDirect3DRMObject_Release(context.obj); IDirect3DRMViewport_Release(viewport); ok(context.called == 2, "got %d, expected 2\n", context.called); @@ -1436,6 +1439,9 @@ static void test_Viewport(void) ok(hr == D3DRM_OK, "expected D3DRM_OK (hr = %x)\n", hr); context.called = 0; + hr = IDirect3DRMViewport2_QueryInterface(viewport2, &IID_IDirect3DRMObject, (void**)&context.obj); + ok(hr == D3DRM_OK, "expected D3DRM_OK (hr = %x)\n", hr); + IDirect3DRMObject_Release(context.obj); IDirect3DRMViewport2_Release(viewport2); ok(context.called == 2, "got %d, expected 2\n", context.called);
1
0
0
0
Henri Verbeet : wined3d: Merge surface_private_setup() into wined3d_surface_init().
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: 484c9ae45f32d8aef933b8e281025d014ebad008 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=484c9ae45f32d8aef933b8e28…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Mon Mar 21 17:40:13 2016 +0100 wined3d: Merge surface_private_setup() into wined3d_surface_init(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 60 ++++++++++++++++++++------------------------------ 1 file changed, 24 insertions(+), 36 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 7878ee0..c11d248 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -518,41 +518,6 @@ static void surface_evict_sysmem(struct wined3d_surface *surface) surface_invalidate_location(surface, WINED3D_LOCATION_SYSMEM); } -static void surface_private_setup(struct wined3d_surface *surface) -{ - /* TODO: Check against the maximum texture sizes supported by the video card. */ - struct wined3d_texture *texture = surface->container; - const struct wined3d_gl_info *gl_info = &texture->resource.device->adapter->gl_info; - unsigned int pow2Width, pow2Height; - - TRACE("surface %p.\n", surface); - - /* Non-power2 support */ - if (gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO] || gl_info->supported[WINED3D_GL_NORMALIZED_TEXRECT] - || gl_info->supported[ARB_TEXTURE_RECTANGLE]) - { - pow2Width = surface->resource.width; - pow2Height = surface->resource.height; - } - else - { - /* Find the nearest pow2 match */ - pow2Width = pow2Height = 1; - while (pow2Width < surface->resource.width) - pow2Width <<= 1; - while (pow2Height < surface->resource.height) - pow2Height <<= 1; - } - surface->pow2Width = pow2Width; - surface->pow2Height = pow2Height; - - if (texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) - surface->locations = WINED3D_LOCATION_DISCARDED; - - if (wined3d_texture_use_pbo(texture, gl_info)) - surface->resource.map_binding = WINED3D_LOCATION_BUFFER; -} - static BOOL surface_is_full_rect(const struct wined3d_surface *surface, const RECT *r) { if ((r->left && r->right) || abs(r->right - r->left) != surface->resource.width) @@ -4556,6 +4521,25 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex unsigned int resource_size; HRESULT hr; + if (container->flags & WINED3D_TEXTURE_COND_NP2_EMULATED) + { + unsigned int pow2_width = 1, pow2_height = 1; + + /* Find the nearest pow2 match. */ + while (pow2_width < desc->width) + pow2_width <<= 1; + while (pow2_height < desc->height) + pow2_height <<= 1; + + surface->pow2Width = pow2_width; + surface->pow2Height = pow2_height; + } + else + { + surface->pow2Width = desc->width; + surface->pow2Height = desc->height; + } + /* Quick lockable sanity check. * TODO: remove this after surfaces, usage and lockability have been debugged properly * this function is too deep to need to care about things like this. @@ -4614,7 +4598,11 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex surface->texture_level = level; surface->texture_layer = layer; - surface_private_setup(surface); + if (container->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) + surface->locations = WINED3D_LOCATION_DISCARDED; + + if (wined3d_texture_use_pbo(container, gl_info)) + surface->resource.map_binding = WINED3D_LOCATION_BUFFER; /* Similar to lockable rendertargets above, creating the DIB section * during surface initialization prevents the sysmem pointer from changing
1
0
0
0
Henri Verbeet : wined3d: Check for compressed and height scaled formats in texture_init().
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: 55b97245707e74196f999240bf06c77236a3c815 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=55b97245707e74196f999240b…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Mon Mar 21 17:40:12 2016 +0100 wined3d: Check for compressed and height scaled formats in texture_init(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 23 ++--------------------- dlls/wined3d/texture.c | 11 +++++++++++ 2 files changed, 13 insertions(+), 21 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 5842d52..7878ee0 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -518,7 +518,7 @@ static void surface_evict_sysmem(struct wined3d_surface *surface) surface_invalidate_location(surface, WINED3D_LOCATION_SYSMEM); } -static HRESULT surface_private_setup(struct wined3d_surface *surface) +static void surface_private_setup(struct wined3d_surface *surface) { /* TODO: Check against the maximum texture sizes supported by the video card. */ struct wined3d_texture *texture = surface->container; @@ -546,24 +546,11 @@ static HRESULT surface_private_setup(struct wined3d_surface *surface) surface->pow2Width = pow2Width; surface->pow2Height = pow2Height; - if (pow2Width > surface->resource.width || pow2Height > surface->resource.height) - { - /* TODO: Add support for non power two compressed textures. */ - if (texture->resource.format_flags & (WINED3DFMT_FLAG_COMPRESSED | WINED3DFMT_FLAG_HEIGHT_SCALE)) - { - FIXME("(%p) Compressed or height scaled non-power-two textures are not supported w(%d) h(%d)\n", - surface, surface->resource.width, surface->resource.height); - return WINED3DERR_NOTAVAILABLE; - } - } - if (texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) surface->locations = WINED3D_LOCATION_DISCARDED; if (wined3d_texture_use_pbo(texture, gl_info)) surface->resource.map_binding = WINED3D_LOCATION_BUFFER; - - return WINED3D_OK; } static BOOL surface_is_full_rect(const struct wined3d_surface *surface, const RECT *r) @@ -4627,13 +4614,7 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex surface->texture_level = level; surface->texture_layer = layer; - /* Call the private setup routine */ - if (FAILED(hr = surface_private_setup(surface))) - { - ERR("Private setup failed, hr %#x.\n", hr); - wined3d_surface_cleanup(surface); - return hr; - } + surface_private_setup(surface); /* Similar to lockable rendertargets above, creating the DIB section * during surface initialization prevents the sysmem pointer from changing diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 588066f..7e28681 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -1423,6 +1423,17 @@ static HRESULT texture_init(struct wined3d_texture *texture, const struct wined3 if (!gl_info->supported[ARB_TEXTURE_RECTANGLE] && !gl_info->supported[WINED3D_GL_NORMALIZED_TEXRECT]) { + const struct wined3d_format *format = wined3d_get_format(gl_info, desc->format); + + /* TODO: Add support for non-power-of-two compressed textures. */ + if (format->flags[WINED3D_GL_RES_TYPE_TEX_2D] + & (WINED3DFMT_FLAG_COMPRESSED | WINED3DFMT_FLAG_HEIGHT_SCALE)) + { + FIXME("Compressed or height scaled non-power-of-two (%ux%u) textures are not supported.\n", + desc->width, desc->height); + return WINED3DERR_NOTAVAILABLE; + } + /* Find the nearest pow2 match. */ pow2_width = pow2_height = 1; while (pow2_width < desc->width)
1
0
0
0
Henri Verbeet : wined3d: Validate (2D) texture dimensions in texture_init( ).
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: ab53ef06519d5e5a528fff54e6481ecf59576755 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ab53ef06519d5e5a528fff54e…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Mon Mar 21 17:40:11 2016 +0100 wined3d: Validate (2D) texture dimensions in texture_init(). Instead of for each surface individually. Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 24 ----------- dlls/wined3d/texture.c | 108 +++++++++++++++++++++++++++---------------------- 2 files changed, 59 insertions(+), 73 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 532f6f8..5842d52 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -557,30 +557,6 @@ static HRESULT surface_private_setup(struct wined3d_surface *surface) } } - if ((surface->pow2Width > gl_info->limits.texture_size || surface->pow2Height > gl_info->limits.texture_size) - && (texture->resource.usage & WINED3DUSAGE_TEXTURE)) - { - /* One of three options: - * 1: Do the same as we do with NPOT and scale the texture, (any - * texture ops would require the texture to be scaled which is - * potentially slow) - * 2: Set the texture to the maximum size (bad idea). - * 3: WARN and return WINED3DERR_NOTAVAILABLE; - * 4: Create the surface, but allow it to be used only for DirectDraw - * Blts. Some apps (e.g. Swat 3) create textures with a Height of - * 16 and a Width > 3000 and blt 16x16 letter areas from them to - * the render target. */ - if (texture->resource.pool == WINED3D_POOL_DEFAULT || texture->resource.pool == WINED3D_POOL_MANAGED) - { - WARN("Unable to allocate a surface which exceeds the maximum OpenGL texture size.\n"); - return WINED3DERR_NOTAVAILABLE; - } - - /* We should never use this surface in combination with OpenGL! */ - TRACE("Creating an oversized surface: %ux%u.\n", - surface->pow2Width, surface->pow2Height); - } - if (texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) surface->locations = WINED3D_LOCATION_DISCARDED; diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 4d2a94f..588066f 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -79,7 +79,7 @@ static HRESULT wined3d_texture_init(struct wined3d_texture *texture, const struc texture->level_count = level_count; texture->filter_type = (desc->usage & WINED3DUSAGE_AUTOGENMIPMAP) ? WINED3D_TEXF_LINEAR : WINED3D_TEXF_NONE; texture->lod = 0; - texture->flags = WINED3D_TEXTURE_POW2_MAT_IDENT | WINED3D_TEXTURE_NORMALIZED_COORDS; + texture->flags |= WINED3D_TEXTURE_POW2_MAT_IDENT | WINED3D_TEXTURE_NORMALIZED_COORDS; if (flags & WINED3D_TEXTURE_CREATE_PIN_SYSMEM) texture->flags |= WINED3D_TEXTURE_PIN_SYSMEM; @@ -1403,39 +1403,59 @@ static HRESULT texture_init(struct wined3d_texture *texture, const struct wined3 return WINED3DERR_INVALIDCALL; } - /* Non-power2 support. */ - if (gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO]) + pow2_width = desc->width; + pow2_height = desc->height; + if (((desc->width & (desc->width - 1)) || (desc->height & (desc->height - 1))) + && !gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO]) { - pow2_width = desc->width; - pow2_height = desc->height; - } - else - { - /* Find the nearest pow2 match. */ - pow2_width = pow2_height = 1; - while (pow2_width < desc->width) - pow2_width <<= 1; - while (pow2_height < desc->height) - pow2_height <<= 1; - - if (pow2_width != desc->width || pow2_height != desc->height) + /* level_count == 0 returns an error as well. */ + if (level_count != 1 || desc->usage & WINED3DUSAGE_LEGACY_CUBEMAP) { - /* level_count == 0 returns an error as well */ - if (level_count != 1 || desc->usage & WINED3DUSAGE_LEGACY_CUBEMAP) + if (desc->pool != WINED3D_POOL_SCRATCH) { - if (desc->pool == WINED3D_POOL_SCRATCH) - { - WARN("Creating a scratch mipmapped/cube NPOT texture despite lack of HW support.\n"); - } - else - { - WARN("Attempted to create a mipmapped/cube NPOT texture without unconditional NPOT support.\n"); - return WINED3DERR_INVALIDCALL; - } + WARN("Attempted to create a mipmapped/cube NPOT texture without unconditional NPOT support.\n"); + return WINED3DERR_INVALIDCALL; } + + WARN("Creating a scratch mipmapped/cube NPOT texture despite lack of HW support.\n"); + } + texture->flags |= WINED3D_TEXTURE_COND_NP2; + + if (!gl_info->supported[ARB_TEXTURE_RECTANGLE] && !gl_info->supported[WINED3D_GL_NORMALIZED_TEXRECT]) + { + /* Find the nearest pow2 match. */ + pow2_width = pow2_height = 1; + while (pow2_width < desc->width) + pow2_width <<= 1; + while (pow2_height < desc->height) + pow2_height <<= 1; + texture->flags |= WINED3D_TEXTURE_COND_NP2_EMULATED; } } + if ((pow2_width > gl_info->limits.texture_size || pow2_height > gl_info->limits.texture_size) + && (desc->usage & WINED3DUSAGE_TEXTURE)) + { + /* One of four options: + * 1: Do the same as we do with NPOT and scale the texture. (Any + * texture ops would require the texture to be scaled which is + * potentially slow.) + * 2: Set the texture to the maximum size (bad idea). + * 3: WARN and return WINED3DERR_NOTAVAILABLE. + * 4: Create the surface, but allow it to be used only for DirectDraw + * Blts. Some apps (e.g. Swat 3) create textures with a height of + * 16 and a width > 3000 and blt 16x16 letter areas from them to + * the render target. */ + if (desc->pool == WINED3D_POOL_DEFAULT || desc->pool == WINED3D_POOL_MANAGED) + { + WARN("Dimensions (%ux%u) exceed the maximum texture size.\n", pow2_width, pow2_height); + return WINED3DERR_NOTAVAILABLE; + } + + /* We should never use this surface in combination with OpenGL. */ + TRACE("Creating an oversized (%ux%u) surface.\n", pow2_width, pow2_height); + } + /* Calculate levels for mip mapping. */ if (desc->usage & WINED3DUSAGE_AUTOGENMIPMAP) { @@ -1464,40 +1484,30 @@ static HRESULT texture_init(struct wined3d_texture *texture, const struct wined3 { texture->pow2_matrix[0] = (float)desc->width; texture->pow2_matrix[5] = (float)desc->height; - texture->pow2_matrix[10] = 1.0f; - texture->pow2_matrix[15] = 1.0f; - texture->target = GL_TEXTURE_RECTANGLE_ARB; - texture->flags |= WINED3D_TEXTURE_COND_NP2; texture->flags &= ~(WINED3D_TEXTURE_POW2_MAT_IDENT | WINED3D_TEXTURE_NORMALIZED_COORDS); + texture->target = GL_TEXTURE_RECTANGLE_ARB; } else { - if (desc->usage & WINED3DUSAGE_LEGACY_CUBEMAP) - texture->target = GL_TEXTURE_CUBE_MAP_ARB; - else - texture->target = GL_TEXTURE_2D; - if (desc->width == pow2_width && desc->height == pow2_height) + if (texture->flags & WINED3D_TEXTURE_COND_NP2_EMULATED) { - texture->pow2_matrix[0] = 1.0f; - texture->pow2_matrix[5] = 1.0f; + texture->pow2_matrix[0] = (((float)desc->width) / ((float)pow2_width)); + texture->pow2_matrix[5] = (((float)desc->height) / ((float)pow2_height)); + texture->flags &= ~WINED3D_TEXTURE_POW2_MAT_IDENT; } - else if (gl_info->supported[WINED3D_GL_NORMALIZED_TEXRECT]) + else { texture->pow2_matrix[0] = 1.0f; texture->pow2_matrix[5] = 1.0f; - texture->flags |= WINED3D_TEXTURE_COND_NP2; } + if (desc->usage & WINED3DUSAGE_LEGACY_CUBEMAP) + texture->target = GL_TEXTURE_CUBE_MAP_ARB; else - { - texture->pow2_matrix[0] = (((float)desc->width) / ((float)pow2_width)); - texture->pow2_matrix[5] = (((float)desc->height) / ((float)pow2_height)); - texture->flags &= ~WINED3D_TEXTURE_POW2_MAT_IDENT; - texture->flags |= WINED3D_TEXTURE_COND_NP2_EMULATED; - } - texture->pow2_matrix[10] = 1.0f; - texture->pow2_matrix[15] = 1.0f; + texture->target = GL_TEXTURE_2D; } - TRACE("xf(%f) yf(%f)\n", texture->pow2_matrix[0], texture->pow2_matrix[5]); + texture->pow2_matrix[10] = 1.0f; + texture->pow2_matrix[15] = 1.0f; + TRACE("x scale %.8e, y scale %.8e.\n", texture->pow2_matrix[0], texture->pow2_matrix[5]); if (!(surfaces = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*surfaces) * level_count * layer_count))) {
1
0
0
0
Henri Verbeet : wined3d: Get rid of wined3d_surface_ops.surface_private_setup().
by Alexandre Julliard
22 Mar '16
22 Mar '16
Module: wine Branch: master Commit: 2d00f77f30b9b9bebf83d9ff0b68a91fb8f9e3ed URL:
http://source.winehq.org/git/wine.git/?a=commit;h=2d00f77f30b9b9bebf83d9ff0…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Mon Mar 21 17:40:10 2016 +0100 wined3d: Get rid of wined3d_surface_ops.surface_private_setup(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 62 ++++++------------------------------------ dlls/wined3d/wined3d_private.h | 6 ---- 2 files changed, 9 insertions(+), 59 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index c259c13..532f6f8 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -1068,51 +1068,6 @@ static const struct wined3d_resource_ops surface_resource_ops = surface_resource_sub_resource_unmap, }; -static const struct wined3d_surface_ops surface_ops = -{ - surface_private_setup, -}; - -/***************************************************************************** - * Initializes the GDI surface, aka creates the DIB section we render to - * The DIB section creation is done by calling GetDC, which will create the - * section and releasing the dc to allow the app to use it. The dib section - * will stay until the surface is released - * - * GDI surfaces do not need to be a power of 2 in size, so the pow2 sizes - * are set to the real sizes to save memory. The NONPOW2 flag is unset to - * avoid confusion in the shared surface code. - * - * Returns: - * WINED3D_OK on success - * The return values of called methods on failure - * - *****************************************************************************/ -static HRESULT gdi_surface_private_setup(struct wined3d_surface *surface) -{ - HRESULT hr; - - TRACE("surface %p.\n", surface); - - /* Sysmem textures have memory already allocated - release it, - * this avoids an unnecessary memcpy. */ - hr = surface_create_dib_section(surface); - if (FAILED(hr)) - return hr; - surface->resource.map_binding = WINED3D_LOCATION_DIB; - - /* We don't mind the nonpow2 stuff in GDI. */ - surface->pow2Width = surface->resource.width; - surface->pow2Height = surface->resource.height; - - return WINED3D_OK; -} - -static const struct wined3d_surface_ops gdi_surface_ops = -{ - gdi_surface_private_setup, -}; - /* This call just downloads data, the caller is responsible for binding the * correct texture. */ /* Context activation is done by the caller. */ @@ -4673,11 +4628,6 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex if (!resource_size) return WINED3DERR_INVALIDCALL; - if (device->wined3d->flags & WINED3D_NO3D) - surface->surface_ops = &gdi_surface_ops; - else - surface->surface_ops = &surface_ops; - if (FAILED(hr = resource_init(&surface->resource, device, WINED3D_RTYPE_SURFACE, format, desc->multisample_type, multisample_quality, desc->usage, desc->pool, desc->width, desc->height, 1, resource_size, NULL, &wined3d_null_parent_ops, &surface_resource_ops))) @@ -4702,7 +4652,7 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex surface->texture_layer = layer; /* Call the private setup routine */ - if (FAILED(hr = surface->surface_ops->surface_private_setup(surface))) + if (FAILED(hr = surface_private_setup(surface))) { ERR("Private setup failed, hr %#x.\n", hr); wined3d_surface_cleanup(surface); @@ -4712,9 +4662,15 @@ HRESULT wined3d_surface_init(struct wined3d_surface *surface, struct wined3d_tex /* Similar to lockable rendertargets above, creating the DIB section * during surface initialization prevents the sysmem pointer from changing * after a wined3d_texture_get_dc() call. */ - if ((desc->usage & WINED3DUSAGE_OWNDC) && !surface->hDC - && SUCCEEDED(surface_create_dib_section(surface))) + if ((desc->usage & WINED3DUSAGE_OWNDC) || (device->wined3d->flags & WINED3D_NO3D)) + { + if (FAILED(hr = surface_create_dib_section(surface))) + { + wined3d_surface_cleanup(surface); + return hr; + } surface->resource.map_binding = WINED3D_LOCATION_DIB; + } if (surface->resource.map_binding == WINED3D_LOCATION_DIB) { diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 3dea1e3..cbaa4b3 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2548,15 +2548,9 @@ struct fbo_entry } key; }; -struct wined3d_surface_ops -{ - HRESULT (*surface_private_setup)(struct wined3d_surface *surface); -}; - struct wined3d_surface { struct wined3d_resource resource; - const struct wined3d_surface_ops *surface_ops; struct wined3d_texture *container; DWORD locations;
1
0
0
0
Bruno Jesus : comctl32/tests: Add initial tests for the animation control.
by Alexandre Julliard
21 Mar '16
21 Mar '16
Module: wine Branch: master Commit: bc357819296594aca300fdf30bb0cda46e9f0be0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bc357819296594aca300fdf30…
Author: Bruno Jesus <00cpxxx(a)gmail.com> Date: Fri Mar 18 14:47:48 2016 +0530 comctl32/tests: Add initial tests for the animation control. Signed-off-by: Bruno Jesus <00cpxxx(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/comctl32/tests/Makefile.in | 1 + dlls/comctl32/tests/animate.c | 185 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 186 insertions(+) diff --git a/dlls/comctl32/tests/Makefile.in b/dlls/comctl32/tests/Makefile.in index 1a4ce23..cb2fdf3 100644 --- a/dlls/comctl32/tests/Makefile.in +++ b/dlls/comctl32/tests/Makefile.in @@ -2,6 +2,7 @@ TESTDLL = comctl32.dll IMPORTS = comctl32 ole32 user32 gdi32 advapi32 C_SRCS = \ + animate.c \ button.c \ comboex.c \ datetime.c \ diff --git a/dlls/comctl32/tests/animate.c b/dlls/comctl32/tests/animate.c new file mode 100644 index 0000000..b4218db --- /dev/null +++ b/dlls/comctl32/tests/animate.c @@ -0,0 +1,185 @@ +/* Unit tests for the animate control. + * + * Copyright 2016 Bruno Jesus + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include <stdarg.h> + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winuser.h" +#include "commctrl.h" + +#include "wine/test.h" + +#define SEARCHING_AVI_INDEX 151 /* From shell32 resource library */ +#define INVALID_AVI_INDEX 0xffff + +static HWND hAnimateParentWnd, hAnimateWnd; +static const char animateTestClass[] = "AnimateTestClass"; +static WNDPROC animate_wndproc; +static HANDLE shell32; + +/* try to make sure pending X events have been processed before continuing */ +static void flush_events(void) +{ + MSG msg; + int diff = 100; + DWORD time = GetTickCount() + diff; + + while (diff > 0) + { + if (MsgWaitForMultipleObjects( 0, NULL, FALSE, min(10,diff), QS_ALLINPUT ) == WAIT_TIMEOUT) break; + while (PeekMessageA( &msg, 0, 0, 0, PM_REMOVE )) DispatchMessageA( &msg ); + diff = time - GetTickCount(); + } +} + +static LRESULT CALLBACK animate_test_wnd_proc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + switch(msg) + { + case WM_DESTROY: + PostQuitMessage(0); + break; + + default: + return DefWindowProcA(hWnd, msg, wParam, lParam); + } + return 0L; +} + +static void update_window(HWND hWnd) +{ + UpdateWindow(hWnd); + ok(!GetUpdateRect(hWnd, NULL, FALSE), "GetUpdateRect must return zero after UpdateWindow\n"); +} + +static void create_animate(DWORD parent_style, DWORD animate_style) +{ + WNDCLASSA wc; + RECT rect; + BOOL ret; + + wc.style = CS_HREDRAW | CS_VREDRAW; + wc.cbClsExtra = 0; + wc.cbWndExtra = 0; + wc.hInstance = GetModuleHandleA(NULL); + wc.hIcon = NULL; + wc.hCursor = LoadCursorA(NULL, (LPCSTR)IDC_ARROW); + wc.hbrBackground = GetSysColorBrush(COLOR_WINDOW); + wc.lpszMenuName = NULL; + wc.lpszClassName = animateTestClass; + wc.lpfnWndProc = animate_test_wnd_proc; + RegisterClassA(&wc); + + rect.left = 0; + rect.top = 0; + rect.right = 200; + rect.bottom = 200; + ret = AdjustWindowRect(&rect, WS_OVERLAPPEDWINDOW, FALSE); + ok(ret, "got %d\n", ret); + + hAnimateParentWnd = CreateWindowExA(0, animateTestClass, "Animate Test", WS_OVERLAPPEDWINDOW | parent_style, + CW_USEDEFAULT, CW_USEDEFAULT, rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, GetModuleHandleA(NULL), 0); + ok(hAnimateParentWnd != NULL, "failed to create parent wnd\n"); + + GetClientRect(hAnimateParentWnd, &rect); + hAnimateWnd = CreateWindowExA(0, ANIMATE_CLASSA, NULL, WS_CHILD | WS_VISIBLE | animate_style, + 0, 0, rect.right, rect.bottom, hAnimateParentWnd, NULL, shell32, 0); + ok(hAnimateWnd != NULL, "failed to create parent wnd\n"); + animate_wndproc = (WNDPROC)SetWindowLongPtrA(hAnimateWnd, GWLP_WNDPROC, 0); + + ShowWindow(hAnimateParentWnd, SW_SHOWNORMAL); + ok(GetUpdateRect(hAnimateParentWnd, NULL, FALSE), "GetUpdateRect: There should be a region that needs to be updated\n"); + flush_events(); + update_window(hAnimateParentWnd); +} + +static void init(void) +{ + HMODULE hComctl32; + BOOL (WINAPI *pInitCommonControlsEx)(const INITCOMMONCONTROLSEX*); + + hComctl32 = GetModuleHandleA("comctl32.dll"); + pInitCommonControlsEx = (void*)GetProcAddress(hComctl32, "InitCommonControlsEx"); + if (pInitCommonControlsEx) + { + INITCOMMONCONTROLSEX iccex; + iccex.dwSize = sizeof(iccex); + iccex.dwICC = ICC_ANIMATE_CLASS; + pInitCommonControlsEx(&iccex); + } + else + InitCommonControls(); + + shell32 = LoadLibraryA("Shell32.dll"); +} + +static void destroy_animate(void) +{ + MSG msg; + + PostMessageA(hAnimateParentWnd, WM_CLOSE, 0, 0); + while (GetMessageA(&msg,0,0,0)) + { + TranslateMessage(&msg); + DispatchMessageA(&msg); + } + hAnimateParentWnd = NULL; +} + +static void cleanup(void) +{ + UnregisterClassA(animateTestClass, GetModuleHandleA(NULL)); +} + +static void test_play(void) +{ + LONG res; + DWORD err; + + create_animate(0, 0); + SetLastError(0xdeadbeef); + res = SendMessageA(hAnimateWnd, ACM_OPENA,(WPARAM)shell32, MAKEINTRESOURCE(INVALID_AVI_INDEX)); + err = GetLastError(); + ok(res == 0, "Invalid video should have failed\n"); + ok(err == ERROR_RESOURCE_NAME_NOT_FOUND, "Expected 1814, got %u\n", err); + + SetLastError(0xdeadbeef); + res = SendMessageA(hAnimateWnd, ACM_PLAY, (WPARAM) -1, MAKELONG(0, -1)); + ok(res == 0, "Play should have failed\n"); + ok(err == ERROR_RESOURCE_NAME_NOT_FOUND, "Expected 1814, got %u\n", err); + destroy_animate(); + + create_animate(0, 0); + res = SendMessageA(hAnimateWnd, ACM_OPENA,(WPARAM)shell32, MAKEINTRESOURCE(SEARCHING_AVI_INDEX)); + ok(res != 0, "Load AVI resource failed\n"); + res = SendMessageA(hAnimateWnd, ACM_PLAY, (WPARAM) -1, MAKELONG(0, -1)); + ok(res != 0, "Play should have worked\n"); + destroy_animate(); +} + +START_TEST(animate) +{ + init(); + + test_play(); + + cleanup(); +}
1
0
0
0
Detlef Riekenberg : kernelbase: Add dll with forwards to kernel32.dll.
by Alexandre Julliard
21 Mar '16
21 Mar '16
Module: wine Branch: master Commit: 30686975a9ba7dee86bdeb18740d706909a3d509 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=30686975a9ba7dee86bdeb187…
Author: Detlef Riekenberg <wine.dev(a)web.de> Date: Fri Mar 18 00:01:57 2016 +0100 kernelbase: Add dll with forwards to kernel32.dll. Signed-off-by: Detlef Riekenberg <wine.dev(a)web.de> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- configure | 2 + configure.ac | 1 + dlls/kernelbase/Makefile.in | 1 + dlls/kernelbase/kernelbase.spec | 631 ++++++++++++++++++++++++++++++++++++++++ tools/make_specfiles | 1 + 5 files changed, 636 insertions(+) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=30686975a9ba7dee86bde…
1
0
0
0
Theodore Dubois : shell32/tests: Additional tests for IQueryAssociations.
by Alexandre Julliard
21 Mar '16
21 Mar '16
Module: wine Branch: master Commit: 9e05c66c03cfa6df33fea0c13b944684bca9999f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=9e05c66c03cfa6df33fea0c13…
Author: Theodore Dubois <tblodt(a)icloud.com> Date: Wed Mar 16 13:19:51 2016 -0700 shell32/tests: Additional tests for IQueryAssociations. Signed-off-by: Theodore Dubois <tblodt(a)icloud.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/tests/assoc.c | 65 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) diff --git a/dlls/shell32/tests/assoc.c b/dlls/shell32/tests/assoc.c index 8aa2535..0077f1e 100644 --- a/dlls/shell32/tests/assoc.c +++ b/dlls/shell32/tests/assoc.c @@ -100,14 +100,79 @@ static struct assoc_getstring_test getstring_tests[] = { NULL } }; +static void getstring_test(LPCWSTR assocName, HKEY progIdKey, ASSOCSTR str, LPCWSTR expected_string, int line_num) +{ + IQueryAssociations *assoc; + HRESULT hr; + WCHAR *buffer; + DWORD len; + + hr = CoCreateInstance(&CLSID_QueryAssociations, NULL, CLSCTX_INPROC_SERVER, &IID_IQueryAssociations, (void*)&assoc); + ok(hr == S_OK, "line %d: failed to create IQueryAssociations, 0x%x\n", line_num, hr); + hr = IQueryAssociations_Init(assoc, 0, assocName, progIdKey, NULL); + ok(hr == S_OK, "line %d: IQueryAssociations::Init failed, 0x%x\n", line_num, hr); + + hr = IQueryAssociations_GetString(assoc, 0, str, NULL, NULL, &len); + if (hr != S_FALSE) { + if (expected_string) { + ok(SUCCEEDED(hr), "line %d: GetString returned 0x%x, expected success\n", line_num, hr); + } else { + ok(FAILED(hr), "line %d: GetString returned 0x%x, expected failure\n", line_num, hr); + } + } + + buffer = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + ok(buffer != NULL, "line %d: out of memory\n", line_num); + hr = IQueryAssociations_GetString(assoc, 0, str, NULL, buffer, &len); + + if (expected_string) { + ok(lstrcmpW(buffer, expected_string) == 0, "line %d: GetString returned %s, expected %s\n", line_num, + wine_dbgstr_w(buffer), wine_dbgstr_w(expected_string)); + } +} + static void test_IQueryAssociations_GetString(void) { + static WCHAR test_extensionW[] = {'.','t','e','s','t',0}; + static WCHAR test_progidW[] = {'t','e','s','t','f','i','l','e',0}; + static WCHAR DefaultIconW[] = {'D','e','f','a','u','l','t','I','c','o','n',0}; + /* folder.ico, why not */ + static WCHAR test_iconW[] = {'s','h','e','l','l','3','2','.','d','l','l',',','1',0}; + HKEY test_extension_key; + HKEY test_progid_key; + HKEY test_defaulticon_key; + LRESULT r; + struct assoc_getstring_test *ptr = getstring_tests; IQueryAssociations *assoc; HRESULT hr; DWORD len; int i = 0; + r = RegCreateKeyExW(HKEY_CLASSES_ROOT, test_extensionW, 0, NULL, 0, KEY_ALL_ACCESS, NULL, &test_extension_key, NULL); + ok(r == ERROR_SUCCESS, "RegCreateKeyExW(HKCR, \".test\") failed: 0x%lx\n", r); + r = RegSetValueExW(test_extension_key, NULL, 0, REG_SZ, (PBYTE)test_progidW, sizeof(test_progidW)); + ok(r == ERROR_SUCCESS, "RegSetValueExW(HKCR\\.test, NULL, \"testfile\") failed: 0x%lx\n", r); + + /* adding progid key with no information shuld fail to return information */ + r = RegCreateKeyExW(HKEY_CLASSES_ROOT, test_progidW, 0, NULL, 0, KEY_ALL_ACCESS, NULL, &test_progid_key, NULL); + ok(r == ERROR_SUCCESS, "RegCreateKeyExW(HKCR, \"testfile\") failed: 0x%lx\n", r); + getstring_test(test_extensionW, NULL, ASSOCSTR_DEFAULTICON, NULL, __LINE__); + getstring_test(test_progidW, NULL, ASSOCSTR_DEFAULTICON, NULL, __LINE__); + getstring_test(NULL, test_progid_key, ASSOCSTR_DEFAULTICON, NULL, __LINE__); + + /* adding information to the progid should return that information */ + r = RegCreateKeyExW(test_progid_key, DefaultIconW, 0, NULL, 0, KEY_ALL_ACCESS, NULL, &test_defaulticon_key, NULL); + ok(r == ERROR_SUCCESS, "RegCreateKeyExW(HKCR\\testfile\\DefaultIcon) failed: 0x%lx\n", r); + r = RegSetValueExW(test_defaulticon_key, NULL, 0, REG_SZ, (PBYTE)test_iconW, sizeof(test_iconW)); + ok(r == ERROR_SUCCESS, "RegSetValueExW(HKCR\\testfile\\DefaultIcon, NULL, \"folder.ico\") failed: 0x%lx\n", r); + getstring_test(test_extensionW, NULL, ASSOCSTR_DEFAULTICON, test_iconW, __LINE__); + getstring_test(test_progidW, NULL, ASSOCSTR_DEFAULTICON, test_iconW, __LINE__); + getstring_test(NULL, test_progid_key, ASSOCSTR_DEFAULTICON, test_iconW, __LINE__); + + RegDeleteKeyW(HKEY_CLASSES_ROOT, test_extensionW); + RegDeleteKeyW(HKEY_CLASSES_ROOT, test_progidW); + hr = CoCreateInstance(&CLSID_QueryAssociations, NULL, CLSCTX_INPROC_SERVER, &IID_IQueryAssociations, (void*)&assoc); ok(hr == S_OK, "failed to create object, 0x%x\n", hr);
1
0
0
0
← Newer
1
...
26
27
28
29
30
31
32
...
73
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
Results per page:
10
25
50
100
200