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
February 2018
----- 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
804 discussions
Start a n
N
ew thread
Michael Müller : dwmapi: Add DwmSetIconicThumbnail() stub.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: e6723be683b1435323f1ede30c6a7f7729b825d9 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e6723be683b1435323f1ede3…
Author: Michael Müller <michael(a)fds-team.de> Date: Wed Feb 28 09:41:10 2018 +0300 dwmapi: Add DwmSetIconicThumbnail() stub. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwmapi/dwmapi.spec | 2 +- dlls/dwmapi/dwmapi_main.c | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/dlls/dwmapi/dwmapi.spec b/dlls/dwmapi/dwmapi.spec index d81df3d..697cefc 100644 --- a/dlls/dwmapi/dwmapi.spec +++ b/dlls/dwmapi/dwmapi.spec @@ -81,7 +81,7 @@ # @ stub DwmRenderGesture @ stub DwmSetDxFrameDuration @ stub DwmSetIconicLivePreviewBitmap -@ stub DwmSetIconicThumbnail +@ stdcall DwmSetIconicThumbnail(long long long) @ stdcall DwmSetPresentParameters(ptr ptr) @ stdcall DwmSetWindowAttribute(long long ptr long) # @ stub DwmShowContact diff --git a/dlls/dwmapi/dwmapi_main.c b/dlls/dwmapi/dwmapi_main.c index 8c3472a..7ac0b2b 100644 --- a/dlls/dwmapi/dwmapi_main.c +++ b/dlls/dwmapi/dwmapi_main.c @@ -268,3 +268,12 @@ HRESULT WINAPI DwmSetPresentParameters(HWND hwnd, DWM_PRESENT_PARAMETERS *params FIXME("(%p %p) stub\n", hwnd, params); return S_OK; }; + +/********************************************************************** + * DwmSetIconicThumbnail (DWMAPI.@) + */ +HRESULT WINAPI DwmSetIconicThumbnail(HWND hwnd, HBITMAP hbmp, DWORD flags) +{ + FIXME("(%p %p %x) stub\n", hwnd, hbmp, flags); + return S_OK; +};
1
0
0
0
Henri Verbeet : wined3d: Explicitly calculate the sub-resource level in fb_copy_to_texture_direct( ).
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: c8120f526ed16e60b972a5d4c2bbd5b21c131981 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c8120f526ed16e60b972a5d4…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Feb 28 10:14:58 2018 +0330 wined3d: Explicitly calculate the sub-resource level in fb_copy_to_texture_direct(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 36ecfaf..12370ed 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -1607,12 +1607,12 @@ static void fb_copy_to_texture_direct(struct wined3d_surface *dst_surface, struc struct wined3d_texture *src_texture = src_surface->container; struct wined3d_texture *dst_texture = dst_surface->container; struct wined3d_device *device = dst_texture->resource.device; + unsigned int src_height, src_level, dst_level; const struct wined3d_gl_info *gl_info; float xrel, yrel; struct wined3d_context *context; BOOL upsidedown = FALSE; RECT dst_rect = *dst_rect_in; - unsigned int src_height; GLenum dst_target; /* Make sure that the top pixel is always above the bottom pixel, and keep a separate upside down flag @@ -1660,14 +1660,17 @@ static void fb_copy_to_texture_direct(struct wined3d_surface *dst_surface, struc ERR("Texture filtering not supported in direct blit\n"); } - src_height = wined3d_texture_get_level_height(src_texture, src_surface->texture_level); + src_level = src_sub_resource_idx % src_texture->level_count; + dst_level = dst_sub_resource_idx % dst_texture->level_count; + + src_height = wined3d_texture_get_level_height(src_texture, src_level); dst_target = wined3d_texture_get_sub_resource_target(dst_texture, dst_sub_resource_idx); if (upsidedown && !((xrel - 1.0f < -eps) || (xrel - 1.0f > eps)) && !((yrel - 1.0f < -eps) || (yrel - 1.0f > eps))) { /* Upside down copy without stretching is nice, one glCopyTexSubImage call will do. */ - gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_surface->texture_level, + gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_level, dst_rect.left /*xoffset */, dst_rect.top /* y offset */, src_rect->left, src_height - src_rect->bottom, dst_rect.right - dst_rect.left, dst_rect.bottom - dst_rect.top); @@ -1692,14 +1695,14 @@ static void fb_copy_to_texture_direct(struct wined3d_surface *dst_surface, struc for (col = dst_rect.left; col < dst_rect.right; ++col) { - gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_surface->texture_level, + gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_level, dst_rect.left + col /* x offset */, row /* y offset */, src_rect->left + col * xrel, yoffset - (int) (row * yrel), 1, 1); } } else { - gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_surface->texture_level, + gl_info->gl_ops.gl.p_glCopyTexSubImage2D(dst_target, dst_level, dst_rect.left /* x offset */, row /* y offset */, src_rect->left, yoffset - (int) (row * yrel), dst_rect.right - dst_rect.left, 1); }
1
0
0
0
Henri Verbeet : wined3d: Explicitly calculate the sub-resource level in surface_load_fb_texture().
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 8e7540b602beb658cb10aa576811cc404beac1a2 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=8e7540b602beb658cb10aa57…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Feb 28 10:14:57 2018 +0330 wined3d: Explicitly calculate the sub-resource level in surface_load_fb_texture(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 751424d..36ecfaf 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -1563,6 +1563,7 @@ void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct const struct wined3d_gl_info *gl_info; struct wined3d_context *context = old_ctx; struct wined3d_surface *restore_rt = NULL; + unsigned int level; GLenum target; restore_rt = context_get_rt_surface(old_ctx); @@ -1585,10 +1586,11 @@ void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct gl_info->gl_ops.gl.p_glReadBuffer(wined3d_texture_get_gl_buffer(texture)); checkGLcall("glReadBuffer"); + level = sub_resource_idx % texture->level_count; target = wined3d_texture_get_sub_resource_target(texture, sub_resource_idx); - gl_info->gl_ops.gl.p_glCopyTexSubImage2D(target, surface->texture_level, - 0, 0, 0, 0, wined3d_texture_get_level_width(texture, surface->texture_level), - wined3d_texture_get_level_height(texture, surface->texture_level)); + gl_info->gl_ops.gl.p_glCopyTexSubImage2D(target, level, 0, 0, 0, 0, + wined3d_texture_get_level_width(texture, level), + wined3d_texture_get_level_height(texture, level)); checkGLcall("glCopyTexSubImage2D"); if (restore_rt)
1
0
0
0
Henri Verbeet : wined3d: Explicitly calculate the sub-resource level in read_from_framebuffer().
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 64ba3ee4a065a9032b797312ad9e8a0081830578 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=64ba3ee4a065a9032b797312…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Feb 28 10:14:56 2018 +0330 wined3d: Explicitly calculate the sub-resource level in read_from_framebuffer(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 22156b6..751424d 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -1433,8 +1433,8 @@ static void read_from_framebuffer(struct wined3d_surface *surface, struct wined3d_surface *restore_rt = NULL; const struct wined3d_gl_info *gl_info; unsigned int row_pitch, slice_pitch; + unsigned int width, height, level; struct wined3d_bo_address data; - unsigned int width, height; BYTE *row, *top, *bottom; BOOL src_is_upside_down; unsigned int i; @@ -1488,14 +1488,15 @@ static void read_from_framebuffer(struct wined3d_surface *surface, checkGLcall("glBindBuffer"); } - wined3d_texture_get_pitch(texture, surface->texture_level, &row_pitch, &slice_pitch); + level = sub_resource_idx % texture->level_count; + wined3d_texture_get_pitch(texture, level, &row_pitch, &slice_pitch); /* Setup pixel store pack state -- to glReadPixels into the correct place */ gl_info->gl_ops.gl.p_glPixelStorei(GL_PACK_ROW_LENGTH, row_pitch / texture->resource.format->byte_count); checkGLcall("glPixelStorei"); - width = wined3d_texture_get_level_width(texture, surface->texture_level); - height = wined3d_texture_get_level_height(texture, surface->texture_level); + width = wined3d_texture_get_level_width(texture, level); + height = wined3d_texture_get_level_height(texture, level); gl_info->gl_ops.gl.p_glReadPixels(0, 0, width, height, texture->resource.format->glFormat, texture->resource.format->glType, data.addr);
1
0
0
0
Henri Verbeet : wined3d: Explicitly calculate the sub-resource level in surface_set_compatible_renderbuffer ().
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 1cdff1c8a4bb4a547fdc10020b5f9385f3ef533e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1cdff1c8a4bb4a547fdc1002…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Wed Feb 28 10:14:55 2018 +0330 wined3d: Explicitly calculate the sub-resource level in surface_set_compatible_renderbuffer(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index ada7193..22156b6 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -981,36 +981,42 @@ static HRESULT surface_upload_from_surface(struct wined3d_surface *dst_surface, /* Context activation is done by the caller. */ void surface_set_compatible_renderbuffer(struct wined3d_surface *surface, const struct wined3d_rendertarget_info *rt) { - const struct wined3d_gl_info *gl_info = &surface->container->resource.device->adapter->gl_info; + unsigned int sub_resource_idx, width, height, level; struct wined3d_renderbuffer_entry *entry; + const struct wined3d_texture *texture; + const struct wined3d_gl_info *gl_info; unsigned int src_width, src_height; - unsigned int width, height; GLuint renderbuffer = 0; + texture = surface->container; + gl_info = &texture->resource.device->adapter->gl_info; + sub_resource_idx = surface_get_sub_resource_idx(surface); + level = sub_resource_idx % texture->level_count; + if (rt && rt->resource->format->id != WINED3DFMT_NULL) { - struct wined3d_texture *texture; - unsigned int level; + struct wined3d_texture *rt_texture; + unsigned int rt_level; if (rt->resource->type == WINED3D_RTYPE_BUFFER) { FIXME("Unsupported resource type %s.\n", debug_d3dresourcetype(rt->resource->type)); return; } - texture = wined3d_texture_from_resource(rt->resource); - level = rt->sub_resource_idx % texture->level_count; + rt_texture = wined3d_texture_from_resource(rt->resource); + rt_level = rt->sub_resource_idx % rt_texture->level_count; - width = wined3d_texture_get_level_pow2_width(texture, level); - height = wined3d_texture_get_level_pow2_height(texture, level); + width = wined3d_texture_get_level_pow2_width(rt_texture, rt_level); + height = wined3d_texture_get_level_pow2_height(rt_texture, rt_level); } else { - width = wined3d_texture_get_level_pow2_width(surface->container, surface->texture_level); - height = wined3d_texture_get_level_pow2_height(surface->container, surface->texture_level); + width = wined3d_texture_get_level_pow2_width(texture, level); + height = wined3d_texture_get_level_pow2_height(texture, level); } - src_width = wined3d_texture_get_level_pow2_width(surface->container, surface->texture_level); - src_height = wined3d_texture_get_level_pow2_height(surface->container, surface->texture_level); + src_width = wined3d_texture_get_level_pow2_width(texture, level); + src_height = wined3d_texture_get_level_pow2_height(texture, level); /* A depth stencil smaller than the render target is not valid */ if (width > src_width || height > src_height) return; @@ -1039,7 +1045,7 @@ void surface_set_compatible_renderbuffer(struct wined3d_surface *surface, const gl_info->fbo_ops.glGenRenderbuffers(1, &renderbuffer); gl_info->fbo_ops.glBindRenderbuffer(GL_RENDERBUFFER, renderbuffer); gl_info->fbo_ops.glRenderbufferStorage(GL_RENDERBUFFER, - surface->container->resource.format->glInternal, width, height); + texture->resource.format->glInternal, width, height); entry = heap_alloc(sizeof(*entry)); entry->width = width;
1
0
0
0
Nikolay Sivov : user32/tests: Remove commented out traces, use test calls instead of traces.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: d0b1e43c711a50378b07395d6745b67602f06968 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d0b1e43c711a50378b07395d…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed Feb 28 09:03:56 2018 +0300 user32/tests: Remove commented out traces, use test calls instead of traces. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/user32/tests/win.c | 46 ++++++++++++++-------------------------------- 1 file changed, 14 insertions(+), 32 deletions(-) diff --git a/dlls/user32/tests/win.c b/dlls/user32/tests/win.c index 96a2467..ab39ee8 100644 --- a/dlls/user32/tests/win.c +++ b/dlls/user32/tests/win.c @@ -2786,7 +2786,6 @@ static void check_z_order_debug(HWND hwnd, HWND next, HWND prev, HWND owner, UlongToHandle(GetWindowLongPtrA(test, GWLP_HINSTANCE)) != GetModuleHandleA(NULL) || GetWindow(test, GW_OWNER) == next)) { - /*trace("skipping next %p (%p)\n", test, UlongToHandle(GetWindowLongPtr(test, GWLP_HINSTANCE)));*/ test = GetWindow(test, GW_HWNDNEXT); } ok_(file, line)(next == test, "%p: expected next %p, got %p\n", hwnd, next, test); @@ -2798,7 +2797,6 @@ static void check_z_order_debug(HWND hwnd, HWND next, HWND prev, HWND owner, UlongToHandle(GetWindowLongPtrA(test, GWLP_HINSTANCE)) != GetModuleHandleA(NULL) || GetWindow(test, GW_OWNER) == hwnd)) { - /*trace("skipping prev %p (%p)\n", test, UlongToHandle(GetWindowLongPtr(test, GWLP_HINSTANCE)));*/ test = GetWindow(test, GW_HWNDPREV); } ok_(file, line)(prev == test, "%p: expected prev %p, got %p\n", hwnd, prev, test); @@ -3060,8 +3058,6 @@ static void test_SetActiveWindow(HWND hwnd) SetActiveWindow(0); check_wnd_state(0, 0, 0, 0); - /*trace("testing SetActiveWindow %p\n", hwnd);*/ - ShowWindow(hwnd, SW_SHOW); check_wnd_state(hwnd, hwnd, hwnd, 0); @@ -3084,7 +3080,7 @@ static void test_SetActiveWindow(HWND hwnd) ShowWindow(hwnd, SW_HIDE); check_wnd_state(0, 0, 0, 0); - /*trace("testing SetActiveWindow on an invisible window %p\n", hwnd);*/ + /* Invisible window. */ SetActiveWindow(hwnd); check_wnd_state(hwnd, hwnd, hwnd, 0); @@ -3176,8 +3172,6 @@ static void test_SetForegroundWindow(HWND hwnd) SetActiveWindow(0); check_wnd_state(0, 0, 0, 0); - /*trace("testing SetForegroundWindow %p\n", hwnd);*/ - ShowWindow(hwnd, SW_SHOW); check_wnd_state(hwnd, hwnd, hwnd, 0); @@ -3219,7 +3213,7 @@ static void test_SetForegroundWindow(HWND hwnd) ShowWindow(hwnd, SW_HIDE); check_wnd_state(0, 0, 0, 0); - /*trace("testing SetForegroundWindow on an invisible window %p\n", hwnd);*/ + /* Invisible window. */ ret = SetForegroundWindow(hwnd); ok(ret, "SetForegroundWindow returned FALSE instead of TRUE\n"); check_wnd_state(hwnd, hwnd, hwnd, 0); @@ -5206,10 +5200,8 @@ static void test_AWRwindow(LPCSTR class, LONG style, LONG exStyle, BOOL menu) 0, menu ? hmenu : 0, 0, 0); - if (!hwnd) { - trace("Failed to create window class=%s, style=0x%08x, exStyle=0x%08x\n", class, style, exStyle); - return; - } + ok(hwnd != NULL, "Failed to create window class=%s, style=0x%08x, exStyle=0x%08x\n", class, style, exStyle); + ShowWindow(hwnd, SW_SHOW); test_nonclient_area(hwnd); @@ -5354,6 +5346,7 @@ static void test_redrawnow(void) { WNDCLASSA cls; HWND hwndMain; + BOOL ret; cls.style = CS_DBLCLKS; cls.lpfnWndProc = redraw_window_procA; @@ -5365,11 +5358,8 @@ static void test_redrawnow(void) cls.hbrBackground = GetStockObject(WHITE_BRUSH); cls.lpszMenuName = NULL; cls.lpszClassName = "RedrawWindowClass"; - - if(!RegisterClassA(&cls)) { - trace("Register failed %d\n", GetLastError()); - return; - } + ret = RegisterClassA(&cls); + ok(ret, "Failed to register a test class.\n"); hwndMain = CreateWindowA("RedrawWindowClass", "Main Window", WS_OVERLAPPEDWINDOW, CW_USEDEFAULT, 0, 100, 100, NULL, NULL, 0, NULL); @@ -5471,6 +5461,7 @@ static void test_csparentdc(void) { WNDCLASSA clsMain, cls; HWND hwndMain, hwnd1, hwnd2; + BOOL ret; RECT rc; struct parentdc_test test_answer; @@ -5536,11 +5527,8 @@ static void test_csparentdc(void) clsMain.hbrBackground = GetStockObject(WHITE_BRUSH); clsMain.lpszMenuName = NULL; clsMain.lpszClassName = "ParentDcMainWindowClass"; - - if(!RegisterClassA(&clsMain)) { - trace("Register failed %d\n", GetLastError()); - return; - } + ret = RegisterClassA(&clsMain); + ok(ret, "Failed to register a test class.\n"); cls.style = CS_DBLCLKS | CS_PARENTDC; cls.lpfnWndProc = parentdc_window_procA; @@ -5552,11 +5540,8 @@ static void test_csparentdc(void) cls.hbrBackground = GetStockObject(WHITE_BRUSH); cls.lpszMenuName = NULL; cls.lpszClassName = "ParentDcWindowClass"; - - if(!RegisterClassA(&cls)) { - trace("Register failed %d\n", GetLastError()); - return; - } + ret = RegisterClassA(&cls); + ok(ret, "Failed to register a test class.\n"); SetRect(&rc, 0, 0, 150, 150); AdjustWindowRectEx(&rc, WS_OVERLAPPEDWINDOW, FALSE, 0); @@ -7041,11 +7026,8 @@ static void test_GetUpdateRect(void) cls.hbrBackground = GetStockObject(WHITE_BRUSH); cls.lpszMenuName = NULL; cls.lpszClassName = classNameA; - - if(!RegisterClassA(&cls)) { - trace("Register failed %d\n", GetLastError()); - return; - } + ret = RegisterClassA(&cls); + ok(ret, "Failed to register a test class.\n"); hgrandparent = CreateWindowA(classNameA, "grandparent", WS_OVERLAPPEDWINDOW, 0, 0, 100, 100, NULL, NULL, 0, NULL);
1
0
0
0
Roman Pišl : comctl32/tooltips: Set window size before TTN_SHOW and preserve it after.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 4803b7abc9633125d38e2fa4cc099d44fe497edc URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4803b7abc9633125d38e2fa4…
Author: Roman Pišl <rpisl(a)seznam.cz> Date: Wed Feb 28 09:00:05 2018 +0300 comctl32/tooltips: Set window size before TTN_SHOW and preserve it after. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/comctl32/tests/tooltips.c | 1 - dlls/comctl32/tooltips.c | 27 +++++++++++++-------------- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/dlls/comctl32/tests/tooltips.c b/dlls/comctl32/tests/tooltips.c index 7f37d5f..af95a56 100644 --- a/dlls/comctl32/tests/tooltips.c +++ b/dlls/comctl32/tests/tooltips.c @@ -304,7 +304,6 @@ static LRESULT WINAPI parent_wnd_proc(HWND hwnd, UINT message, WPARAM wParam, LP break; case TTN_SHOW: GetWindowRect(hdr->hwndFrom, &rect); - todo_wine ok(!EqualRect(&g_ttip_rect, &rect), "Unexpected window rectangle.\n"); break; } diff --git a/dlls/comctl32/tooltips.c b/dlls/comctl32/tooltips.c index e5b966a..5460101 100644 --- a/dlls/comctl32/tooltips.c +++ b/dlls/comctl32/tooltips.c @@ -624,18 +624,10 @@ TOOLTIPS_Show (TOOLTIPS_INFO *infoPtr, BOOL track_activate) } toolPtr = &infoPtr->tools[nTool]; - - TRACE("Show tooltip %d\n", nTool); - - hdr.hwndFrom = infoPtr->hwndSelf; - hdr.idFrom = toolPtr->uId; - hdr.code = TTN_SHOW; - SendMessageW (toolPtr->hwnd, WM_NOTIFY, toolPtr->uId, (LPARAM)&hdr); - - TRACE("%s\n", debugstr_w(infoPtr->szTipText)); - TOOLTIPS_CalcTipSize (infoPtr, &size); - TRACE("size %d x %d\n", size.cx, size.cy); + + TRACE("Show tooltip %d, %s, size %d x %d\n", nTool, debugstr_w(infoPtr->szTipText), + size.cx, size.cy); if (track_activate && (toolPtr->uFlags & TTF_TRACK)) { @@ -824,9 +816,16 @@ TOOLTIPS_Show (TOOLTIPS_INFO *infoPtr, BOOL track_activate) * it is no longer needed */ } - SetWindowPos (infoPtr->hwndSelf, HWND_TOPMOST, rect.left, rect.top, - rect.right - rect.left, rect.bottom - rect.top, - SWP_SHOWWINDOW | SWP_NOACTIVATE); + SetWindowPos (infoPtr->hwndSelf, NULL, rect.left, rect.top, + rect.right - rect.left, rect.bottom - rect.top, SWP_NOZORDER | SWP_NOACTIVATE); + + hdr.hwndFrom = infoPtr->hwndSelf; + hdr.idFrom = toolPtr->uId; + hdr.code = TTN_SHOW; + SendMessageW (toolPtr->hwnd, WM_NOTIFY, toolPtr->uId, (LPARAM)&hdr); + + SetWindowPos (infoPtr->hwndSelf, HWND_TOPMOST, 0, 0, 0, 0, + SWP_NOSIZE | SWP_NOMOVE | SWP_SHOWWINDOW | SWP_NOACTIVATE); /* repaint the tooltip */ InvalidateRect(infoPtr->hwndSelf, NULL, TRUE);
1
0
0
0
Nikolay Sivov : comctl32/tests: Run some Progress control tests on version 6.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 037d315a2893d642a7b20b19b0dbcc4c9f0f81fa URL:
https://source.winehq.org/git/wine.git/?a=commit;h=037d315a2893d642a7b20b19…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed Feb 28 08:57:53 2018 +0300 comctl32/tests: Run some Progress control tests on version 6. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/comctl32/tests/progress.c | 49 +++++++++++++++++++++++++++--------------- 1 file changed, 32 insertions(+), 17 deletions(-) diff --git a/dlls/comctl32/tests/progress.c b/dlls/comctl32/tests/progress.c index d3b219c..b911021 100644 --- a/dlls/comctl32/tests/progress.c +++ b/dlls/comctl32/tests/progress.c @@ -27,8 +27,9 @@ #include "wine/test.h" +#include "v6util.h" -static HWND hProgressParentWnd, hProgressWnd; +static HWND hProgressParentWnd; static const char progressTestClass[] = "ProgressBarTestClass"; static BOOL (WINAPI *pInitCommonControlsEx)(const INITCOMMONCONTROLSEX*); @@ -119,16 +120,6 @@ static void init(void) CW_USEDEFAULT, CW_USEDEFAULT, rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, GetModuleHandleA(NULL), 0); ok(hProgressParentWnd != NULL, "failed to create parent wnd\n"); - GetClientRect(hProgressParentWnd, &rect); - hProgressWnd = CreateWindowExA(0, PROGRESS_CLASSA, "", WS_CHILD | WS_VISIBLE, - 0, 0, rect.right, rect.bottom, hProgressParentWnd, NULL, GetModuleHandleA(NULL), 0); - ok(hProgressWnd != NULL, "Failed to create progress bar.\n"); - progress_wndproc = (WNDPROC)SetWindowLongPtrA(hProgressWnd, GWLP_WNDPROC, (LPARAM)progress_subclass_proc); - - ShowWindow(hProgressParentWnd, SW_SHOWNORMAL); - ok(GetUpdateRect(hProgressParentWnd, NULL, FALSE), "GetUpdateRect: There should be a region that needs to be updated\n"); - flush_events(); - update_window(hProgressParentWnd); } static void cleanup(void) @@ -151,9 +142,21 @@ static void cleanup(void) */ static void test_redraw(void) { - RECT client_rect; + RECT client_rect, rect; + HWND hProgressWnd; LRESULT ret; + GetClientRect(hProgressParentWnd, &rect); + hProgressWnd = CreateWindowExA(0, PROGRESS_CLASSA, "", WS_CHILD | WS_VISIBLE, + 0, 0, rect.right, rect.bottom, hProgressParentWnd, NULL, GetModuleHandleA(NULL), 0); + ok(hProgressWnd != NULL, "Failed to create progress bar.\n"); + progress_wndproc = (WNDPROC)SetWindowLongPtrA(hProgressWnd, GWLP_WNDPROC, (LPARAM)progress_subclass_proc); + + ShowWindow(hProgressParentWnd, SW_SHOWNORMAL); + ok(GetUpdateRect(hProgressParentWnd, NULL, FALSE), "GetUpdateRect: There should be a region that needs to be updated\n"); + flush_events(); + update_window(hProgressParentWnd); + SendMessageA(hProgressWnd, PBM_SETRANGE, 0, MAKELPARAM(0, 100)); SendMessageA(hProgressWnd, PBM_SETPOS, 10, 0); SendMessageA(hProgressWnd, PBM_SETSTEP, 20, 0); @@ -162,15 +165,15 @@ static void test_redraw(void) /* PBM_SETPOS */ ok(SendMessageA(hProgressWnd, PBM_SETPOS, 50, 0) == 10, "PBM_SETPOS must return the previous position\n"); ok(!GetUpdateRect(hProgressWnd, NULL, FALSE), "PBM_SETPOS: The progress bar should be redrawn immediately\n"); - + /* PBM_DELTAPOS */ ok(SendMessageA(hProgressWnd, PBM_DELTAPOS, 15, 0) == 50, "PBM_DELTAPOS must return the previous position\n"); ok(!GetUpdateRect(hProgressWnd, NULL, FALSE), "PBM_DELTAPOS: The progress bar should be redrawn immediately\n"); - + /* PBM_SETPOS */ ok(SendMessageA(hProgressWnd, PBM_SETPOS, 80, 0) == 65, "PBM_SETPOS must return the previous position\n"); ok(!GetUpdateRect(hProgressWnd, NULL, FALSE), "PBM_SETPOS: The progress bar should be redrawn immediately\n"); - + /* PBM_STEPIT */ ok(SendMessageA(hProgressWnd, PBM_STEPIT, 0, 0) == 80, "PBM_STEPIT must return the previous position\n"); ok(!GetUpdateRect(hProgressWnd, NULL, FALSE), "PBM_STEPIT: The progress bar should be redrawn immediately\n"); @@ -179,7 +182,7 @@ static void test_redraw(void) win_skip("PBM_GETPOS needs comctl32 > 4.70\n"); else ok(ret == 100, "PBM_GETPOS returned a wrong position : %d\n", (UINT)ret); - + /* PBM_SETRANGE and PBM_SETRANGE32: Usually the progress bar doesn't repaint itself immediately. If the position is not in the new range, it does. @@ -207,6 +210,8 @@ static void test_redraw(void) wine_dbgstr_rect(&last_paint_rect), wine_dbgstr_rect(&client_rect)); update_window(hProgressWnd); ok(erased, "Progress bar should have erased the background\n"); + + DestroyWindow(hProgressWnd); } static void test_setcolors(void) @@ -299,6 +304,8 @@ static void init_functions(void) START_TEST(progress) { INITCOMMONCONTROLSEX iccex; + ULONG_PTR ctx_cookie; + HANDLE hCtx; init_functions(); @@ -307,10 +314,18 @@ START_TEST(progress) pInitCommonControlsEx(&iccex); init(); - + test_redraw(); test_setcolors(); test_PBM_STEPIT(); + if (!load_v6_module(&ctx_cookie, &hCtx)) + return; + + test_setcolors(); + test_PBM_STEPIT(); + + unload_v6_module(ctx_cookie, hCtx); + cleanup(); }
1
0
0
0
Nikolay Sivov : wshom: Use global memory allocation helpers.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: f6bf26906547200a6cc23e6e139e357f440dc605 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f6bf26906547200a6cc23e6e…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed Feb 28 08:56:04 2018 +0300 wshom: Use global memory allocation helpers. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wshom.ocx/shell.c | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/dlls/wshom.ocx/shell.c b/dlls/wshom.ocx/shell.c index d7b36cf..1aa353a 100644 --- a/dlls/wshom.ocx/shell.c +++ b/dlls/wshom.ocx/shell.c @@ -24,6 +24,7 @@ #include "dispex.h" #include "wine/debug.h" +#include "wine/heap.h" #include "wine/unicode.h" WINE_DEFAULT_DEBUG_CHANNEL(wshom); @@ -130,7 +131,7 @@ static ULONG WINAPI WshExec_Release(IWshExec *iface) if (!ref) { CloseHandle(This->info.hThread); CloseHandle(This->info.hProcess); - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); } return ref; @@ -325,7 +326,7 @@ static HRESULT WshExec_create(BSTR command, IWshExec **ret) *ret = NULL; - This = HeapAlloc(GetProcessHeap(), 0, sizeof(*This)); + This = heap_alloc(sizeof(*This)); if (!This) return E_OUTOFMEMORY; @@ -333,7 +334,7 @@ static HRESULT WshExec_create(BSTR command, IWshExec **ret) This->ref = 1; if (!CreateProcessW(NULL, command, NULL, NULL, FALSE, 0, NULL, NULL, &si, &This->info)) { - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); return HRESULT_FROM_WIN32(GetLastError()); } @@ -383,7 +384,7 @@ static ULONG WINAPI WshEnvironment_Release(IWshEnvironment *iface) TRACE("(%p) ref = %d\n", This, ref); if (!ref) - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); return ref; } @@ -519,7 +520,7 @@ static HRESULT WshEnvironment_Create(IWshEnvironment **env) { WshEnvironment *This; - This = HeapAlloc(GetProcessHeap(), 0, sizeof(*This)); + This = heap_alloc(sizeof(*This)); if (!This) return E_OUTOFMEMORY; This->IWshEnvironment_iface.lpVtbl = &WshEnvironmentVtbl; @@ -572,7 +573,7 @@ static ULONG WINAPI WshCollection_Release(IWshCollection *iface) TRACE("(%p) ref = %d\n", This, ref); if (!ref) - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); return ref; } @@ -721,7 +722,7 @@ static HRESULT WshCollection_Create(IWshCollection **collection) { WshCollection *This; - This = HeapAlloc(GetProcessHeap(), 0, sizeof(*This)); + This = heap_alloc(sizeof(*This)); if (!This) return E_OUTOFMEMORY; This->IWshCollection_iface.lpVtbl = &WshCollectionVtbl; @@ -778,7 +779,7 @@ static ULONG WINAPI WshShortcut_Release(IWshShortcut *iface) { SysFreeString(This->path_link); IShellLinkW_Release(This->link); - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); } return ref; @@ -1077,7 +1078,7 @@ static HRESULT WshShortcut_Create(const WCHAR *path, IDispatch **shortcut) *shortcut = NULL; - This = HeapAlloc(GetProcessHeap(), 0, sizeof(*This)); + This = heap_alloc(sizeof(*This)); if (!This) return E_OUTOFMEMORY; This->IWshShortcut_iface.lpVtbl = &WshShortcutVtbl; @@ -1087,7 +1088,7 @@ static HRESULT WshShortcut_Create(const WCHAR *path, IDispatch **shortcut) &IID_IShellLinkW, (void**)&This->link); if (FAILED(hr)) { - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); return hr; } @@ -1095,7 +1096,7 @@ static HRESULT WshShortcut_Create(const WCHAR *path, IDispatch **shortcut) if (!This->path_link) { IShellLinkW_Release(This->link); - HeapFree(GetProcessHeap(), 0, This); + heap_free(This); return E_OUTOFMEMORY; } @@ -1426,7 +1427,7 @@ static HRESULT split_reg_path(const WCHAR *path, WCHAR **subkey, WCHAR **value) unsigned int len = *value - *subkey - 1; WCHAR *ret; - ret = HeapAlloc(GetProcessHeap(), 0, (len+1)*sizeof(WCHAR)); + ret = heap_alloc((len + 1)*sizeof(WCHAR)); if (!ret) return E_OUTOFMEMORY; @@ -1466,7 +1467,7 @@ static HRESULT WINAPI WshShell3_RegRead(IWshShell3 *iface, BSTR name, VARIANT *v if (ret == ERROR_SUCCESS) { void *data; - data = HeapAlloc(GetProcessHeap(), 0, datalen); + data = heap_alloc(datalen); if (!data) { hr = E_OUTOFMEMORY; goto fail; @@ -1474,7 +1475,7 @@ static HRESULT WINAPI WshShell3_RegRead(IWshShell3 *iface, BSTR name, VARIANT *v ret = RegGetValueW(root, subkey, val, RRF_RT_ANY, &type, data, &datalen); if (ret) { - HeapFree(GetProcessHeap(), 0, data); + heap_free(data); hr = HRESULT_FROM_WIN32(ret); goto fail; } @@ -1564,7 +1565,7 @@ static HRESULT WINAPI WshShell3_RegRead(IWshShell3 *iface, BSTR name, VARIANT *v hr = E_FAIL; }; - HeapFree(GetProcessHeap(), 0, data); + heap_free(data); if (FAILED(hr)) VariantInit(value); } @@ -1573,7 +1574,7 @@ static HRESULT WINAPI WshShell3_RegRead(IWshShell3 *iface, BSTR name, VARIANT *v fail: if (val) - HeapFree(GetProcessHeap(), 0, subkey); + heap_free(subkey); return hr; } @@ -1661,7 +1662,7 @@ static HRESULT WINAPI WshShell3_RegWrite(IWshShell3 *iface, BSTR name, VARIANT * fail: VariantClear(&v); if (val) - HeapFree(GetProcessHeap(), 0, subkey); + heap_free(subkey); return hr; }
1
0
0
0
Sebastian Lackner : bcrypt: Correctly check the size in BCryptGetProperty.
by Alexandre Julliard
28 Feb '18
28 Feb '18
Module: wine Branch: master Commit: 1db5170f49781a23d20424d1617a9a09fb131831 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1db5170f49781a23d20424d1…
Author: Sebastian Lackner <sebastian(a)fds-team.de> Date: Wed Feb 28 04:15:55 2018 +0000 bcrypt: Correctly check the size in BCryptGetProperty. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/bcrypt/bcrypt_main.c | 2 +- dlls/bcrypt/tests/bcrypt.c | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/dlls/bcrypt/bcrypt_main.c b/dlls/bcrypt/bcrypt_main.c index 72b5df2..28cf2d8 100644 --- a/dlls/bcrypt/bcrypt_main.c +++ b/dlls/bcrypt/bcrypt_main.c @@ -532,7 +532,7 @@ static NTSTATUS get_alg_property( enum alg_id id, const WCHAR *prop, UCHAR *buf, } if (!strcmpW( prop, BCRYPT_CHAINING_MODE )) { - if (size >= sizeof(BCRYPT_CHAIN_MODE_CBC)) + if (size >= sizeof(BCRYPT_CHAIN_MODE_CBC) * sizeof(WCHAR)) { memcpy(buf, BCRYPT_CHAIN_MODE_CBC, sizeof(BCRYPT_CHAIN_MODE_CBC)); *ret_size = sizeof(BCRYPT_CHAIN_MODE_CBC) * sizeof(WCHAR); diff --git a/dlls/bcrypt/tests/bcrypt.c b/dlls/bcrypt/tests/bcrypt.c index 6fa04b0..b716688 100644 --- a/dlls/bcrypt/tests/bcrypt.c +++ b/dlls/bcrypt/tests/bcrypt.c @@ -452,6 +452,12 @@ static void test_aes(void) ok(size == 64, "got %u\n", size); size = 0; + ret = pBCryptGetProperty(alg, BCRYPT_CHAINING_MODE, mode, sizeof(mode) - 1, &size, 0); + ok(ret == STATUS_BUFFER_TOO_SMALL, "got %08x\n", ret); + ok(size == 64, "got %u\n", size); + + size = 0; + memset(mode, 0, sizeof(mode)); ret = pBCryptGetProperty(alg, BCRYPT_CHAINING_MODE, mode, sizeof(mode), &size, 0); ok(ret == STATUS_SUCCESS, "got %08x\n", ret); ok(!lstrcmpW((const WCHAR *)mode, BCRYPT_CHAIN_MODE_CBC), "got %s\n", mode);
1
0
0
0
← Newer
1
2
3
4
5
6
...
81
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
Results per page:
10
25
50
100
200