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
September 2010
----- 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
852 discussions
Start a n
N
ew thread
Alexandre Julliard : user32: Avoid direct accesses to the window structure in NC_HandleNCHitTest.
by Alexandre Julliard
08 Sep '10
08 Sep '10
Module: wine Branch: master Commit: 4858c54a8e5b59cc8a3a7d41c5a4243aca597ea8 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=4858c54a8e5b59cc8a3a7d41c…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 8 13:19:04 2010 +0200 user32: Avoid direct accesses to the window structure in NC_HandleNCHitTest. --- dlls/user32/nonclient.c | 95 +++++++++++++++++----------------------------- 1 files changed, 35 insertions(+), 60 deletions(-) diff --git a/dlls/user32/nonclient.c b/dlls/user32/nonclient.c index 15ed22e..051041c 100644 --- a/dlls/user32/nonclient.c +++ b/dlls/user32/nonclient.c @@ -60,7 +60,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(nonclient); ((exStyle) & WS_EX_DLGMODALFRAME) || \ !((style) & (WS_CHILD | WS_POPUP))) -#define HAS_MENU(w) ((((w)->dwStyle & (WS_CHILD | WS_POPUP)) != WS_CHILD) && ((w)->wIDmenu != 0)) +#define HAS_MENU(hwnd,style) ((((style) & (WS_CHILD | WS_POPUP)) != WS_CHILD) && GetMenu(hwnd)) /****************************************************************************** @@ -512,33 +512,29 @@ static void NC_GetInsideRect( HWND hwnd, enum coords_relative relative, RECT *re /*********************************************************************** - * NC_DoNCHitTest - * - * Handle a WM_NCHITTEST message. Called from NC_HandleNCHitTest(). + * NC_HandleNCHitTest * - * FIXME: Just a modified copy of the Win 3.1 version. + * Handle a WM_NCHITTEST message. Called from DefWindowProc(). */ - -static LRESULT NC_DoNCHitTest (WND *wndPtr, POINT pt ) +LRESULT NC_HandleNCHitTest( HWND hwnd, POINT pt ) { RECT rect, rcClient; - POINT ptClient; + DWORD style, ex_style; - TRACE("hwnd=%p pt=%d,%d\n", wndPtr->obj.handle, pt.x, pt.y ); + TRACE("hwnd=%p pt=%d,%d\n", hwnd, pt.x, pt.y ); - GetWindowRect(wndPtr->obj.handle, &rect ); + ScreenToClient( hwnd, &pt ); + WIN_GetRectangles( hwnd, COORDS_CLIENT, &rect, &rcClient ); if (!PtInRect( &rect, pt )) return HTNOWHERE; - if (wndPtr->dwStyle & WS_MINIMIZE) return HTCAPTION; + style = GetWindowLongW( hwnd, GWL_STYLE ); + ex_style = GetWindowLongW( hwnd, GWL_EXSTYLE ); + if (style & WS_MINIMIZE) return HTCAPTION; - /* Check client area */ - ptClient = pt; - ScreenToClient( wndPtr->obj.handle, &ptClient ); - GetClientRect( wndPtr->obj.handle, &rcClient ); - if (PtInRect( &rcClient, ptClient )) return HTCLIENT; + if (PtInRect( &rcClient, pt )) return HTCLIENT; /* Check borders */ - if (HAS_THICKFRAME( wndPtr->dwStyle, wndPtr->dwExStyle )) + if (HAS_THICKFRAME( style, ex_style )) { InflateRect( &rect, -GetSystemMetrics(SM_CXFRAME), -GetSystemMetrics(SM_CYFRAME) ); if (!PtInRect( &rect, pt )) @@ -575,47 +571,46 @@ static LRESULT NC_DoNCHitTest (WND *wndPtr, POINT pt ) } else /* No thick frame */ { - if (HAS_DLGFRAME( wndPtr->dwStyle, wndPtr->dwExStyle )) + if (HAS_DLGFRAME( style, ex_style )) InflateRect(&rect, -GetSystemMetrics(SM_CXDLGFRAME), -GetSystemMetrics(SM_CYDLGFRAME)); - else if (HAS_THINFRAME( wndPtr->dwStyle )) + else if (HAS_THINFRAME( style )) InflateRect(&rect, -GetSystemMetrics(SM_CXBORDER), -GetSystemMetrics(SM_CYBORDER)); if (!PtInRect( &rect, pt )) return HTBORDER; } /* Check caption */ - if ((wndPtr->dwStyle & WS_CAPTION) == WS_CAPTION) + if ((style & WS_CAPTION) == WS_CAPTION) { - if (wndPtr->dwExStyle & WS_EX_TOOLWINDOW) + if (ex_style & WS_EX_TOOLWINDOW) rect.top += GetSystemMetrics(SM_CYSMCAPTION) - 1; else rect.top += GetSystemMetrics(SM_CYCAPTION) - 1; if (!PtInRect( &rect, pt )) { - BOOL min_or_max_box = (wndPtr->dwStyle & WS_MAXIMIZEBOX) || - (wndPtr->dwStyle & WS_MINIMIZEBOX); + BOOL min_or_max_box = (style & WS_MAXIMIZEBOX) || + (style & WS_MINIMIZEBOX); /* Check system menu */ - if ((wndPtr->dwStyle & WS_SYSMENU) && !(wndPtr->dwExStyle & WS_EX_TOOLWINDOW)) + if ((style & WS_SYSMENU) && !(ex_style & WS_EX_TOOLWINDOW)) { - if (NC_IconForWindow(wndPtr->obj.handle)) - rect.left += GetSystemMetrics(SM_CYCAPTION) - 1; + if (NC_IconForWindow(hwnd)) rect.left += GetSystemMetrics(SM_CYCAPTION) - 1; } if (pt.x < rect.left) return HTSYSMENU; /* Check close button */ - if (wndPtr->dwStyle & WS_SYSMENU) + if (style & WS_SYSMENU) rect.right -= GetSystemMetrics(SM_CYCAPTION); if (pt.x > rect.right) return HTCLOSE; /* Check maximize box */ /* In win95 there is automatically a Maximize button when there is a minimize one*/ - if (min_or_max_box && !(wndPtr->dwExStyle & WS_EX_TOOLWINDOW)) + if (min_or_max_box && !(ex_style & WS_EX_TOOLWINDOW)) rect.right -= GetSystemMetrics(SM_CXSIZE); if (pt.x > rect.right) return HTMAXBUTTON; /* Check minimize box */ /* In win95 there is automatically a Maximize button when there is a Maximize one*/ - if (min_or_max_box && !(wndPtr->dwExStyle & WS_EX_TOOLWINDOW)) + if (min_or_max_box && !(ex_style & WS_EX_TOOLWINDOW)) rect.right -= GetSystemMetrics(SM_CXSIZE); if (pt.x > rect.right) return HTMINBUTTON; @@ -625,26 +620,26 @@ static LRESULT NC_DoNCHitTest (WND *wndPtr, POINT pt ) /* Check vertical scroll bar */ - if (wndPtr->dwStyle & WS_VSCROLL) + if (style & WS_VSCROLL) { - if((wndPtr->dwExStyle & WS_EX_LEFTSCROLLBAR) != 0) + if((ex_style & WS_EX_LEFTSCROLLBAR) != 0) rcClient.left -= GetSystemMetrics(SM_CXVSCROLL); else rcClient.right += GetSystemMetrics(SM_CXVSCROLL); - if (PtInRect( &rcClient, ptClient )) return HTVSCROLL; + if (PtInRect( &rcClient, pt )) return HTVSCROLL; } /* Check horizontal scroll bar */ - if (wndPtr->dwStyle & WS_HSCROLL) + if (style & WS_HSCROLL) { rcClient.bottom += GetSystemMetrics(SM_CYHSCROLL); - if (PtInRect( &rcClient, ptClient )) + if (PtInRect( &rcClient, pt )) { /* Check size box */ - if ((wndPtr->dwStyle & WS_VSCROLL) && - ((((wndPtr->dwExStyle & WS_EX_LEFTSCROLLBAR) != 0) && (ptClient.x <= rcClient.left + GetSystemMetrics(SM_CXVSCROLL))) || - (((wndPtr->dwExStyle & WS_EX_LEFTSCROLLBAR) == 0) && (ptClient.x >= rcClient.right - GetSystemMetrics(SM_CXVSCROLL))))) + if ((style & WS_VSCROLL) && + ((((ex_style & WS_EX_LEFTSCROLLBAR) != 0) && (pt.x <= rcClient.left + GetSystemMetrics(SM_CXVSCROLL))) || + (((ex_style & WS_EX_LEFTSCROLLBAR) == 0) && (pt.x >= rcClient.right - GetSystemMetrics(SM_CXVSCROLL))))) return HTSIZE; return HTHSCROLL; } @@ -652,9 +647,9 @@ static LRESULT NC_DoNCHitTest (WND *wndPtr, POINT pt ) /* Check menu bar */ - if (HAS_MENU(wndPtr)) + if (HAS_MENU( hwnd, style )) { - if ((ptClient.y < 0) && (ptClient.x >= 0) && (ptClient.x < rcClient.right)) + if ((pt.y < 0) && (pt.x >= 0) && (pt.x < rcClient.right)) return HTMENU; } @@ -664,24 +659,6 @@ static LRESULT NC_DoNCHitTest (WND *wndPtr, POINT pt ) } -/*********************************************************************** - * NC_HandleNCHitTest - * - * Handle a WM_NCHITTEST message. Called from DefWindowProc(). - */ -LRESULT NC_HandleNCHitTest (HWND hwnd , POINT pt) -{ - LRESULT retvalue; - WND *wndPtr = WIN_GetPtr( hwnd ); - - if (!wndPtr || wndPtr == WND_OTHER_PROCESS || wndPtr == WND_DESKTOP) return HTERROR; - - retvalue = NC_DoNCHitTest (wndPtr, pt); - WIN_ReleasePtr( wndPtr ); - return retvalue; -} - - /****************************************************************************** * * NC_DrawSysButton @@ -986,10 +963,8 @@ static void NC_DoNCPaint( HWND hwnd, HRGN clip, BOOL suppress_menupaint ) WORD flags; HRGN hrgn; RECT rectClient; - int has_menu; if (!(wndPtr = WIN_GetPtr( hwnd )) || wndPtr == WND_OTHER_PROCESS) return; - has_menu = HAS_MENU(wndPtr); dwStyle = wndPtr->dwStyle; dwExStyle = wndPtr->dwExStyle; flags = wndPtr->flags; @@ -1053,7 +1028,7 @@ static void NC_DoNCPaint( HWND hwnd, HRGN clip, BOOL suppress_menupaint ) NC_DrawCaption(hdc, &r, hwnd, dwStyle, dwExStyle, active); } - if (has_menu) + if (HAS_MENU( hwnd, dwStyle )) { RECT r = rect; r.bottom = rect.top + GetSystemMetrics(SM_CYMENU);
1
0
0
0
Alexandre Julliard : user32: Avoid redundant server call in WIN_GetRectangles and fix the screen coordinates mapping .
by Alexandre Julliard
08 Sep '10
08 Sep '10
Module: wine Branch: master Commit: ca499d070f3ac707f49d46d1bf7f7588ccc7d76b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ca499d070f3ac707f49d46d1b…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Sep 8 13:15:29 2010 +0200 user32: Avoid redundant server call in WIN_GetRectangles and fix the screen coordinates mapping. --- dlls/user32/win.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/user32/win.c b/dlls/user32/win.c index 4f85547..f5e9064 100644 --- a/dlls/user32/win.c +++ b/dlls/user32/win.c @@ -708,14 +708,15 @@ BOOL WIN_GetRectangles( HWND hwnd, enum coords_relative relative, RECT *rectWind } WIN_ReleasePtr( win ); win = parent; - OffsetRect( &window_rect, -win->rectClient.left, -win->rectClient.top ); - OffsetRect( &client_rect, -win->rectClient.left, -win->rectClient.top ); + OffsetRect( &window_rect, win->rectClient.left, win->rectClient.top ); + OffsetRect( &client_rect, win->rectClient.left, win->rectClient.top ); } break; } if (rectWindow) *rectWindow = window_rect; if (rectClient) *rectClient = client_rect; WIN_ReleasePtr( win ); + return TRUE; } other_process:
1
0
0
0
Michael Stefaniuc : oleaut32: The function pointer should be const and not the return value.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: ec382f43452890354b9edd30ecb7d293045bb8c2 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ec382f43452890354b9edd30e…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Tue Sep 7 17:51:29 2010 +0200 oleaut32: The function pointer should be const and not the return value. --- dlls/oleaut32/typelib.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c index 0a3ad09..0fb3cee 100644 --- a/dlls/oleaut32/typelib.c +++ b/dlls/oleaut32/typelib.c @@ -5743,7 +5743,7 @@ __ASM_GLOBAL_FUNC( call_method, "ret" ) /* same function but returning floating point */ -static const double (*call_double_method)(void*,int,const DWORD*,int*) = (void *)call_method; +static double (* const call_double_method)(void*,int,const DWORD*,int*) = (void *)call_method; /* ITypeInfo::Invoke * @@ -5821,7 +5821,7 @@ __ASM_GLOBAL_FUNC( call_method, "ret") /* same function but returning floating point */ -static const double (CDECL *call_double_method)(void*,int,const DWORD_PTR*) = (void *)call_method; +static double (CDECL * const call_double_method)(void*,int,const DWORD_PTR*) = (void *)call_method; #endif /* __x86_64__ */
1
0
0
0
André Hentschel : winebuild: Don' t segfault when run without arguments.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: d0f434eb3ac343d522ca4319abfd2df78367a8bd URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d0f434eb3ac343d522ca4319a…
Author: André Hentschel <nerv(a)dawncrow.de> Date: Tue Sep 7 16:36:55 2010 +0200 winebuild: Don't segfault when run without arguments. --- tools/winebuild/main.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/winebuild/main.c b/tools/winebuild/main.c index f6c04fd..0fc351c 100644 --- a/tools/winebuild/main.c +++ b/tools/winebuild/main.c @@ -142,13 +142,13 @@ static void set_dll_file_name( const char *name, DLLSPEC *spec ) /* set the dll name from the file name */ static void init_dll_name( DLLSPEC *spec ) { - if (!spec->file_name) + if (!spec->file_name && output_file_name) { char *p; spec->file_name = xstrdup( output_file_name ); if ((p = strrchr( spec->file_name, '.' ))) *p = 0; } - if (!spec->dll_name) /* set default name from file name */ + if (!spec->dll_name && spec->file_name) /* set default name from file name */ { char *p; spec->dll_name = xstrdup( spec->file_name );
1
0
0
0
Jacek Caban : jscript: Addd jsdisp_addref helper function.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: f46f9261349e121d1d9a1dfb366083d90eefefc7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f46f9261349e121d1d9a1dfb3…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Sep 7 15:42:34 2010 +0200 jscript: Addd jsdisp_addref helper function. --- dlls/jscript/array.c | 6 +++--- dlls/jscript/dispex.c | 4 ++-- dlls/jscript/engine.c | 4 ++-- dlls/jscript/function.c | 2 +- dlls/jscript/global.c | 2 +- dlls/jscript/jscript.h | 5 +++++ 6 files changed, 14 insertions(+), 9 deletions(-) diff --git a/dlls/jscript/array.c b/dlls/jscript/array.c index f267b38..99127d4 100644 --- a/dlls/jscript/array.c +++ b/dlls/jscript/array.c @@ -506,8 +506,8 @@ static HRESULT Array_reverse(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISP } if(retv) { + jsdisp_addref(jsthis); var_set_jsdisp(retv, jsthis); - IDispatch_AddRef(V_DISPATCH(retv)); } return S_OK; @@ -745,8 +745,8 @@ static HRESULT Array_sort(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPAR if(cmp_func) jsdisp_release(cmp_func); if(retv) { + jsdisp_addref(jsthis); var_set_jsdisp(retv, jsthis); - IDispatch_AddRef(V_DISPATCH(retv)); } return S_OK; } @@ -850,8 +850,8 @@ static HRESULT Array_sort(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPAR return hres; if(retv) { + jsdisp_addref(jsthis); var_set_jsdisp(retv, jsthis); - IDispatch_AddRef(V_DISPATCH(retv)); } return S_OK; diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index be8967a..368cb6e 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -437,7 +437,7 @@ static HRESULT WINAPI DispatchEx_QueryInterface(IDispatchEx *iface, REFIID riid, *ppv = _IDispatchEx_(This); }else if(IsEqualGUID(&IID_IDispatchJS, riid)) { TRACE("(%p)->(IID_IDispatchJS %p)\n", This, ppv); - IUnknown_AddRef(_IDispatchEx_(This)); + jsdisp_addref(This); *ppv = This; return S_OK; }else { @@ -755,7 +755,7 @@ HRESULT init_dispex(jsdisp_t *dispex, script_ctx_t *ctx, const builtin_info_t *b dispex->prototype = prototype; if(prototype) - IDispatchEx_AddRef(_IDispatchEx_(prototype)); + jsdisp_addref(prototype); dispex->prop_cnt = 1; dispex->props[0].name = NULL; diff --git a/dlls/jscript/engine.c b/dlls/jscript/engine.c index 4bd4bfd..8aed4db 100644 --- a/dlls/jscript/engine.c +++ b/dlls/jscript/engine.c @@ -143,7 +143,7 @@ HRESULT scope_push(scope_chain_t *scope, jsdisp_t *obj, scope_chain_t **ret) new_scope->ref = 1; - IDispatchEx_AddRef(_IDispatchEx_(obj)); + jsdisp_addref(obj); new_scope->obj = obj; if(scope) { @@ -197,7 +197,7 @@ HRESULT create_exec_ctx(script_ctx_t *script_ctx, IDispatch *this_obj, jsdisp_t ctx->this_obj = to_disp(script_ctx->global); IDispatch_AddRef(ctx->this_obj); - IDispatchEx_AddRef(_IDispatchEx_(var_disp)); + jsdisp_addref(var_disp); ctx->var_disp = var_disp; if(scope) { diff --git a/dlls/jscript/function.c b/dlls/jscript/function.c index 56cd2b2..2bcc918 100644 --- a/dlls/jscript/function.c +++ b/dlls/jscript/function.c @@ -547,7 +547,7 @@ static HRESULT Function_arguments(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags switch(flags) { case DISPATCH_PROPERTYGET: { if(function->arguments) { - IDispatchEx_AddRef(_IDispatchEx_(function->arguments)); + jsdisp_addref(function->arguments); var_set_jsdisp(retv, function->arguments); }else { V_VT(retv) = VT_NULL; diff --git a/dlls/jscript/global.c b/dlls/jscript/global.c index eef57c4..21d9201 100644 --- a/dlls/jscript/global.c +++ b/dlls/jscript/global.c @@ -112,8 +112,8 @@ static HRESULT constructor_call(jsdisp_t *constr, WORD flags, DISPPARAMS *dp, if(flags != DISPATCH_PROPERTYGET) return jsdisp_call_value(constr, flags, dp, retv, ei, sp); + jsdisp_addref(constr); var_set_jsdisp(retv, constr); - IDispatchEx_AddRef(_IDispatchEx_(constr)); return S_OK; } diff --git a/dlls/jscript/jscript.h b/dlls/jscript/jscript.h index 5ed7e8f..e9318e5 100644 --- a/dlls/jscript/jscript.h +++ b/dlls/jscript/jscript.h @@ -192,6 +192,11 @@ static inline IDispatch *to_disp(jsdisp_t *jsdisp) return (IDispatch*)&jsdisp->lpIDispatchExVtbl; } +static inline void jsdisp_addref(jsdisp_t *jsdisp) +{ + IDispatchEx_AddRef(_IDispatchEx_(jsdisp)); +} + static inline void jsdisp_release(jsdisp_t *jsdisp) { IDispatchEx_Release(_IDispatchEx_(jsdisp));
1
0
0
0
Jacek Caban : jscript: jsdisp_t to IDispatch casts clean up.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: ac8d2f1fae0eb60f0ea5b21dee1ce6c5806ddc95 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ac8d2f1fae0eb60f0ea5b21de…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Sep 7 15:42:01 2010 +0200 jscript: jsdisp_t to IDispatch casts clean up. --- dlls/jscript/dispex.c | 2 +- dlls/jscript/engine.c | 10 +++++----- dlls/jscript/function.c | 6 +++--- dlls/jscript/jscript.c | 4 ++-- dlls/jscript/jsutils.c | 8 ++++---- dlls/jscript/regexp.c | 2 +- 6 files changed, 16 insertions(+), 16 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index 9739aa8..be8967a 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -285,7 +285,7 @@ static HRESULT invoke_prop_func(jsdisp_t *This, jsdisp_t *jsthis, dispex_prop_t TRACE("call %s %p\n", debugstr_w(prop->name), V_DISPATCH(&prop->u.var)); - hres = set_this(&new_dp, dp, (IDispatch*)_IDispatchEx_(jsthis)); + hres = set_this(&new_dp, dp, to_disp(jsthis)); if(FAILED(hres)) return hres; diff --git a/dlls/jscript/engine.c b/dlls/jscript/engine.c index 0556d69..4bd4bfd 100644 --- a/dlls/jscript/engine.c +++ b/dlls/jscript/engine.c @@ -194,7 +194,7 @@ HRESULT create_exec_ctx(script_ctx_t *script_ctx, IDispatch *this_obj, jsdisp_t else if(script_ctx->host_global) ctx->this_obj = script_ctx->host_global; else - ctx->this_obj = (IDispatch*)_IDispatchEx_(script_ctx->global); + ctx->this_obj = to_disp(script_ctx->global); IDispatch_AddRef(ctx->this_obj); IDispatchEx_AddRef(_IDispatchEx_(var_disp)); @@ -517,13 +517,13 @@ static HRESULT identifier_eval(exec_ctx_t *ctx, BSTR identifier, DWORD flags, js } if(scope) { - exprval_set_idref(ret, (IDispatch*)_IDispatchEx_(scope->obj), id); + exprval_set_idref(ret, to_disp(scope->obj), id); return S_OK; } hres = jsdisp_get_id(ctx->parser->script->global, identifier, 0, &id); if(SUCCEEDED(hres)) { - exprval_set_idref(ret, (IDispatch*)_IDispatchEx_(ctx->parser->script->global), id); + exprval_set_idref(ret, to_disp(ctx->parser->script->global), id); return S_OK; } @@ -566,7 +566,7 @@ static HRESULT identifier_eval(exec_ctx_t *ctx, BSTR identifier, DWORD flags, js if(FAILED(hres)) return hres; - exprval_set_idref(ret, (IDispatch*)_IDispatchEx_(ctx->parser->script->global), id); + exprval_set_idref(ret, to_disp(ctx->parser->script->global), id); return S_OK; } @@ -2017,7 +2017,7 @@ static HRESULT instanceof_eval(exec_ctx_t *ctx, VARIANT *inst, VARIANT *objv, js if(V_VT(inst) == VT_DISPATCH) tmp = iface_to_jsdisp((IUnknown*)V_DISPATCH(inst)); for(iter = tmp; iter; iter = iter->prototype) { - hres = disp_cmp(V_DISPATCH(&var), (IDispatch*)_IDispatchEx_(iter), &b); + hres = disp_cmp(V_DISPATCH(&var), to_disp(iter), &b); if(FAILED(hres)) break; if(b) { diff --git a/dlls/jscript/function.c b/dlls/jscript/function.c index 8b5638d..56cd2b2 100644 --- a/dlls/jscript/function.c +++ b/dlls/jscript/function.c @@ -196,7 +196,7 @@ static HRESULT invoke_source(script_ctx_t *ctx, FunctionInstance *function, IDis return E_FAIL; } - hres = create_arguments(ctx, (IDispatch*)_IDispatchEx_(&function->dispex), + hres = create_arguments(ctx, to_disp(&function->dispex), dp, ei, caller, &arg_disp); if(FAILED(hres)) return hres; @@ -239,7 +239,7 @@ static HRESULT invoke_constructor(script_ctx_t *ctx, FunctionInstance *function, if(FAILED(hres)) return hres; - hres = invoke_source(ctx, function, (IDispatch*)_IDispatchEx_(this_obj), dp, &var, ei, caller); + hres = invoke_source(ctx, function, to_disp(this_obj), dp, &var, ei, caller); if(FAILED(hres)) { jsdisp_release(this_obj); return hres; @@ -793,7 +793,7 @@ static HRESULT construct_function(script_ctx_t *ctx, DISPPARAMS *dp, jsexcept_t if(FAILED(hres)) return hres; - *ret = (IDispatch*)_IDispatchEx_(function); + *ret = to_disp(function); return S_OK; } diff --git a/dlls/jscript/jscript.c b/dlls/jscript/jscript.c index 3b15818..079db3d 100644 --- a/dlls/jscript/jscript.c +++ b/dlls/jscript/jscript.c @@ -558,7 +558,7 @@ static HRESULT WINAPI JScript_GetScriptDispatch(IActiveScript *iface, LPCOLESTR return E_UNEXPECTED; } - *ppdisp = (IDispatch*)_IDispatchEx_(This->ctx->global); + *ppdisp = to_disp(This->ctx->global); IDispatch_AddRef(*ppdisp); return S_OK; } @@ -779,7 +779,7 @@ static HRESULT WINAPI JScriptParseProcedure_ParseProcedureText(IActiveScriptPars if(FAILED(hres)) return hres; - *ppdisp = (IDispatch*)_IDispatchEx_(dispex); + *ppdisp = to_disp(dispex); return S_OK; } diff --git a/dlls/jscript/jsutils.c b/dlls/jscript/jsutils.c index 602a1a8..3024f3b 100644 --- a/dlls/jscript/jsutils.c +++ b/dlls/jscript/jsutils.c @@ -602,7 +602,7 @@ HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp) if(FAILED(hres)) return hres; - *disp = (IDispatch*)_IDispatchEx_(dispex); + *disp = to_disp(dispex); break; case VT_I4: case VT_R8: @@ -610,7 +610,7 @@ HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp) if(FAILED(hres)) return hres; - *disp = (IDispatch*)_IDispatchEx_(dispex); + *disp = to_disp(dispex); break; case VT_DISPATCH: if(V_DISPATCH(v)) { @@ -623,7 +623,7 @@ HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp) if(FAILED(hres)) return hres; - *disp = (IDispatch*)_IDispatchEx_(obj); + *disp = to_disp(obj); } break; case VT_BOOL: @@ -631,7 +631,7 @@ HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp) if(FAILED(hres)) return hres; - *disp = (IDispatch*)_IDispatchEx_(dispex); + *disp = to_disp(dispex); break; default: FIXME("unsupported vt %d\n", V_VT(v)); diff --git a/dlls/jscript/regexp.c b/dlls/jscript/regexp.c index 82a0a94..5d75144 100644 --- a/dlls/jscript/regexp.c +++ b/dlls/jscript/regexp.c @@ -3638,7 +3638,7 @@ static HRESULT create_match_array(script_ctx_t *ctx, BSTR input, const match_res return hres; } - *ret = (IDispatch*)_IDispatchEx_(array); + *ret = to_disp(array); return S_OK; }
1
0
0
0
Jacek Caban : jscript: Added a helper function for setting VARIANT value to jsdisp_t.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: 2ae0f44033049d4b747fce61fa06a8b4980abe2a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=2ae0f44033049d4b747fce61f…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Sep 7 15:41:40 2010 +0200 jscript: Added a helper function for setting VARIANT value to jsdisp_t. --- dlls/jscript/array.c | 35 ++++++++++++----------------------- dlls/jscript/bool.c | 3 +-- dlls/jscript/date.c | 3 +-- dlls/jscript/dispex.c | 7 ++----- dlls/jscript/engine.c | 15 +++++---------- dlls/jscript/error.c | 14 ++++---------- dlls/jscript/function.c | 13 +++++-------- dlls/jscript/global.c | 6 ++---- dlls/jscript/jscript.h | 11 +++++++++++ dlls/jscript/number.c | 3 +-- dlls/jscript/object.c | 3 +-- dlls/jscript/regexp.c | 24 +++++++++--------------- dlls/jscript/string.c | 11 ++++------- 13 files changed, 58 insertions(+), 90 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=2ae0f44033049d4b747fc…
1
0
0
0
Francois Gouget : msi/tests: Fix compilation on systems that don' t support nameless unions or structs.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: b66eb177af45f0b4b6082d5d286e55fd6a07cd1e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=b66eb177af45f0b4b6082d5d2…
Author: Francois Gouget <fgouget(a)free.fr> Date: Tue Sep 7 15:28:27 2010 +0200 msi/tests: Fix compilation on systems that don't support nameless unions or structs. --- dlls/msi/tests/package.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/msi/tests/package.c b/dlls/msi/tests/package.c index 225a0e3..fef79de 100644 --- a/dlls/msi/tests/package.c +++ b/dlls/msi/tests/package.c @@ -9666,7 +9666,7 @@ static void test_installprops(void) if (pGetSystemInfo) { pGetSystemInfo(&si); - if (si.wProcessorArchitecture == PROCESSOR_ARCHITECTURE_AMD64) + if (S(U(si)).wProcessorArchitecture == PROCESSOR_ARCHITECTURE_AMD64) { buf[0] = 0; size = MAX_PATH;
1
0
0
0
Jacek Caban : msxml3: Don't use xmlnode' s IXMLDOMNode iface in get_nodeType and get_nodeParent implementations.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: 6e76c894e8a38e6039bfba1cca5e343c26b44118 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6e76c894e8a38e6039bfba1cc…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Sep 7 15:28:21 2010 +0200 msxml3: Don't use xmlnode's IXMLDOMNode iface in get_nodeType and get_nodeParent implementations. --- dlls/msxml3/attribute.c | 6 +++++- dlls/msxml3/cdata.c | 11 +++++++++-- dlls/msxml3/comment.c | 11 +++++++++-- dlls/msxml3/docfrag.c | 11 +++++++++-- dlls/msxml3/domdoc.c | 11 +++++++++-- dlls/msxml3/element.c | 11 +++++++++-- dlls/msxml3/entityref.c | 11 +++++++++-- dlls/msxml3/msxml_private.h | 1 + dlls/msxml3/node.c | 29 +++++++++++++++-------------- dlls/msxml3/pi.c | 11 +++++++++-- dlls/msxml3/text.c | 11 +++++++++-- 11 files changed, 93 insertions(+), 31 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=6e76c894e8a38e6039bfb…
1
0
0
0
Jacek Caban : msxml3: Don't use xmlnode' s IXMLDOMNode iface in put_nodeValue implementations.
by Alexandre Julliard
07 Sep '10
07 Sep '10
Module: wine Branch: master Commit: 9413fab39ea86a55d2e1e3fb119599436138da42 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=9413fab39ea86a55d2e1e3fb1…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Sep 7 15:27:31 2010 +0200 msxml3: Don't use xmlnode's IXMLDOMNode iface in put_nodeValue implementations. --- dlls/msxml3/attribute.c | 14 ++++++-- dlls/msxml3/cdata.c | 7 +++- dlls/msxml3/comment.c | 10 ++++-- dlls/msxml3/docfrag.c | 5 ++- dlls/msxml3/domdoc.c | 5 ++- dlls/msxml3/element.c | 5 ++- dlls/msxml3/entityref.c | 5 ++- dlls/msxml3/msxml_private.h | 1 + dlls/msxml3/node.c | 66 +++++++++++++++--------------------------- dlls/msxml3/pi.c | 6 ++-- dlls/msxml3/text.c | 10 ++++-- 11 files changed, 67 insertions(+), 67 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=9413fab39ea86a55d2e1e…
1
0
0
0
← Newer
1
...
65
66
67
68
69
70
71
...
86
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
Results per page:
10
25
50
100
200