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
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
October 2012
----- 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
960 discussions
Start a n
N
ew thread
Daniel Lehman : msvcp90: Copy facetvec element pointer in copy ctor.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 4f5f2e8e1b29ee43dfe899fdb7530dd993f8a1b9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=4f5f2e8e1b29ee43dfe899fdb…
Author: Daniel Lehman <dlehman(a)esri.com> Date: Wed Oct 3 16:49:37 2012 -0700 msvcp90: Copy facetvec element pointer in copy ctor. --- dlls/msvcp90/locale.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/dlls/msvcp90/locale.c b/dlls/msvcp90/locale.c index 501443c..9a79933 100644 --- a/dlls/msvcp90/locale.c +++ b/dlls/msvcp90/locale.c @@ -7798,8 +7798,11 @@ locale__Locimp* __thiscall locale__Locimp_copy_ctor(locale__Locimp *this, const return NULL; } for(i=0; i<this->facet_cnt; i++) + { + this->facetvec[i] = copy->facetvec[i]; if(this->facetvec[i]) locale_facet__Incref(this->facetvec[i]); + } } MSVCP_basic_string_char_copy_ctor(&this->name, ©->name); _Lockit_dtor(&lock);
1
0
0
0
Daniel Lehman : msvcp90: Initialize state in mb_to_wc.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 650ccf598e5e6b5d01be22484d8ce184aa0a95de URL:
http://source.winehq.org/git/wine.git/?a=commit;h=650ccf598e5e6b5d01be22484…
Author: Daniel Lehman <dlehman(a)esri.com> Date: Tue Oct 2 00:04:22 2012 -0700 msvcp90: Initialize state in mb_to_wc. --- dlls/msvcp90/locale.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/msvcp90/locale.c b/dlls/msvcp90/locale.c index 010284e..501443c 100644 --- a/dlls/msvcp90/locale.c +++ b/dlls/msvcp90/locale.c @@ -4397,7 +4397,7 @@ num_get* num_get_short_use_facet(const locale *loc) static inline wchar_t mb_to_wc(char ch, const _Cvtvec *cvt) { - int state; + int state = 0; wchar_t ret; return _Mbrtowc(&ret, &ch, 1, &state, cvt) == 1 ? ret : 0;
1
0
0
0
Daniel Lehman : msvcp: Flip fclose result check in filebuf<>::close.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: c152c54084ac3c1a096563de9f7227f9a0be8f9b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c152c54084ac3c1a096563de9…
Author: Daniel Lehman <dlehman(a)esri.com> Date: Mon Oct 8 12:14:24 2012 -0700 msvcp: Flip fclose result check in filebuf<>::close. --- dlls/msvcp100/ios.c | 4 ++-- dlls/msvcp60/ios.c | 4 ++-- dlls/msvcp71/ios.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dlls/msvcp100/ios.c b/dlls/msvcp100/ios.c index 6b1fcc8..8122ad1 100644 --- a/dlls/msvcp100/ios.c +++ b/dlls/msvcp100/ios.c @@ -1993,7 +1993,7 @@ static basic_filebuf_char* basic_filebuf_char_close(basic_filebuf_char *this) /* TODO: handle exceptions */ if(!basic_filebuf_char__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_char__Init(this, NULL, INITFL_close); @@ -2482,7 +2482,7 @@ static basic_filebuf_wchar* basic_filebuf_wchar_close(basic_filebuf_wchar *this) /* TODO: handle exceptions */ if(!basic_filebuf_wchar__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_wchar__Init(this, NULL, INITFL_close); diff --git a/dlls/msvcp60/ios.c b/dlls/msvcp60/ios.c index 2b06716..43bd10b 100644 --- a/dlls/msvcp60/ios.c +++ b/dlls/msvcp60/ios.c @@ -2331,7 +2331,7 @@ basic_filebuf_char* __thiscall basic_filebuf_char_close(basic_filebuf_char *this /* TODO: handle exceptions */ if(!basic_filebuf_char__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_char__Init(this, NULL, INITFL_close); @@ -2901,7 +2901,7 @@ basic_filebuf_wchar* __thiscall basic_filebuf_wchar_close(basic_filebuf_wchar *t /* TODO: handle exceptions */ if(!basic_filebuf_wchar__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_wchar__Init(this, NULL, INITFL_close); diff --git a/dlls/msvcp71/ios.c b/dlls/msvcp71/ios.c index d2a1eb6..32e3941 100644 --- a/dlls/msvcp71/ios.c +++ b/dlls/msvcp71/ios.c @@ -2414,7 +2414,7 @@ basic_filebuf_char* __thiscall basic_filebuf_char_close(basic_filebuf_char *this /* TODO: handle exceptions */ if(!basic_filebuf_char__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_char__Init(this, NULL, INITFL_close); @@ -2974,7 +2974,7 @@ basic_filebuf_wchar* __thiscall basic_filebuf_wchar_close(basic_filebuf_wchar *t /* TODO: handle exceptions */ if(!basic_filebuf_wchar__Endwrite(this)) ret = NULL; - if(!fclose(this->file)) + if(fclose(this->file)) ret = NULL; basic_filebuf_wchar__Init(this, NULL, INITFL_close);
1
0
0
0
Alexandre Julliard : winex11: Recreate the GL drawable when changing the window parent.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: c6e0daa200587dda0710ee0dc7135097a4bdce7e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c6e0daa200587dda0710ee0dc…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Oct 10 10:46:16 2012 +0200 winex11: Recreate the GL drawable when changing the window parent. --- dlls/winex11.drv/opengl.c | 101 +++++++++++++++++++++++++++++++++++++-------- dlls/winex11.drv/window.c | 1 + dlls/winex11.drv/x11drv.h | 1 + 3 files changed, 86 insertions(+), 17 deletions(-) diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c index ac6f953..5151e20 100644 --- a/dlls/winex11.drv/opengl.c +++ b/dlls/winex11.drv/opengl.c @@ -1162,26 +1162,13 @@ static void free_gl_drawable( struct gl_drawable *gl ) /*********************************************************************** - * set_win_format + * create_gl_drawable */ -static BOOL set_win_format( HWND hwnd, const struct wgl_pixel_format *format ) +static BOOL create_gl_drawable( HWND hwnd, HWND parent, struct gl_drawable *gl ) { - HWND parent = GetAncestor( hwnd, GA_PARENT ); XSetWindowAttributes attrib; - struct gl_drawable *gl, *prev; - gl = HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*gl) ); - gl->format = format; - gl->visual = pglXGetVisualFromFBConfig( gdi_display, format->fbconfig ); - if (!gl->visual) - { - HeapFree( GetProcessHeap(), 0, gl ); - return FALSE; - } - - GetClientRect( hwnd, &gl->rect ); - gl->rect.right = min( max( 1, gl->rect.right ), 65535 ); - gl->rect.bottom = min( max( 1, gl->rect.bottom ), 65535 ); + gl->drawable = 0; if (parent == GetDesktopWindow()) /* top-level window */ { @@ -1261,7 +1248,32 @@ static BOOL set_win_format( HWND hwnd, const struct wgl_pixel_format *format ) } } - if (!gl->drawable) + return gl->drawable != 0; +} + + +/*********************************************************************** + * set_win_format + */ +static BOOL set_win_format( HWND hwnd, const struct wgl_pixel_format *format ) +{ + HWND parent = GetAncestor( hwnd, GA_PARENT ); + struct gl_drawable *gl, *prev; + + gl = HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*gl) ); + gl->format = format; + gl->visual = pglXGetVisualFromFBConfig( gdi_display, format->fbconfig ); + if (!gl->visual) + { + HeapFree( GetProcessHeap(), 0, gl ); + return FALSE; + } + + GetClientRect( hwnd, &gl->rect ); + gl->rect.right = min( max( 1, gl->rect.right ), 65535 ); + gl->rect.bottom = min( max( 1, gl->rect.bottom ), 65535 ); + + if (!create_gl_drawable( hwnd, parent, gl )) { XFree( gl->visual ); HeapFree( GetProcessHeap(), 0, gl ); @@ -1343,6 +1355,57 @@ done: release_gl_drawable( gl ); } + +/*********************************************************************** + * set_gl_drawable_parent + */ +void set_gl_drawable_parent( HWND hwnd, HWND parent ) +{ + struct gl_drawable *gl; + Drawable old_drawable; + + if (!(gl = get_gl_drawable( hwnd, 0 ))) return; + + TRACE( "setting drawable %lx parent %p\n", gl->drawable, parent ); + + old_drawable = gl->drawable; + switch (gl->type) + { + case DC_GL_WINDOW: + XDestroyWindow( gdi_display, gl->drawable ); + XFreeColormap( gdi_display, gl->colormap ); + break; + case DC_GL_CHILD_WIN: + if (parent != GetDesktopWindow()) goto done; + XDestroyWindow( gdi_display, gl->drawable ); + XFreeColormap( gdi_display, gl->colormap ); + break; + case DC_GL_PIXMAP_WIN: + if (parent != GetDesktopWindow()) goto done; + pglXDestroyGLXPixmap( gdi_display, gl->drawable ); + XFreePixmap( gdi_display, gl->pixmap ); + break; + default: + goto done; + } + + if (!create_gl_drawable( hwnd, parent, gl )) + { + XDeleteContext( gdi_display, (XID)hwnd, gl_hwnd_context ); + release_gl_drawable( gl ); + XFree( gl->visual ); + HeapFree( GetProcessHeap(), 0, gl ); + __wine_set_pixel_format( hwnd, 0 ); + return; + } + mark_drawable_dirty( old_drawable, gl->drawable ); + +done: + release_gl_drawable( gl ); + +} + + /*********************************************************************** * destroy_gl_drawable */ @@ -3076,6 +3139,10 @@ void sync_gl_drawable( HWND hwnd, const RECT *visible_rect, const RECT *client_r { } +void set_gl_drawable_parent( HWND hwnd, HWND parent ) +{ +} + void destroy_gl_drawable( HWND hwnd ) { } diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index b0fc9a0..f5f7af5 100644 --- a/dlls/winex11.drv/window.c +++ b/dlls/winex11.drv/window.c @@ -2002,6 +2002,7 @@ void CDECL X11DRV_SetParent( HWND hwnd, HWND parent, HWND old_parent ) } done: release_win_data( data ); + set_gl_drawable_parent( hwnd, parent ); fetch_icon_data( hwnd, 0, 0 ); } diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 2f34098..f4ccdd2 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -568,6 +568,7 @@ extern Window X11DRV_get_whole_window( HWND hwnd ) DECLSPEC_HIDDEN; extern XIC X11DRV_get_ic( HWND hwnd ) DECLSPEC_HIDDEN; extern void sync_gl_drawable( HWND hwnd, const RECT *visible_rect, const RECT *client_rect ) DECLSPEC_HIDDEN; +extern void set_gl_drawable_parent( HWND hwnd, HWND parent ) DECLSPEC_HIDDEN; extern void destroy_gl_drawable( HWND hwnd ) DECLSPEC_HIDDEN; extern void wait_for_withdrawn_state( HWND hwnd, BOOL set ) DECLSPEC_HIDDEN;
1
0
0
0
Alexandre Julliard : winex11: Create a surface even for OpenGL windows, to allow painting the non-client area.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 47983d819fddb566883e8d45c631a714f7ab8922 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=47983d819fddb566883e8d45c…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Oct 10 12:46:37 2012 +0200 winex11: Create a surface even for OpenGL windows, to allow painting the non-client area. --- dlls/winex11.drv/opengl.c | 14 -------------- dlls/winex11.drv/window.c | 1 - dlls/winex11.drv/x11drv.h | 1 - 3 files changed, 0 insertions(+), 16 deletions(-) diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c index b19f334..ac6f953 100644 --- a/dlls/winex11.drv/opengl.c +++ b/dlls/winex11.drv/opengl.c @@ -1114,15 +1114,6 @@ static void release_gl_drawable( struct gl_drawable *gl ) if (gl) LeaveCriticalSection( &context_section ); } -BOOL has_gl_drawable( HWND hwnd ) -{ - struct gl_drawable *gl; - - gl = get_gl_drawable( hwnd, 0 ); - release_gl_drawable( gl ); - return gl != NULL; -} - static GLXContext create_glxcontext(Display *display, struct wgl_context *context, GLXContext shareList) { GLXContext ctx; @@ -3081,11 +3072,6 @@ struct opengl_funcs *get_glx_driver( UINT version ) return NULL; } -BOOL has_gl_drawable( HWND hwnd ) -{ - return FALSE; -} - void sync_gl_drawable( HWND hwnd, const RECT *visible_rect, const RECT *client_rect ) { } diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index 386db2c..b0fc9a0 100644 --- a/dlls/winex11.drv/window.c +++ b/dlls/winex11.drv/window.c @@ -2060,7 +2060,6 @@ void CDECL X11DRV_WindowPosChanging( HWND hwnd, HWND insert_after, UINT swp_flag if (data->embedded) goto done; if (data->whole_window == root_window) goto done; - if (has_gl_drawable( hwnd )) goto done; if (!client_side_graphics && !layered) goto done; surface_rect = get_surface_rect( visible_rect ); diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 8e114a2..2f34098 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -567,7 +567,6 @@ extern void release_win_data( struct x11drv_win_data *data ) DECLSPEC_HIDDEN; extern Window X11DRV_get_whole_window( HWND hwnd ) DECLSPEC_HIDDEN; extern XIC X11DRV_get_ic( HWND hwnd ) DECLSPEC_HIDDEN; -extern BOOL has_gl_drawable( HWND hwnd ) DECLSPEC_HIDDEN; extern void sync_gl_drawable( HWND hwnd, const RECT *visible_rect, const RECT *client_rect ) DECLSPEC_HIDDEN; extern void destroy_gl_drawable( HWND hwnd ) DECLSPEC_HIDDEN;
1
0
0
0
Alexandre Julliard : user32: Don' t use the window surface when the pixel format was set.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 77b9ec8cd6079bb4602f002a4a25003b551ab46b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=77b9ec8cd6079bb4602f002a4…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Oct 10 12:46:14 2012 +0200 user32: Don't use the window surface when the pixel format was set. --- dlls/user32/painting.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/dlls/user32/painting.c b/dlls/user32/painting.c index 2a634fb..7d106bb 100644 --- a/dlls/user32/painting.c +++ b/dlls/user32/painting.c @@ -165,7 +165,8 @@ static void update_visible_region( struct dce *dce ) if ((win = WIN_GetPtr( top_win )) && win != WND_DESKTOP && win != WND_OTHER_PROCESS) { - surface = win->surface; + /* don't use a surface to paint the client area of OpenGL windows */ + if (!win->pixel_format || (flags & DCX_WINDOW)) surface = win->surface; if (surface) window_surface_add_ref( surface ); WIN_ReleasePtr( win ); }
1
0
0
0
Francois Gouget : shell32: Fix ShellExecute()'s handling of file URLs.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 53e4ddc399cef1f044fb25bdb19a478ced6178d7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=53e4ddc399cef1f044fb25bdb…
Author: Francois Gouget <fgouget(a)codeweavers.com> Date: Wed Oct 10 00:54:07 2012 +0200 shell32: Fix ShellExecute()'s handling of file URLs. --- dlls/shell32/shlexec.c | 46 +++++++++++++++++++++++++---------------- dlls/shell32/tests/shlexec.c | 46 ++++++++++++++++++++++------------------- 2 files changed, 53 insertions(+), 39 deletions(-) diff --git a/dlls/shell32/shlexec.c b/dlls/shell32/shlexec.c index a714fe8..5799ab0 100644 --- a/dlls/shell32/shlexec.c +++ b/dlls/shell32/shlexec.c @@ -1504,7 +1504,7 @@ static UINT_PTR SHELL_quote_and_execute( LPCWSTR wcmd, LPCWSTR wszParameters, LP return retval; } -static UINT_PTR SHELL_execute_url( LPCWSTR lpFile, LPCWSTR wFile, LPCWSTR wcmd, LPSHELLEXECUTEINFOW psei, LPSHELLEXECUTEINFOW psei_out, SHELL_ExecuteW32 execfunc ) +static UINT_PTR SHELL_execute_url( LPCWSTR lpFile, LPCWSTR wcmd, LPSHELLEXECUTEINFOW psei, LPSHELLEXECUTEINFOW psei_out, SHELL_ExecuteW32 execfunc ) { static const WCHAR wShell[] = {'\\','s','h','e','l','l','\\',0}; static const WCHAR wCommand[] = {'\\','c','o','m','m','a','n','d',0}; @@ -1534,13 +1534,6 @@ static UINT_PTR SHELL_execute_url( LPCWSTR lpFile, LPCWSTR wFile, LPCWSTR wcmd, strcatW(lpstrProtocol, psei->lpVerb && *psei->lpVerb ? psei->lpVerb: wszOpen); strcatW(lpstrProtocol, wCommand); - /* Remove File Protocol from lpFile */ - /* In the case file://path/file */ - if (!strncmpiW(lpFile, wFile, iSize)) - { - lpFile += iSize; - while (*lpFile == ':') lpFile++; - } retval = execute_from_key(lpstrProtocol, lpFile, NULL, psei->lpParameters, wcmd, execfunc, psei, psei_out); HeapFree(GetProcessHeap(), 0, lpstrProtocol); @@ -1567,7 +1560,6 @@ static BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc ) { static const WCHAR wSpace[] = {' ',0}; static const WCHAR wWww[] = {'w','w','w',0}; - static const WCHAR wFile[] = {'f','i','l','e',0}; static const WCHAR wHttp[] = {'h','t','t','p',':','/','/',0}; static const DWORD unsupportedFlags = SEE_MASK_INVOKEIDLIST | SEE_MASK_ICON | SEE_MASK_HOTKEY | @@ -1724,21 +1716,39 @@ static BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc ) dwApplicationNameLen ); } - /* expand environment strings */ - len = ExpandEnvironmentStringsW(sei_tmp.lpFile, NULL, 0); - if (len>0) + /* convert file URLs */ + if (UrlIsFileUrlW(sei_tmp.lpFile)) { LPWSTR buf; - buf = HeapAlloc(GetProcessHeap(),0,(len+1)*sizeof(WCHAR)); + DWORD size; + + size = MAX_PATH; + buf = HeapAlloc(GetProcessHeap(), 0, size * sizeof(WCHAR)); + if (FAILED(PathCreateFromUrlW(sei_tmp.lpFile, buf, &size, 0))) + return SE_ERR_OOM; - ExpandEnvironmentStringsW(sei_tmp.lpFile, buf, len+1); HeapFree(GetProcessHeap(), 0, wszApplicationName); - dwApplicationNameLen = len+1; + dwApplicationNameLen = lstrlenW(buf) + 1; wszApplicationName = buf; - /* appKnownSingular unmodified */ - sei_tmp.lpFile = wszApplicationName; } + else /* or expand environment strings (not both!) */ + { + len = ExpandEnvironmentStringsW(sei_tmp.lpFile, NULL, 0); + if (len>0) + { + LPWSTR buf; + buf = HeapAlloc(GetProcessHeap(), 0, (len + 1) * sizeof(WCHAR)); + + ExpandEnvironmentStringsW(sei_tmp.lpFile, buf, len + 1); + HeapFree(GetProcessHeap(), 0, wszApplicationName); + dwApplicationNameLen = len + 1; + wszApplicationName = buf; + /* appKnownSingular unmodified */ + + sei_tmp.lpFile = wszApplicationName; + } + } if (*sei_tmp.lpDirectory) { @@ -1889,7 +1899,7 @@ static BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc ) } else if (PathIsURLW(lpFile)) /* File not found, check for URL */ { - retval = SHELL_execute_url( lpFile, wFile, wcmd, &sei_tmp, sei, execfunc ); + retval = SHELL_execute_url( lpFile, wcmd, &sei_tmp, sei, execfunc ); } /* Check if file specified is in the form
www.??????.***
*/ else if (!strncmpiW(lpFile, wWww, 3)) diff --git a/dlls/shell32/tests/shlexec.c b/dlls/shell32/tests/shlexec.c index 8d164a6..e3d5676 100644 --- a/dlls/shell32/tests/shlexec.c +++ b/dlls/shell32/tests/shlexec.c @@ -1637,34 +1637,37 @@ typedef struct static fileurl_tests_t fileurl_tests[]= { /* How many slashes does it take... */ - {"file:", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file:/", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file://", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file:///", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"File:///", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file:////", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file://///", "%s\\test file.shlexec", 0, 0x1}, + {"file:", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file:/", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file://", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file:///", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"File:///", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file:////", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file://///", "%s\\test file.shlexec", 0, 0}, /* Test with Windows-style paths */ - {"file:///", "%s\\test file.shlexec", URL_SUCCESS | USE_COLON, 0x1}, - {"file:///", "%s\\test file.shlexec", URL_SUCCESS | USE_BSLASH, 0x1}, + {"file:///", "%s\\test file.shlexec", URL_SUCCESS | USE_COLON, 0}, + {"file:///", "%s\\test file.shlexec", URL_SUCCESS | USE_BSLASH, 0}, /* Check handling of hostnames */ - {"file://localhost/", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file://localhost:80/", "%s\\test file.shlexec", 0, 0x1}, - {"file://LocalHost/", "%s\\test file.shlexec", URL_SUCCESS, 0x1}, - {"file://127.0.0.1/", "%s\\test file.shlexec", 0, 0x1}, - {"file://::1/", "%s\\test file.shlexec", 0, 0x1}, - {"file://notahost/", "%s\\test file.shlexec", 0, 0x1}, + {"file://localhost/", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file://localhost:80/", "%s\\test file.shlexec", 0, 0}, + {"file://LocalHost/", "%s\\test file.shlexec", URL_SUCCESS, 0}, + {"file://127.0.0.1/", "%s\\test file.shlexec", 0, 0}, + {"file://::1/", "%s\\test file.shlexec", 0, 0}, + {"file://notahost/", "%s\\test file.shlexec", 0, 0}, /* Environment variables are not expanded in URLs */ {"%urlprefix%", "%s\\test file.shlexec", 0, 0x1}, - {"file:///", "%s\\%%urlenvvar%% file.shlexec", 0, 0x1}, + {"file:///", "%%TMPDIR%%\\test file.shlexec", 0, 0}, + + /* Test shortcuts vs. URLs */ + {"file://///", "%s\\test_shortcut_shlexec.lnk", 0, 0x1d}, {NULL, NULL, 0, 0} }; -static void test_fileurl(void) +static void test_fileurls(void) { char filename[MAX_PATH], fileurl[MAX_PATH], longtmpdir[MAX_PATH]; char command[MAX_PATH]; @@ -1681,7 +1684,6 @@ static void test_fileurl(void) get_long_path_name(tmpdir, longtmpdir, sizeof(longtmpdir)/sizeof(*longtmpdir)); SetEnvironmentVariable("urlprefix", "file:///"); - SetEnvironmentVariable("urlenvvar", "test"); test=fileurl_tests; while (test->basename) @@ -1705,7 +1707,10 @@ static void test_fileurl(void) ok(rc == SE_ERR_FNF, "FindExecutable(%s) failed: bad rc=%lu\n", fileurl, rc); /* Then ShellExecute() */ - rc = shell_execute(NULL, fileurl, NULL, NULL); + if ((test->todo & 0x10) == 0) + rc = shell_execute(NULL, fileurl, NULL, NULL); + else todo_wait + rc = shell_execute(NULL, fileurl, NULL, NULL); if (bad_shellexecute) { win_skip("shell32 is too old (likely 4.72). Skipping the file URL tests\n"); @@ -1750,7 +1755,6 @@ static void test_fileurl(void) } SetEnvironmentVariable("urlprefix", NULL); - SetEnvironmentVariable("urlenvvar", NULL); } static void test_find_executable(void) @@ -2639,7 +2643,7 @@ START_TEST(shlexec) test_argify(); test_lpFile_parsed(); test_filename(); - test_fileurl(); + test_fileurls(); test_find_executable(); test_lnks(); test_exes();
1
0
0
0
Francois Gouget : shell32/tests: Simplify shlexec's test_directory() and add some more tests.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: eee9b8ee124dafda078dc2412658e6403c1c402e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=eee9b8ee124dafda078dc2412…
Author: Francois Gouget <fgouget(a)codeweavers.com> Date: Wed Oct 10 00:53:52 2012 +0200 shell32/tests: Simplify shlexec's test_directory() and add some more tests. --- dlls/shell32/tests/shlexec.c | 68 +++++++++++++++++++++-------------------- 1 files changed, 35 insertions(+), 33 deletions(-) diff --git a/dlls/shell32/tests/shlexec.c b/dlls/shell32/tests/shlexec.c index 69b466e..8d164a6 100644 --- a/dlls/shell32/tests/shlexec.c +++ b/dlls/shell32/tests/shlexec.c @@ -818,26 +818,6 @@ static DWORD get_long_path_name(const char* shortpath, char* longpath, DWORD lon /*** * - * PathFindFileNameA equivalent that supports WinNT - * - ***/ - -static LPSTR path_find_file_name(LPCSTR lpszPath) -{ - LPCSTR lastSlash = lpszPath; - - while (lpszPath && *lpszPath) - { - if ((*lpszPath == '\\' || *lpszPath == '/' || *lpszPath == ':') && - lpszPath[1] && lpszPath[1] != '\\' && lpszPath[1] != '/') - lastSlash = lpszPath + 1; - lpszPath = CharNext(lpszPath); - } - return (LPSTR)lastSlash; -} - -/*** - * * Tests * ***/ @@ -2592,33 +2572,55 @@ static void cleanup_test(void) static void test_directory(void) { - char path[MAX_PATH], newdir[MAX_PATH]; - char params[1024]; + char path[MAX_PATH], curdir[MAX_PATH]; + char params[1024], dirpath[1024]; INT_PTR rc; - /* copy this executable to a new folder and cd to it */ - sprintf(newdir, "%s\\newfolder", tmpdir); - rc = CreateDirectoryA( newdir, NULL ); - ok( rc, "failed to create %s err %u\n", newdir, GetLastError() ); - sprintf(path, "%s\\%s", newdir, path_find_file_name(argv0)); + sprintf(path, "%s\\test2.exe", tmpdir); CopyFileA(argv0, path, FALSE); - SetCurrentDirectory(tmpdir); sprintf(params, "shlexec \"%s\" Exec", child_file); + /* Test with the current directory */ + GetCurrentDirectoryA(sizeof(curdir), curdir); + SetCurrentDirectoryA(tmpdir); rc=shell_execute_ex(SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, - NULL, path_find_file_name(argv0), params, NULL, NULL); - todo_wine ok(rc == SE_ERR_FNF, "%s returned %lu\n", shell_call, rc); + NULL, "test2.exe", params, NULL, NULL); + ok(rc > 32, "%s returned %lu\n", shell_call, rc); + okChildInt("argcA", 4); + okChildString("argvA3", "Exec"); + todo_wine okChildPath("longPath", path); + SetCurrentDirectoryA(curdir); + + rc=shell_execute_ex(SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, + NULL, "test2.exe", params, NULL, NULL); + ok(rc == SE_ERR_FNF, "%s returned %lu\n", shell_call, rc); + + /* Explicitly specify the directory to use */ + rc=shell_execute_ex(SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, + NULL, "test2.exe", params, tmpdir, NULL); + ok(rc > 32, "%s returned %lu\n", shell_call, rc); + okChildInt("argcA", 4); + okChildString("argvA3", "Exec"); + todo_wine okChildPath("longPath", path); + /* Specify it through an environment variable */ rc=shell_execute_ex(SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, - NULL, path_find_file_name(argv0), params, newdir, NULL); + NULL, "test2.exe", params, "%TMPDIR%", NULL); + todo_wine ok(rc == SE_ERR_FNF, "%s returned %lu\n", shell_call, rc); + + rc=shell_execute_ex(SEE_MASK_DOENVSUBST|SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, + NULL, "test2.exe", params, "%TMPDIR%", NULL); ok(rc > 32, "%s returned %lu\n", shell_call, rc); okChildInt("argcA", 4); okChildString("argvA3", "Exec"); todo_wine okChildPath("longPath", path); - DeleteFile(path); - RemoveDirectoryA(newdir); + /* Not a colon-separated directory list */ + sprintf(dirpath, "%s:%s", curdir, tmpdir); + rc=shell_execute_ex(SEE_MASK_NOZONECHECKS|SEE_MASK_FLAG_NO_UI, + NULL, "test2.exe", params, dirpath, NULL); + ok(rc == SE_ERR_FNF, "%s returned %lu\n", shell_call, rc); } START_TEST(shlexec)
1
0
0
0
Christian Costa : quartz: Don' t say we have a menu to AdjustWindowRectEx since the created window doesn' t have one.
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: c82d96fded3fabeee7a13fd60599a4a1bba49d07 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c82d96fded3fabeee7a13fd60…
Author: Christian Costa <titan.costa(a)gmail.com> Date: Tue Oct 9 23:55:53 2012 +0200 quartz: Don't say we have a menu to AdjustWindowRectEx since the created window doesn't have one. --- dlls/quartz/videorenderer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index 50a01fc..d6b87fa 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -184,7 +184,7 @@ static void VideoRenderer_AutoShowWindow(VideoRendererImpl *This) } } - AdjustWindowRectEx(&This->WindowPos, style, TRUE, style_ex); + AdjustWindowRectEx(&This->WindowPos, style, FALSE, style_ex); TRACE("WindowPos: %d %d %d %d\n", This->WindowPos.left, This->WindowPos.top, This->WindowPos.right, This->WindowPos.bottom); SetWindowPos(This->baseControlWindow.baseWindow.hWnd, NULL,
1
0
0
0
Christian Costa : quartz: Use target rect if set otherwise default to source rect in VideoRenderer_AutoShowWindow .
by Alexandre Julliard
10 Oct '12
10 Oct '12
Module: wine Branch: master Commit: 266e79d05f054904162dea62a3a2656b8917c13e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=266e79d05f054904162dea62a…
Author: Christian Costa <titan.costa(a)gmail.com> Date: Tue Oct 9 23:55:44 2012 +0200 quartz: Use target rect if set otherwise default to source rect in VideoRenderer_AutoShowWindow. --- dlls/quartz/videorenderer.c | 39 +++++++++++++++++++++++++++------------ 1 files changed, 27 insertions(+), 12 deletions(-) diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index 5e78c55..50a01fc 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -150,7 +150,8 @@ static BOOL CreateRenderingSubsystem(VideoRendererImpl* This) return TRUE; } -static void VideoRenderer_AutoShowWindow(VideoRendererImpl *This) { +static void VideoRenderer_AutoShowWindow(VideoRendererImpl *This) +{ if (!This->init && (!This->WindowPos.right || !This->WindowPos.top)) { DWORD style = GetWindowLongW(This->baseControlWindow.baseWindow.hWnd, GWL_STYLE); @@ -158,13 +159,29 @@ static void VideoRenderer_AutoShowWindow(VideoRendererImpl *This) { if (!This->WindowPos.right) { - This->WindowPos.left = This->SourceRect.left; - This->WindowPos.right = This->SourceRect.right; + if (This->DestRect.right) + { + This->WindowPos.left = This->DestRect.left; + This->WindowPos.right = This->DestRect.right; + } + else + { + This->WindowPos.left = This->SourceRect.left; + This->WindowPos.right = This->SourceRect.right; + } } if (!This->WindowPos.bottom) { - This->WindowPos.top = This->SourceRect.top; - This->WindowPos.bottom = This->SourceRect.bottom; + if (This->DestRect.bottom) + { + This->WindowPos.top = This->DestRect.top; + This->WindowPos.bottom = This->DestRect.bottom; + } + else + { + This->WindowPos.top = This->SourceRect.top; + This->WindowPos.bottom = This->SourceRect.bottom; + } } AdjustWindowRectEx(&This->WindowPos, style, TRUE, style_ex); @@ -740,7 +757,7 @@ static ULONG WINAPI VideoRenderer_Release(IBaseFilter * iface) static HRESULT WINAPI VideoRenderer_Pause(IBaseFilter * iface) { VideoRendererImpl *This = impl_from_IBaseFilter(iface); - + TRACE("(%p/%p)->()\n", This, iface); EnterCriticalSection(&This->renderer.csRenderLock); @@ -781,9 +798,8 @@ static const IBaseFilterVtbl VideoRenderer_Vtbl = }; /*** IUnknown methods ***/ -static HRESULT WINAPI Basicvideo_QueryInterface(IBasicVideo *iface, - REFIID riid, - LPVOID*ppvObj) { +static HRESULT WINAPI Basicvideo_QueryInterface(IBasicVideo *iface, REFIID riid, LPVOID *ppvObj) +{ VideoRendererImpl *This = impl_from_IBasicVideo(iface); TRACE("(%p/%p)->(%s (%p), %p)\n", This, iface, debugstr_guid(riid), riid, ppvObj); @@ -852,9 +868,8 @@ static const IBasicVideoVtbl IBasicVideo_VTable = /*** IUnknown methods ***/ -static HRESULT WINAPI Videowindow_QueryInterface(IVideoWindow *iface, - REFIID riid, - LPVOID*ppvObj) { +static HRESULT WINAPI Videowindow_QueryInterface(IVideoWindow *iface, REFIID riid, LPVOID *ppvObj) +{ VideoRendererImpl *This = impl_from_IVideoWindow(iface); TRACE("(%p/%p)->(%s (%p), %p)\n", This, iface, debugstr_guid(riid), riid, ppvObj);
1
0
0
0
← Newer
1
...
64
65
66
67
68
69
70
...
96
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
Results per page:
10
25
50
100
200