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
January 2012
----- 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
972 discussions
Start a n
N
ew thread
Aric Stewart : usp10: Move GDEF functions to opentype.c.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: bf1ef214e6f131945b84cb8fd91092d5a75e9b3e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bf1ef214e6f131945b84cb8fd…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Wed Jan 4 08:13:41 2012 -0600 usp10: Move GDEF functions to opentype.c. --- dlls/usp10/opentype.c | 146 ++++++++++++++++++++++++++++++++++++++++ dlls/usp10/shape.c | 155 ++----------------------------------------- dlls/usp10/usp10_internal.h | 1 + 3 files changed, 153 insertions(+), 149 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=bf1ef214e6f131945b84c…
1
0
0
0
Aric Stewart : usp10: Move CMAP functions to opentype.c.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 6311ccfe9703e819449ba93b4dfe717dcfda1dbe URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6311ccfe9703e819449ba93b4…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Wed Jan 4 08:13:38 2012 -0600 usp10: Move CMAP functions to opentype.c. --- dlls/usp10/Makefile.in | 1 + dlls/usp10/opentype.c | 162 +++++++++++++++++++++++++++++++++++++++++++ dlls/usp10/shape.c | 114 ------------------------------ dlls/usp10/usp10.c | 2 +- dlls/usp10/usp10_internal.h | 2 +- 5 files changed, 165 insertions(+), 116 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=6311ccfe9703e819449ba…
1
0
0
0
Jacek Caban : vbscript: Added for each loop parser implementation.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 8c1b9a01bf20f13d470a06caeeb08f88cc7d7e25 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=8c1b9a01bf20f13d470a06cae…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Wed Jan 4 11:50:29 2012 +0100 vbscript: Added for each loop parser implementation. --- dlls/vbscript/compile.c | 9 +++++++++ dlls/vbscript/lex.c | 4 ++++ dlls/vbscript/parse.h | 8 ++++++++ dlls/vbscript/parser.y | 20 +++++++++++++++++++- 4 files changed, 40 insertions(+), 1 deletions(-) diff --git a/dlls/vbscript/compile.c b/dlls/vbscript/compile.c index 435f9e3..9f62a23 100644 --- a/dlls/vbscript/compile.c +++ b/dlls/vbscript/compile.c @@ -616,6 +616,12 @@ static HRESULT compile_dowhile_statement(compile_ctx_t *ctx, while_statement_t * return S_OK; } +static HRESULT compile_foreach_statement(compile_ctx_t *ctx, foreach_statement_t *stat) +{ + FIXME("for each loop not implemented\n"); + return E_NOTIMPL; +} + static HRESULT compile_forto_statement(compile_ctx_t *ctx, forto_statement_t *stat) { unsigned step_instr, instr, prev_label; @@ -895,6 +901,9 @@ static HRESULT compile_statement(compile_ctx_t *ctx, statement_t *stat) case STAT_EXITSUB: hres = compile_exitsub_statement(ctx); break; + case STAT_FOREACH: + hres = compile_foreach_statement(ctx, (foreach_statement_t*)stat); + break; case STAT_FORTO: hres = compile_forto_statement(ctx, (forto_statement_t*)stat); break; diff --git a/dlls/vbscript/lex.c b/dlls/vbscript/lex.c index 81d4517..fe5fbae 100644 --- a/dlls/vbscript/lex.c +++ b/dlls/vbscript/lex.c @@ -35,6 +35,7 @@ static const WCHAR constW[] = {'c','o','n','s','t',0}; static const WCHAR defaultW[] = {'d','e','f','a','u','l','t',0}; static const WCHAR dimW[] = {'d','i','m',0}; static const WCHAR doW[] = {'d','o',0}; +static const WCHAR eachW[] = {'e','a','c','h',0}; static const WCHAR elseW[] = {'e','l','s','e',0}; static const WCHAR elseifW[] = {'e','l','s','e','i','f',0}; static const WCHAR emptyW[] = {'e','m','p','t','y',0}; @@ -50,6 +51,7 @@ static const WCHAR getW[] = {'g','e','t',0}; static const WCHAR gotoW[] = {'g','o','t','o',0}; static const WCHAR ifW[] = {'i','f',0}; static const WCHAR impW[] = {'i','m','p',0}; +static const WCHAR inW[] = {'i','n',0}; static const WCHAR isW[] = {'i','s',0}; static const WCHAR letW[] = {'l','e','t',0}; static const WCHAR loopW[] = {'l','o','o','p',0}; @@ -93,6 +95,7 @@ static const struct { {defaultW, tDEFAULT}, {dimW, tDIM}, {doW, tDO}, + {eachW, tEACH}, {elseW, tELSE}, {elseifW, tELSEIF}, {emptyW, tEMPTY}, @@ -108,6 +111,7 @@ static const struct { {gotoW, tGOTO}, {ifW, tIF}, {impW, tIMP}, + {inW, tIN}, {isW, tIS}, {letW, tLET}, {loopW, tLOOP}, diff --git a/dlls/vbscript/parse.h b/dlls/vbscript/parse.h index e58e7f3..b97ee13 100644 --- a/dlls/vbscript/parse.h +++ b/dlls/vbscript/parse.h @@ -107,6 +107,7 @@ typedef enum { STAT_EXITFUNC, STAT_EXITPROP, STAT_EXITSUB, + STAT_FOREACH, STAT_FORTO, STAT_FUNC, STAT_IF, @@ -209,6 +210,13 @@ typedef struct { typedef struct { statement_t stat; + const WCHAR *identifier; + expression_t *group_expr; + statement_t *body; +} foreach_statement_t; + +typedef struct { + statement_t stat; BOOL resume_next; } onerror_statement_t; diff --git a/dlls/vbscript/parser.y b/dlls/vbscript/parser.y index d6bda55..45e0e8a 100644 --- a/dlls/vbscript/parser.y +++ b/dlls/vbscript/parser.y @@ -53,6 +53,7 @@ static statement_t *new_set_statement(parser_ctx_t*,member_expression_t*,express static statement_t *new_dim_statement(parser_ctx_t*,dim_decl_t*); static statement_t *new_while_statement(parser_ctx_t*,statement_type_t,expression_t*,statement_t*); static statement_t *new_forto_statement(parser_ctx_t*,const WCHAR*,expression_t*,expression_t*,expression_t*,statement_t*); +static statement_t *new_foreach_statement(parser_ctx_t*,const WCHAR*,expression_t*,statement_t*); static statement_t *new_if_statement(parser_ctx_t*,expression_t*,statement_t*,elseif_decl_t*,statement_t*); static statement_t *new_function_statement(parser_ctx_t*,function_decl_t*); static statement_t *new_onerror_statement(parser_ctx_t*,BOOL); @@ -103,7 +104,7 @@ static statement_t *link_statements(statement_t*,statement_t*); %token tIS tLTEQ tGTEQ tMOD %token tCALL tDIM tSUB tFUNCTION tPROPERTY tGET tLET tCONST %token tIF tELSE tELSEIF tEND tTHEN tEXIT -%token tWHILE tWEND tDO tLOOP tUNTIL tFOR tTO tSTEP +%token tWHILE tWEND tDO tLOOP tUNTIL tFOR tTO tSTEP tEACH tIN %token tBYREF tBYVAL %token tOPTION tEXPLICIT %token tSTOP @@ -190,6 +191,8 @@ SimpleStatement | tCONST ConstDeclList { $$ = new_const_statement(ctx, $2); CHECK_ERROR; } | tFOR tIdentifier '=' Expression tTO Expression Step_opt tNL StatementsNl_opt tNEXT { $$ = new_forto_statement(ctx, $2, $4, $6, $7, $9); CHECK_ERROR; } + | tFOR tEACH tIdentifier tIN Expression tNL StatementsNl_opt tNEXT + { $$ = new_foreach_statement(ctx, $3, $5, $7); } MemberExpression : tIdentifier { $$ = new_member_expression(ctx, NULL, $1); CHECK_ERROR; } @@ -651,6 +654,21 @@ static statement_t *new_forto_statement(parser_ctx_t *ctx, const WCHAR *identifi return &stat->stat; } +static statement_t *new_foreach_statement(parser_ctx_t *ctx, const WCHAR *identifier, expression_t *group_expr, + statement_t *body) +{ + foreach_statement_t *stat; + + stat = new_statement(ctx, STAT_FOREACH, sizeof(*stat)); + if(!stat) + return NULL; + + stat->identifier = identifier; + stat->group_expr = group_expr; + stat->body = body; + return &stat->stat; +} + static statement_t *new_if_statement(parser_ctx_t *ctx, expression_t *expr, statement_t *if_stat, elseif_decl_t *elseif_decl, statement_t *else_stat) {
1
0
0
0
Dmitry Timoshkov : user32: Add some tests for SetFocus/ SetActiveWindow called on invalid or belonging to another thread windows.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 593340774a5257d50489c842ddab81706e48b278 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=593340774a5257d50489c842d…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Wed Jan 4 19:14:56 2012 +0800 user32: Add some tests for SetFocus/SetActiveWindow called on invalid or belonging to another thread windows. --- dlls/user32/tests/msg.c | 137 +++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 133 insertions(+), 4 deletions(-) diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index 407fc7b..c14fc04 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -13523,8 +13523,19 @@ static const struct message WmSetFocus_4[] = { static void test_SetFocus(void) { - HWND parent, old_parent, child, old_focus; + HWND parent, old_parent, child, old_focus, old_active; MSG msg; + struct wnd_event wnd_event; + HANDLE hthread; + DWORD ret, tid; + + wnd_event.start_event = CreateEvent(NULL, 0, 0, NULL); + ok(wnd_event.start_event != 0, "CreateEvent error %d\n", GetLastError()); + hthread = CreateThread(NULL, 0, thread_proc, &wnd_event, 0, &tid); + ok(hthread != 0, "CreateThread error %d\n", GetLastError()); + ret = WaitForSingleObject(wnd_event.start_event, INFINITE); + ok(ret == WAIT_OBJECT_0, "WaitForSingleObject failed\n"); + CloseHandle(wnd_event.start_event); parent = CreateWindowEx(0, "TestParentClass", NULL, WS_OVERLAPPEDWINDOW, 0, 0, 0, 0, 0, 0, 0, NULL); @@ -13533,7 +13544,7 @@ static void test_SetFocus(void) 0, 0, 0, 0, parent, 0, 0, NULL); ok(child != 0, "failed to create child window\n"); - trace("parent %p, child %p\n", parent, child); + trace("parent %p, child %p, thread window %p\n", parent, child, wnd_event.hwnd); SetFocus(0); SetActiveWindow(0); @@ -13560,26 +13571,138 @@ static void test_SetFocus(void) ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + SetLastError(0xdeadbeef); + old_focus = SetFocus((HWND)0xdeadbeef); +todo_wine + ok(GetLastError() == ERROR_INVALID_WINDOW_HANDLE, "expected ERROR_INVALID_WINDOW_HANDLE, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetFocus on an invalid window", TRUE); + ok(old_focus == 0, "expected old focus 0, got %p\n", old_focus); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + old_focus = SetFocus(GetDesktopWindow()); + ok(GetLastError() == ERROR_ACCESS_DENIED /* Vista+ */ || + broken(GetLastError() == 0xdeadbeef), "expected ERROR_ACCESS_DENIED, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetFocus on a desktop window", TRUE); + ok(old_focus == 0, "expected old focus 0, got %p\n", old_focus); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + old_focus = SetFocus(wnd_event.hwnd); + ok(GetLastError() == ERROR_ACCESS_DENIED /* Vista+ */ || + broken(GetLastError() == 0xdeadbeef), "expected ERROR_ACCESS_DENIED, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetFocus on another thread window", TRUE); + ok(old_focus == 0, "expected old focus 0, got %p\n", old_focus); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + old_active = SetActiveWindow((HWND)0xdeadbeef); +todo_wine + ok(GetLastError() == ERROR_INVALID_WINDOW_HANDLE, "expected ERROR_INVALID_WINDOW_HANDLE, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetActiveWindow on an invalid window", TRUE); + ok(old_active == 0, "expected old focus 0, got %p\n", old_active); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + old_active = SetActiveWindow(GetDesktopWindow()); +todo_wine + ok(GetLastError() == 0xdeadbeef, "expected 0xdeadbeef, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetActiveWindow on a desktop window", TRUE); + ok(old_active == 0, "expected old focus 0, got %p\n", old_focus); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + old_active = SetActiveWindow(wnd_event.hwnd); +todo_wine + ok(GetLastError() == 0xdeadbeef, "expected 0xdeadbeef, got %d\n", GetLastError()); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok_sequence(WmEmptySeq, "SetActiveWindow on another thread window", TRUE); + ok(old_active == 0, "expected old focus 0, got %p\n", old_active); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + SetLastError(0xdeadbeef); + ret = AttachThreadInput(GetCurrentThreadId(), tid, TRUE); + ok(ret, "AttachThreadInput error %d\n", GetLastError()); + +todo_wine { + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); +} + flush_events(); + flush_sequence(); + + old_focus = SetFocus(wnd_event.hwnd); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok(old_focus == wnd_event.hwnd, "expected old focus %p, got %p\n", wnd_event.hwnd, old_focus); + ok(GetActiveWindow() == wnd_event.hwnd, "expected active %p, got %p\n", wnd_event.hwnd, GetActiveWindow()); + ok(GetFocus() == wnd_event.hwnd, "expected focus %p, got %p\n", wnd_event.hwnd, GetFocus()); + + old_focus = SetFocus(parent); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok(old_focus == parent, "expected old focus %p, got %p\n", parent, old_focus); + ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); + ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); + + flush_events(); + flush_sequence(); + + old_active = SetActiveWindow(wnd_event.hwnd); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok(old_active == parent, "expected old focus %p, got %p\n", parent, old_active); + ok(GetActiveWindow() == wnd_event.hwnd, "expected active %p, got %p\n", wnd_event.hwnd, GetActiveWindow()); + ok(GetFocus() == wnd_event.hwnd, "expected focus %p, got %p\n", wnd_event.hwnd, GetFocus()); + + SetLastError(0xdeadbeef); + ret = AttachThreadInput(GetCurrentThreadId(), tid, FALSE); + ok(ret, "AttachThreadInput error %d\n", GetLastError()); + + ok(GetActiveWindow() == 0, "expected active 0, got %p\n", GetActiveWindow()); + ok(GetFocus() == 0, "expected focus 0, got %p\n", GetFocus()); + old_parent = SetParent(child, GetDesktopWindow()); ok(old_parent == parent, "expected old parent %p, got %p\n", parent, old_parent); + ok(GetActiveWindow() == 0, "expected active 0, got %p\n", GetActiveWindow()); + ok(GetFocus() == 0, "expected focus 0, got %p\n", GetFocus()); + + old_focus = SetFocus(parent); + while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); + ok(old_focus == parent, "expected old focus %p, got %p\n", parent, old_focus); ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); flush_events(); flush_sequence(); + SetLastError(0xdeadbeef); old_focus = SetFocus(child); +todo_wine + ok(GetLastError() == ERROR_INVALID_PARAMETER /* Vista+ */ || + broken(GetLastError() == 0) /* XP */ || + broken(GetLastError() == 0xdeadbeef), "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); ok_sequence(WmSetFocus_3, "SetFocus on a child window", TRUE); ok(old_focus == 0, "expected old focus 0, got %p\n", old_focus); ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); - old_focus = SetActiveWindow(child); + SetLastError(0xdeadbeef); + old_active = SetActiveWindow(child); + ok(GetLastError() == 0xdeadbeef, "expected 0xdeadbeef, got %d\n", GetLastError()); while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) DispatchMessage(&msg); ok_sequence(WmEmptySeq, "SetActiveWindow on a child window", FALSE); - ok(old_focus == parent, "expected old active %p, got %p\n", parent, old_focus); + ok(old_active == parent, "expected old active %p, got %p\n", parent, old_active); ok(GetActiveWindow() == parent, "expected active %p, got %p\n", parent, GetActiveWindow()); ok(GetFocus() == parent, "expected focus %p, got %p\n", parent, GetFocus()); @@ -13587,6 +13710,12 @@ static void test_SetFocus(void) DestroyWindow(child); DestroyWindow(parent); + + ret = PostMessage(wnd_event.hwnd, WM_QUIT, 0, 0); + ok(ret, "PostMessage(WM_QUIT) error %d\n", GetLastError()); + ret = WaitForSingleObject(hthread, INFINITE); + ok(ret == WAIT_OBJECT_0, "WaitForSingleObject failed\n"); + CloseHandle(hthread); } START_TEST(msg)
1
0
0
0
Eric Pouech : winedbg: Added support for qAttached query packet.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: b4cea6e4026895e9ebebeabf6f57bdcbd64de867 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=b4cea6e4026895e9ebebeabf6…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 3 21:37:59 2012 +0100 winedbg: Added support for qAttached query packet. --- programs/winedbg/gdbproxy.c | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/programs/winedbg/gdbproxy.c b/programs/winedbg/gdbproxy.c index 1a30947..9205bad 100644 --- a/programs/winedbg/gdbproxy.c +++ b/programs/winedbg/gdbproxy.c @@ -1785,6 +1785,16 @@ static enum packet_return packet_query(struct gdb_context* gdbctx) return packet_done; } break; + case 'A': + if (strncmp(gdbctx->in_packet, "Attached", gdbctx->in_packet_len) == 0) + { + char buf[2]; + + buf[0] = '1'; + buf[1] = 0; + return packet_reply(gdbctx, buf, -1); + } + break; case 'C': if (gdbctx->in_packet_len == 1) {
1
0
0
0
Eric Pouech : dbghelp: When StackWalk fails to get any frame information, create a default one.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 1ecef8242de0027dbe38f1a2d79062ebd87f9b53 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1ecef8242de0027dbe38f1a2d…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 3 21:37:49 2012 +0100 dbghelp: When StackWalk fails to get any frame information, create a default one. --- programs/winedbg/stack.c | 17 +++++++++++------ 1 files changed, 11 insertions(+), 6 deletions(-) diff --git a/programs/winedbg/stack.c b/programs/winedbg/stack.c index f6583a3..74dcc40 100644 --- a/programs/winedbg/stack.c +++ b/programs/winedbg/stack.c @@ -192,6 +192,7 @@ unsigned stack_fetch_frames(const CONTEXT* _ctx) * it to avoid any damage */ CONTEXT ctx = *_ctx; + BOOL ret; HeapFree(GetProcessHeap(), 0, dbg_curr_thread->frames); dbg_curr_thread->frames = NULL; @@ -208,11 +209,12 @@ unsigned stack_fetch_frames(const CONTEXT* _ctx) sf.AddrFrame.Mode = AddrModeFlat; } - while (StackWalk64(be_cpu->machine, dbg_curr_process->handle, - dbg_curr_thread->handle, &sf, &ctx, stack_read_mem, - SymFunctionTableAccess64, SymGetModuleBase64, NULL)) + while ((ret = StackWalk64(be_cpu->machine, dbg_curr_process->handle, + dbg_curr_thread->handle, &sf, &ctx, stack_read_mem, + SymFunctionTableAccess64, SymGetModuleBase64, NULL)) || + nf == 0) /* we always register first frame information */ { - dbg_curr_thread->frames = dbg_heap_realloc(dbg_curr_thread->frames, + dbg_curr_thread->frames = dbg_heap_realloc(dbg_curr_thread->frames, (nf + 1) * sizeof(dbg_curr_thread->frames[0])); dbg_curr_thread->frames[nf].addr_pc = sf.AddrPC; @@ -230,8 +232,11 @@ unsigned stack_fetch_frames(const CONTEXT* _ctx) (dbg_curr_thread->frames[nf - 1].is_ctx_valid && memcmp(&dbg_curr_thread->frames[nf - 1].context, &ctx, sizeof(ctx)))); nf++; - /* we've probably gotten ourselves into an infinite loop so bail */ - if (nf > 200) break; + /* bail if: + * - we've (probably) gotten ourselves into an infinite loop, + * - or StackWalk failed on first frame + */ + if (nf > 200 || !ret) break; } dbg_curr_thread->curr_frame = -1; dbg_curr_thread->num_frames = nf;
1
0
0
0
Aric Stewart : usp10: Add more Microsoft Sans Serif fallbacks.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: ece423b858000d2bd451880229eada1f05671037 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ece423b858000d2bd45188022…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Tue Jan 3 14:09:11 2012 -0600 usp10: Add more Microsoft Sans Serif fallbacks. --- dlls/usp10/usp10.c | 14 +++++++------- 1 files changed, 7 insertions(+), 7 deletions(-) diff --git a/dlls/usp10/usp10.c b/dlls/usp10/usp10.c index 1f6ec53..c26c793 100644 --- a/dlls/usp10/usp10.c +++ b/dlls/usp10/usp10.c @@ -307,7 +307,7 @@ const scriptData scriptInformation[] = { {{Script_Latin, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ENGLISH, 0, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 1, 0, 0}, MS_MAKE_TAG('l','a','t','n'), - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_CR, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_NEUTRAL, 0, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 0x00000000, @@ -315,7 +315,7 @@ const scriptData scriptInformation[] = { {{Script_Numeric, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ENGLISH, 1, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 0x00000000, - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Control, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ENGLISH, 0, 1, 0, 0, ANSI_CHARSET, 1, 0, 0, 0, 0, 0, 1, 0, 0}, 0x00000000, @@ -323,7 +323,7 @@ const scriptData scriptInformation[] = { {{Script_Punctuation, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_NEUTRAL, 0, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 0x00000000, - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Arabic, 1, 1, 0, 0, 0, 0, { 1,0,0,0,0,0,0,0,0,0,0}}, {LANG_ARABIC, 0, 1, 0, 0, ARABIC_CHARSET, 0, 0, 0, 0, 0, 0, 1, 1, 0}, MS_MAKE_TAG('a','r','a','b'), @@ -351,11 +351,11 @@ const scriptData scriptInformation[] = { {{Script_Greek, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_GREEK, 0, 0, 0, 0, GREEK_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, MS_MAKE_TAG('g','r','e','k'), - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Cyrillic, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_RUSSIAN, 0, 0, 0, 0, RUSSIAN_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, MS_MAKE_TAG('c','y','r','l'), - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Armenian, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ARMENIAN, 0, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 1, 0, 0}, MS_MAKE_TAG('a','r','m','n'), @@ -483,7 +483,7 @@ const scriptData scriptInformation[] = { {{Script_Punctuation2, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ENGLISH, 0, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, MS_MAKE_TAG('l','a','t','n'), - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Numeric2, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_ENGLISH, 1, 0, 0, 0, ANSI_CHARSET, 0, 0, 0, 0, 0, 0, 1, 0, 0}, 0x00000000, @@ -623,7 +623,7 @@ const scriptData scriptInformation[] = { {{Script_Vietnamese_Currency, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_VIETNAMESE, 0, 0, 0, 0, VIETNAMESE_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, MS_MAKE_TAG('l','a','t','n'), - {0}}, + {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f',0}}, {{Script_Thai_Currency, 0, 0, 0, 0, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0}}, {LANG_THAI, 0, 1, 0, 0, THAI_CHARSET, 0, 0, 0, 0, 0, 0, 0, 0, 0}, MS_MAKE_TAG('t','h','a','i'),
1
0
0
0
Daniel Lehman : msvcp90: Use passed in beg to find the length in basic_string<>::replace.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 070479db58337f8af3c63b7ff47cb6b37ff7544a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=070479db58337f8af3c63b7ff…
Author: Daniel Lehman <dlehman(a)esri.com> Date: Thu Dec 29 16:41:29 2011 -0800 msvcp90: Use passed in beg to find the length in basic_string<>::replace. --- dlls/msvcp90/string.c | 22 +++++++++++----------- 1 files changed, 11 insertions(+), 11 deletions(-) diff --git a/dlls/msvcp90/string.c b/dlls/msvcp90/string.c index 27f3ab7..1479780 100644 --- a/dlls/msvcp90/string.c +++ b/dlls/msvcp90/string.c @@ -2079,7 +2079,7 @@ basic_string_char* __thiscall basic_string_char_replace_iter_bstr(basic_string_c { String_iterator_char begin = { this, basic_string_char_ptr(this) }; return basic_string_char_replace(this, MSVCP_basic_string_char_Pdif(beg, begin), - MSVCP_basic_string_char_Pdif(end, begin), str); + MSVCP_basic_string_char_Pdif(end, beg), str); } /* ?replace@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEAAV12@V?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@0ID@Z */ @@ -2090,7 +2090,7 @@ basic_string_char* __thiscall basic_string_char_replace_iter_ch(basic_string_cha { String_iterator_char begin = { this, basic_string_char_ptr(this) }; return basic_string_char_replace_ch(this, MSVCP_basic_string_char_Pdif(beg, begin), - MSVCP_basic_string_char_Pdif(end, begin), count, ch); + MSVCP_basic_string_char_Pdif(end, beg), count, ch); } /* ?replace@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEAAV12@V?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@0PBD1@Z */ @@ -2102,7 +2102,7 @@ basic_string_char* __thiscall basic_string_char_replace_iter_ptr_ptr(basic_strin { String_iterator_char begin = { this, basic_string_char_ptr(this) }; return basic_string_char_replace_cstr_len(this, MSVCP_basic_string_char_Pdif(beg, begin), - MSVCP_basic_string_char_Pdif(end, begin), res_beg, res_end-res_beg); + MSVCP_basic_string_char_Pdif(end, beg), res_beg, res_end-res_beg); } /* ?replace@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEAAV12@V?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@0PBD@Z */ @@ -2113,7 +2113,7 @@ basic_string_char* __thiscall basic_string_char_replace_iter_cstr(basic_string_c { String_iterator_char begin = { this, basic_string_char_ptr(this) }; return basic_string_char_replace_cstr(this, MSVCP_basic_string_char_Pdif(beg, begin), - MSVCP_basic_string_char_Pdif(end, begin), str); + MSVCP_basic_string_char_Pdif(end, beg), str); } /* ?replace@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEAAV12@V?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@0PBDI@Z */ @@ -2124,7 +2124,7 @@ basic_string_char* __thiscall basic_string_char_replace_iter_cstr_len(basic_stri { String_iterator_char begin = { this, basic_string_char_ptr(this) }; return basic_string_char_replace_cstr_len(this, MSVCP_basic_string_char_Pdif(beg, begin), - MSVCP_basic_string_char_Pdif(end, begin), str, len); + MSVCP_basic_string_char_Pdif(end, beg), str, len); } /* ?insert@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEAAV12@IABV12@@Z */ @@ -4034,7 +4034,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_iter(basic_string { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace_cstr_len(this, - MSVCP_basic_string_wchar_Pdif(beg, begin), MSVCP_basic_string_wchar_Pdif(end, begin), + MSVCP_basic_string_wchar_Pdif(beg, begin), MSVCP_basic_string_wchar_Pdif(end, beg), res_beg.pos, MSVCP_basic_string_wchar_Pdif(res_end, res_beg)); } @@ -4048,7 +4048,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_bstr(basic_string { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace(this, MSVCP_basic_string_wchar_Pdif(beg, begin), - MSVCP_basic_string_wchar_Pdif(end, begin), str); + MSVCP_basic_string_wchar_Pdif(end, beg), str); } /* ?replace@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEAAV12@V?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@0I_W@Z */ @@ -4061,7 +4061,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_ch(basic_string_w { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace_ch(this, MSVCP_basic_string_wchar_Pdif(beg, begin), - MSVCP_basic_string_wchar_Pdif(end, begin), count, ch); + MSVCP_basic_string_wchar_Pdif(end, beg), count, ch); } /* ?replace@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEAAV12@V?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@0PB_W1@Z */ @@ -4075,7 +4075,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_ptr_ptr(basic_str { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace_cstr_len(this, MSVCP_basic_string_wchar_Pdif(beg, begin), - MSVCP_basic_string_wchar_Pdif(end, begin), res_beg, res_end-res_beg); + MSVCP_basic_string_wchar_Pdif(end, beg), res_beg, res_end-res_beg); } /* ?replace@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEAAV12@V?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@0PB_W@Z */ @@ -4088,7 +4088,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_cstr(basic_string { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace_cstr(this, MSVCP_basic_string_wchar_Pdif(beg, begin), - MSVCP_basic_string_wchar_Pdif(end, begin), str); + MSVCP_basic_string_wchar_Pdif(end, beg), str); } /* ?replace@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEAAV12@V?$_String_const_iterator@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@0PB_WI@Z */ @@ -4101,7 +4101,7 @@ basic_string_wchar* __thiscall basic_string_wchar_replace_iter_cstr_len(basic_st { String_iterator_wchar begin = { this, basic_string_wchar_ptr(this) }; return basic_string_wchar_replace_cstr_len(this, MSVCP_basic_string_wchar_Pdif(beg, begin), - MSVCP_basic_string_wchar_Pdif(end, begin), str, len); + MSVCP_basic_string_wchar_Pdif(end, beg), str, len); } /* ?insert@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEAAV12@IABV12@@Z */
1
0
0
0
Jörg Höhle : mciseq: wNotifyDeviceID is redundant .
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 387b359a7eaf1115ac734d18d2f2e36806aba250 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=387b359a7eaf1115ac734d18d…
Author: Jörg Höhle <hoehle(a)users.sourceforge.net> Date: Wed Dec 15 22:56:08 2010 +0100 mciseq: wNotifyDeviceID is redundant. --- dlls/mciseq/mcimidi.c | 11 +++-------- 1 files changed, 3 insertions(+), 8 deletions(-) diff --git a/dlls/mciseq/mcimidi.c b/dlls/mciseq/mcimidi.c index e7671d6..2783c07 100644 --- a/dlls/mciseq/mcimidi.c +++ b/dlls/mciseq/mcimidi.c @@ -61,7 +61,6 @@ typedef struct tagWINE_MCIMIDI { UINT wDevID; /* the MCI one */ HMIDI hMidi; int nUseCount; /* Incremented for each shared open */ - MCIDEVICEID wNotifyDeviceID; /* MCI device ID with a pending notification */ HANDLE hCallback; /* Callback handle for pending notification */ HMMIO hFile; /* mmio file handle open as Element */ LPWSTR lpstrElementName; /* Name of file (if any) */ @@ -219,7 +218,7 @@ static void MIDI_mciNotify(DWORD_PTR hWndCallBack, WINE_MCIMIDI* wmm, UINT wStat /* We simply save one parameter by not passing the wDevID local * to the command. They are the same (via mciGetDriverData). */ - MCIDEVICEID wDevID = wmm->wNotifyDeviceID; + MCIDEVICEID wDevID = wmm->wDevID; HANDLE old = InterlockedExchangePointer(&wmm->hCallback, NULL); if (old) mciDriverNotify(old, wDevID, MCI_NOTIFY_SUPERSEDED); mciDriverNotify(HWND_32(LOWORD(hWndCallBack)), wDevID, wStatus); @@ -767,7 +766,6 @@ static DWORD MIDI_mciOpen(WINE_MCIMIDI* wmm, DWORD dwFlags, LPMCI_OPEN_PARMSW lp wmm->lpstrCopyright = NULL; wmm->lpstrName = NULL; - wmm->wNotifyDeviceID = wmm->wDevID; wmm->dwStatus = MCI_MODE_NOT_READY; /* while loading file contents */ /* spec says it should be the default format from the MIDI file... */ wmm->dwMciTimeFormat = MCI_FORMAT_MILLISECONDS; @@ -1563,11 +1561,8 @@ static DWORD MIDI_mciSeek(WINE_MCIMIDI* wmm, DWORD dwFlags, LPMCI_SEEK_PARMS lpP TRACE("Seeking to position=%u ms\n", wmm->dwPositionMS); - if (dwFlags & MCI_NOTIFY) { - TRACE("MCI_NOTIFY_SUCCESSFUL %08lX !\n", lpParms->dwCallback); - mciDriverNotify(HWND_32(LOWORD(lpParms->dwCallback)), - wmm->wNotifyDeviceID, MCI_NOTIFY_SUCCESSFUL); - } + if (dwFlags & MCI_NOTIFY) + MIDI_mciNotify(lpParms->dwCallback, wmm, MCI_NOTIFY_SUCCESSFUL); } return ret; }
1
0
0
0
Jörg Höhle : mciseq: Refactor use of mciGetDriverData.
by Alexandre Julliard
04 Jan '12
04 Jan '12
Module: wine Branch: master Commit: 3ae829d11b38d70244d8e0601e5b32a9313a44ae URL:
http://source.winehq.org/git/wine.git/?a=commit;h=3ae829d11b38d70244d8e0601…
Author: Jörg Höhle <hoehle(a)users.sourceforge.net> Date: Wed Dec 15 22:47:45 2010 +0100 mciseq: Refactor use of mciGetDriverData. --- dlls/mciseq/mcimidi.c | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/dlls/mciseq/mcimidi.c b/dlls/mciseq/mcimidi.c index e35abc5..e7671d6 100644 --- a/dlls/mciseq/mcimidi.c +++ b/dlls/mciseq/mcimidi.c @@ -196,11 +196,11 @@ static DWORD MIDI_drvClose(DWORD dwDevID) /************************************************************************** * MIDI_mciGetOpenDev [internal] */ -static WINE_MCIMIDI* MIDI_mciGetOpenDev(UINT wDevID) +static WINE_MCIMIDI* MIDI_mciGetOpenDev(MCIDEVICEID wDevID, UINT wMsg) { WINE_MCIMIDI* wmm = (WINE_MCIMIDI*)mciGetDriverData(wDevID); - if (wmm == NULL || wmm->nUseCount == 0) { + if (wmm == NULL || ((wmm->nUseCount == 0) ^ (wMsg == MCI_OPEN_DRIVER))) { WARN("Invalid wDevID=%u\n", wDevID); return 0; } @@ -1600,8 +1600,7 @@ LRESULT CALLBACK MCIMIDI_DriverProc(DWORD_PTR dwDevID, HDRVR hDriv, UINT wMsg, return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2); } - wmm = (wMsg == MCI_OPEN_DRIVER) ? - (WINE_MCIMIDI*)mciGetDriverData(dwDevID) : MIDI_mciGetOpenDev(dwDevID); + wmm = MIDI_mciGetOpenDev(dwDevID, wMsg); if (wmm == NULL) return MCIERR_INVALID_DEVICE_ID; switch (wMsg) {
1
0
0
0
← Newer
1
...
85
86
87
88
89
90
91
...
98
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
97
98
Results per page:
10
25
50
100
200