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 2011
----- 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
879 discussions
Start a n
N
ew thread
Vitaliy Margolen : dinput: Make newly created device append itself to Direct Input's list.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 9441d898f78189af4d61368d955f29417b01d0c3 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=9441d898f78189af4d61368d9…
Author: Vitaliy Margolen <wine-patches(a)kievinfo.com> Date: Tue Jan 18 21:06:37 2011 -0700 dinput: Make newly created device append itself to Direct Input's list. --- dlls/dinput/dinput_main.c | 14 -------------- dlls/dinput/joystick_linux.c | 4 ++++ dlls/dinput/joystick_linuxinput.c | 5 +++++ dlls/dinput/joystick_osx.c | 4 ++++ dlls/dinput/keyboard.c | 5 +++++ dlls/dinput/mouse.c | 5 +++++ 6 files changed, 23 insertions(+), 14 deletions(-) diff --git a/dlls/dinput/dinput_main.c b/dlls/dinput/dinput_main.c index 4eb52b3..59b81e8 100644 --- a/dlls/dinput/dinput_main.c +++ b/dlls/dinput/dinput_main.c @@ -506,14 +506,7 @@ static HRESULT WINAPI IDirectInput7AImpl_CreateDeviceEx(LPDIRECTINPUT7A iface, R if (!dinput_devices[i]->create_deviceA) continue; if ((ret = dinput_devices[i]->create_deviceA(This, rguid, riid, (LPDIRECTINPUTDEVICEA*) pvOut)) == DI_OK) - { - IDirectInputDeviceImpl *dev = impl_from_IDirectInputDevice8A(*pvOut); - - EnterCriticalSection( &This->crit ); - list_add_tail( &This->devices_list, &dev->entry ); - LeaveCriticalSection( &This->crit ); return DI_OK; - } if (ret == DIERR_NOINTERFACE) ret_value = DIERR_NOINTERFACE; @@ -544,14 +537,7 @@ static HRESULT WINAPI IDirectInput7WImpl_CreateDeviceEx(LPDIRECTINPUT7W iface, R if (!dinput_devices[i]->create_deviceW) continue; if ((ret = dinput_devices[i]->create_deviceW(This, rguid, riid, (LPDIRECTINPUTDEVICEW*) pvOut)) == DI_OK) - { - IDirectInputDeviceImpl *dev = impl_from_IDirectInputDevice8W(*pvOut); - - EnterCriticalSection( &This->crit ); - list_add_tail( &This->devices_list, &dev->entry ); - LeaveCriticalSection( &This->crit ); return DI_OK; - } if (ret == DIERR_NOINTERFACE) ret_value = DIERR_NOINTERFACE; diff --git a/dlls/dinput/joystick_linux.c b/dlls/dinput/joystick_linux.c index 736b16c..8348310 100644 --- a/dlls/dinput/joystick_linux.c +++ b/dlls/dinput/joystick_linux.c @@ -390,6 +390,10 @@ static HRESULT alloc_device(REFGUID rguid, IDirectInputImpl *dinput, IDirectInput_AddRef(&newDevice->generic.base.dinput->IDirectInput7A_iface); + EnterCriticalSection(&dinput->crit); + list_add_tail(&dinput->devices_list, &newDevice->generic.base.entry); + LeaveCriticalSection(&dinput->crit); + newDevice->generic.devcaps.dwSize = sizeof(newDevice->generic.devcaps); newDevice->generic.devcaps.dwFlags = DIDC_ATTACHED; if (newDevice->generic.base.dinput->dwVersion >= 0x0800) diff --git a/dlls/dinput/joystick_linuxinput.c b/dlls/dinput/joystick_linuxinput.c index 3d8ee19..088f419 100644 --- a/dlls/dinput/joystick_linuxinput.c +++ b/dlls/dinput/joystick_linuxinput.c @@ -525,6 +525,11 @@ static JoystickImpl *alloc_device(REFGUID rguid, IDirectInputImpl *dinput, unsig newDevice->generic.devcaps.dwFlags |= DIDC_FORCEFEEDBACK; IDirectInput_AddRef(&newDevice->generic.base.dinput->IDirectInput7A_iface); + + EnterCriticalSection(&dinput->crit); + list_add_tail(&dinput->devices_list, &newDevice->generic.base.entry); + LeaveCriticalSection(&dinput->crit); + return newDevice; failed: diff --git a/dlls/dinput/joystick_osx.c b/dlls/dinput/joystick_osx.c index 19ff6a3..2fa0bb9 100644 --- a/dlls/dinput/joystick_osx.c +++ b/dlls/dinput/joystick_osx.c @@ -821,6 +821,10 @@ static HRESULT alloc_device(REFGUID rguid, IDirectInputImpl *dinput, IDirectInput_AddRef(&newDevice->generic.base.dinput->IDirectInput7A_iface); + EnterCriticalSection(&dinput->crit); + list_add_tail(&dinput->devices_list, &newDevice->generic.base.entry); + LeaveCriticalSection(&dinput->crit); + newDevice->generic.devcaps.dwSize = sizeof(newDevice->generic.devcaps); newDevice->generic.devcaps.dwFlags = DIDC_ATTACHED; if (newDevice->generic.base.dinput->dwVersion >= 0x0800) diff --git a/dlls/dinput/keyboard.c b/dlls/dinput/keyboard.c index 6957662..f190677 100644 --- a/dlls/dinput/keyboard.c +++ b/dlls/dinput/keyboard.c @@ -255,6 +255,11 @@ static SysKeyboardImpl *alloc_device(REFGUID rguid, IDirectInputImpl *dinput) newDevice->base.data_format.wine_df = df; IDirectInput_AddRef(&newDevice->base.dinput->IDirectInput7A_iface); + + EnterCriticalSection(&dinput->crit); + list_add_tail(&dinput->devices_list, &newDevice->base.entry); + LeaveCriticalSection(&dinput->crit); + return newDevice; failed: diff --git a/dlls/dinput/mouse.c b/dlls/dinput/mouse.c index 0bdec82..2aa0574 100644 --- a/dlls/dinput/mouse.c +++ b/dlls/dinput/mouse.c @@ -242,6 +242,11 @@ static SysMouseImpl *alloc_device(REFGUID rguid, IDirectInputImpl *dinput) newDevice->base.data_format.wine_df = df; IDirectInput_AddRef(&newDevice->base.dinput->IDirectInput7A_iface); + + EnterCriticalSection(&dinput->crit); + list_add_tail(&dinput->devices_list, &newDevice->base.entry); + LeaveCriticalSection(&dinput->crit); + return newDevice; failed:
1
0
0
0
Eric Pouech : kernel32: Added support for insert/ overwrite modes while editing a line.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 2a219b948c451213fb4554352b86f3784a8f7e32 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=2a219b948c451213fb4554352…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 18 22:03:19 2011 +0100 kernel32: Added support for insert/overwrite modes while editing a line. --- dlls/kernel32/editline.c | 63 ++++++++++++++++++++++++++++++++++++++------- server/console.c | 3 +- 2 files changed, 55 insertions(+), 11 deletions(-) diff --git a/dlls/kernel32/editline.c b/dlls/kernel32/editline.c index dd93696..2f3cde6 100644 --- a/dlls/kernel32/editline.c +++ b/dlls/kernel32/editline.c @@ -67,6 +67,7 @@ typedef struct WCEL_Context { error : 1, /* to 1 when an error occurred in the editing */ can_wrap : 1, /* to 1 when multi-line edition can take place */ shall_echo : 1, /* to 1 when characters should be echo:ed when keyed-in */ + insert : 1, /* to 1 when new characters are inserted (otherwise overwrite) */ can_pos_cursor : 1; /* to 1 when console can (re)position cursor */ unsigned histSize; unsigned histPos; @@ -298,16 +299,29 @@ static void WCEL_DeleteString(WCEL_Context* ctx, int beg, int end) static void WCEL_InsertString(WCEL_Context* ctx, const WCHAR* str) { - size_t len = lstrlenW(str); + size_t len = lstrlenW(str), updtlen; - if (!len || !WCEL_Grow(ctx, len)) return; - if (ctx->len > ctx->ofs) - memmove(&ctx->line[ctx->ofs + len], &ctx->line[ctx->ofs], (ctx->len - ctx->ofs) * sizeof(WCHAR)); + if (!len) return; + if (ctx->insert) + { + if (!WCEL_Grow(ctx, len)) return; + if (ctx->len > ctx->ofs) + memmove(&ctx->line[ctx->ofs + len], &ctx->line[ctx->ofs], (ctx->len - ctx->ofs) * sizeof(WCHAR)); + ctx->len += len; + updtlen = ctx->len - ctx->ofs; + } + else + { + if (ctx->ofs + len > ctx->len) + { + if (!WCEL_Grow(ctx, (ctx->ofs + len) - ctx->len)) return; + ctx->len = ctx->ofs + len; + } + updtlen = len; + } memcpy(&ctx->line[ctx->ofs], str, len * sizeof(WCHAR)); - ctx->len += len; ctx->line[ctx->len] = 0; - WCEL_Update(ctx, ctx->ofs, ctx->len - ctx->ofs); - + WCEL_Update(ctx, ctx->ofs, updtlen); ctx->ofs += len; } @@ -738,6 +752,30 @@ static void WCEL_RepeatCount(WCEL_Context* ctx) #endif } +static void WCEL_ToggleInsert(WCEL_Context* ctx) +{ + DWORD mode; + CONSOLE_CURSOR_INFO cinfo; + + if (GetConsoleMode(ctx->hConIn, &mode) && GetConsoleCursorInfo(ctx->hConOut, &cinfo)) + { + if ((mode & (ENABLE_INSERT_MODE|ENABLE_EXTENDED_FLAGS)) == (ENABLE_INSERT_MODE|ENABLE_EXTENDED_FLAGS)) + { + mode &= ~ENABLE_INSERT_MODE; + cinfo.dwSize = 100; + ctx->insert = FALSE; + } + else + { + mode |= ENABLE_INSERT_MODE | ENABLE_EXTENDED_FLAGS; + cinfo.dwSize = 25; + ctx->insert = TRUE; + } + SetConsoleMode(ctx->hConIn, mode); + SetConsoleCursorInfo(ctx->hConOut, &cinfo); + } +} + /* ==================================================================== * * Key Maps @@ -750,6 +788,7 @@ static const KeyEntry StdKeyMap[] = {/*BACK*/0x08, WCEL_DeletePrevChar }, {/*RETURN*/0x0d, WCEL_Done }, {/*DEL*/127, WCEL_DeleteCurrChar }, + {/*VK_INSERT*/0x2d, WCEL_ToggleInsert }, { 0, NULL } }; @@ -834,6 +873,7 @@ static const KeyEntry Win32StdKeyMap[] = {/*VK_UP*/ 0x26, WCEL_MoveToPrevHist }, {/*VK_DOWN*/ 0x28, WCEL_MoveToNextHist }, {/*VK_DEL*/ 0x2e, WCEL_DeleteCurrChar }, + {/*VK_INSERT*/0x2d, WCEL_ToggleInsert }, {/*VK_F8*/ 0x77, WCEL_FindPrevInHist }, { 0, NULL } }; @@ -870,7 +910,7 @@ WCHAR* CONSOLE_Readline(HANDLE hConsoleIn, BOOL can_pos_cursor) const KeyEntry* ke; unsigned ofs; void (*func)(struct WCEL_Context* ctx); - DWORD ks; + DWORD mode, ks; int use_emacs; memset(&ctx, 0, sizeof(ctx)); @@ -884,8 +924,11 @@ WCHAR* CONSOLE_Readline(HANDLE hConsoleIn, BOOL can_pos_cursor) OPEN_EXISTING, 0, 0 )) == INVALID_HANDLE_VALUE || !GetConsoleScreenBufferInfo(ctx.hConOut, &ctx.csbi)) return NULL; - ctx.shall_echo = (GetConsoleMode(hConsoleIn, &ks) && (ks & ENABLE_ECHO_INPUT)) ? 1 : 0; - ctx.can_wrap = (GetConsoleMode(ctx.hConOut, &ks) && (ks & ENABLE_WRAP_AT_EOL_OUTPUT)) ? 1 : 0; + if (!GetConsoleMode(hConsoleIn, &mode)) mode = 0; + ctx.shall_echo = (mode & ENABLE_ECHO_INPUT) ? 1 : 0; + ctx.insert = (mode & (ENABLE_INSERT_MODE|ENABLE_EXTENDED_FLAGS)) == (ENABLE_INSERT_MODE|ENABLE_EXTENDED_FLAGS) ? 1 : 0; + if (!GetConsoleMode(ctx.hConOut, &mode)) mode = 0; + ctx.can_wrap = (mode & ENABLE_WRAP_AT_EOL_OUTPUT) ? 1 : 0; ctx.can_pos_cursor = can_pos_cursor; if (!WCEL_Grow(&ctx, 1)) diff --git a/server/console.c b/server/console.c index 42d985d..3f90937 100644 --- a/server/console.c +++ b/server/console.c @@ -302,7 +302,8 @@ static struct object *create_console_input( struct thread* renderer, int fd ) if (!(console_input = alloc_object( &console_input_ops ))) return NULL; console_input->renderer = renderer; console_input->mode = ENABLE_PROCESSED_INPUT | ENABLE_LINE_INPUT | - ENABLE_ECHO_INPUT | ENABLE_MOUSE_INPUT; + ENABLE_ECHO_INPUT | ENABLE_MOUSE_INPUT | ENABLE_INSERT_MODE | + ENABLE_EXTENDED_FLAGS; console_input->num_proc = 0; console_input->active = NULL; console_input->recnum = 0;
1
0
0
0
Eric Pouech : kernel32: Correctly parse the input strings for advanced keys .
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: a392e9a10262e5f9cfbb284d38e6174cb6f4809a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a392e9a10262e5f9cfbb284d3…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 18 22:02:37 2011 +0100 kernel32: Correctly parse the input strings for advanced keys. --- dlls/kernel32/console.c | 101 +++++++++++++++++++------- dlls/kernel32/console_private.h | 1 + dlls/kernel32/term.c | 149 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 223 insertions(+), 28 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=a392e9a10262e5f9cfbb2…
1
0
0
0
Eric Pouech : kernel32: Move the input character to INPUT_RECORD translation functions to term.c.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 46cd2994582a197510c343852bd5414cee00e6c9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=46cd2994582a197510c343852…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 18 22:02:31 2011 +0100 kernel32: Move the input character to INPUT_RECORD translation functions to term.c. --- dlls/kernel32/console.c | 113 +++------------------------------------ dlls/kernel32/console_private.h | 1 + dlls/kernel32/term.c | 103 +++++++++++++++++++++++++++++++++++ 3 files changed, 111 insertions(+), 106 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=46cd2994582a197510c34…
1
0
0
0
Eric Pouech : kernel32: Added support for terminfo/termcap in console code.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: ef3c46a9bf4e454e27e8f24b12a401b4af6e38cc URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ef3c46a9bf4e454e27e8f24b1…
Author: Eric Pouech <eric.pouech(a)orange.fr> Date: Tue Jan 18 22:02:24 2011 +0100 kernel32: Added support for terminfo/termcap in console code. --- dlls/kernel32/Makefile.in | 1 + dlls/kernel32/console.c | 2 + dlls/kernel32/console_private.h | 4 + dlls/kernel32/term.c | 117 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 124 insertions(+), 0 deletions(-) diff --git a/dlls/kernel32/Makefile.in b/dlls/kernel32/Makefile.in index 58a4497..9e03243 100644 --- a/dlls/kernel32/Makefile.in +++ b/dlls/kernel32/Makefile.in @@ -35,6 +35,7 @@ C_SRCS = \ string.c \ sync.c \ tape.c \ + term.c \ thread.c \ time.c \ toolhelp.c \ diff --git a/dlls/kernel32/console.c b/dlls/kernel32/console.c index f1bc3bc..1541858 100644 --- a/dlls/kernel32/console.c +++ b/dlls/kernel32/console.c @@ -216,6 +216,7 @@ static BOOL restore_console_mode(HANDLE hin) if ((fd = get_console_bare_fd(hin)) == -1) return FALSE; ret = tcsetattr(fd, TCSANOW, &S_termios) >= 0; close(fd); + TERM_Exit(); return ret; } @@ -3086,6 +3087,7 @@ BOOL CONSOLE_Init(RTL_USER_PROCESS_PARAMETERS *params) /* This is wine specific: we have no parent (we're started from unix) * so, create a simple console with bare handles */ + TERM_Init(); wine_server_send_fd(0); SERVER_START_REQ( alloc_console ) { diff --git a/dlls/kernel32/console_private.h b/dlls/kernel32/console_private.h index 06a8bd6..bb16d0b 100644 --- a/dlls/kernel32/console_private.h +++ b/dlls/kernel32/console_private.h @@ -33,4 +33,8 @@ extern BOOL CONSOLE_GetEditionMode(HANDLE, int*); /* editline.c */ extern WCHAR* CONSOLE_Readline(HANDLE, BOOL); +/* term.c */ +extern BOOL TERM_Init(void); +extern BOOL TERM_Exit(void); + #endif /* __WINE_CONSOLE_PRIVATE_H */ diff --git a/dlls/kernel32/term.c b/dlls/kernel32/term.c new file mode 100644 index 0000000..56ddd67 --- /dev/null +++ b/dlls/kernel32/term.c @@ -0,0 +1,117 @@ +/* + * Interface to terminfo and termcap libraries + * + * Copyright 2010 Eric Pouech + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" +#include "wine/port.h" + +#ifdef HAVE_NCURSES_H +# include <ncurses.h> +#elif defined(HAVE_CURSES_H) +# include <curses.h> +#endif +/* avoid redefinition warnings */ +#undef KEY_EVENT +#undef MOUSE_MOVED + +#include <term.h> + +#include <windef.h> +#include <winbase.h> +#include <winnls.h> +#include <wincon.h> +#include "console_private.h" +#include "wine/library.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(console); + +#if defined(SONAME_LIBCURSES) || defined(SONAME_LIBNCURSES) + +#ifdef HAVE_NCURSES_H +# define CURSES_NAME "ncurses" +#else +# define CURSES_NAME "curses" +#endif + +static void *nc_handle = NULL; + +#define MAKE_FUNCPTR(f) static typeof(f) * p_##f; + +MAKE_FUNCPTR(setupterm) + +#undef MAKE_FUNCPTR + +/**********************************************************************/ + +static BOOL TERM_bind_libcurses(void) +{ +#ifdef SONAME_LIBNCURSES + static const char ncname[] = SONAME_LIBNCURSES; +#else + static const char ncname[] = SONAME_LIBCURSES; +#endif + + if (!(nc_handle = wine_dlopen(ncname, RTLD_NOW, NULL, 0))) + { + WINE_MESSAGE("Wine cannot find the " CURSES_NAME " library (%s).\n", + ncname); + return FALSE; + } + +#define LOAD_FUNCPTR(f) \ + if((p_##f = wine_dlsym(nc_handle, #f, NULL, 0)) == NULL) \ + { \ + WINE_WARN("Can't find symbol %s\n", #f); \ + goto sym_not_found; \ + } + + LOAD_FUNCPTR(setupterm) + +#undef LOAD_FUNCPTR + + return TRUE; + +sym_not_found: + WINE_MESSAGE( + "Wine cannot find certain functions that it needs inside the " + CURSES_NAME "\nlibrary. To enable Wine to use " CURSES_NAME + " please upgrade your " CURSES_NAME "\nlibraries\n"); + wine_dlclose(nc_handle, NULL, 0); + nc_handle = NULL; + return FALSE; +} + +#define setupterm p_setupterm + +BOOL TERM_Init(void) +{ + if (!TERM_bind_libcurses()) return FALSE; + if (setupterm(NULL, 1 /* really ?? */, NULL) == -1) return FALSE; + return TRUE; +} + +BOOL TERM_Exit(void) +{ + return TRUE; +} +#else +BOOL TERM_Init(void) {return FALSE;} +BOOL TERM_Exit(void) {return FALSE;} +#endif
1
0
0
0
Hans Leidekker : msi: Downgrade a warning.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 3ada9f2c082bc1927fea3f08c59724568ac1b246 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=3ada9f2c082bc1927fea3f08c…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Wed Jan 19 12:05:52 2011 +0100 msi: Downgrade a warning. Unreferenced files are normal when applying a patch. --- dlls/msi/files.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/msi/files.c b/dlls/msi/files.c index 9d0e01a..1205690 100644 --- a/dlls/msi/files.c +++ b/dlls/msi/files.c @@ -187,7 +187,7 @@ static BOOL installfiles_cb(MSIPACKAGE *package, LPCWSTR file, DWORD action, f = get_loaded_file(package, file); if (!f) { - WARN("unknown file in cabinet (%s)\n", debugstr_w(file)); + TRACE("unknown file in cabinet (%s)\n", debugstr_w(file)); return FALSE; }
1
0
0
0
Hans Leidekker : msi: Don' t ignore disabled components when resolving install states.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 34b9e4c20f1998320a6604e201f4bd09399352c9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=34b9e4c20f1998320a6604e20…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Wed Jan 19 12:05:31 2011 +0100 msi: Don't ignore disabled components when resolving install states. Otherwise features are not published correctly. --- dlls/msi/action.c | 11 +---------- 1 files changed, 1 insertions(+), 10 deletions(-) diff --git a/dlls/msi/action.c b/dlls/msi/action.c index 725ea2f..8cf80bf 100644 --- a/dlls/msi/action.c +++ b/dlls/msi/action.c @@ -1841,8 +1841,7 @@ static void ACTION_GetComponentInstallStates(MSIPACKAGE *package) LIST_FOR_EACH_ENTRY(comp, &package->components, MSICOMPONENT, entry) { - if (!comp->Enabled || !comp->ComponentId) - continue; + if (!comp->ComponentId) continue; if (state != INSTALLSTATE_LOCAL && state != INSTALLSTATE_DEFAULT) comp->Installed = INSTALLSTATE_ABSENT; @@ -2037,8 +2036,6 @@ UINT MSI_SetFeatureStates(MSIPACKAGE *package) /* features with components that have compressed files are made local */ LIST_FOR_EACH_ENTRY( cl, &feature->Components, ComponentList, entry ) { - if (!cl->component->Enabled) continue; - if (cl->component->ForceLocalState && feature->ActionRequest == INSTALLSTATE_SOURCE) { @@ -2051,8 +2048,6 @@ UINT MSI_SetFeatureStates(MSIPACKAGE *package) { component = cl->component; - if (!component->Enabled) continue; - switch (feature->ActionRequest) { case INSTALLSTATE_ABSENT: @@ -2083,8 +2078,6 @@ UINT MSI_SetFeatureStates(MSIPACKAGE *package) LIST_FOR_EACH_ENTRY( component, &package->components, MSICOMPONENT, entry ) { - if (!component->Enabled) continue; - /* check if it's local or source */ if (!(component->Attributes & msidbComponentAttributesOptional) && (component->hasLocalFeature || component->hasSourceFeature)) @@ -2123,8 +2116,6 @@ UINT MSI_SetFeatureStates(MSIPACKAGE *package) LIST_FOR_EACH_ENTRY( component, &package->components, MSICOMPONENT, entry ) { - if (!component->Enabled) continue; - if (component->ActionRequest == INSTALLSTATE_DEFAULT) { TRACE("%s was default, setting to local\n", debugstr_w(component->Component));
1
0
0
0
Juan Lang : crypt32: Remove no-ops.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: a9efbf892602968d313b7967ac411c4e6fb2e679 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a9efbf892602968d313b7967a…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Tue Jan 18 19:19:13 2011 -0800 crypt32: Remove no-ops. --- dlls/crypt32/encode.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/dlls/crypt32/encode.c b/dlls/crypt32/encode.c index a1db6d9..e14ff19 100644 --- a/dlls/crypt32/encode.c +++ b/dlls/crypt32/encode.c @@ -354,7 +354,6 @@ static BOOL WINAPI CRYPT_CopyEncodedBlob(DWORD dwCertEncodingType, if (blob->cbData) memcpy(pbEncoded, blob->pbData, blob->cbData); *pcbEncoded = blob->cbData; - ret = TRUE; } } return ret; @@ -1221,7 +1220,7 @@ static BOOL WINAPI CRYPT_DEREncodeSet(DWORD dwCertEncodingType, *pbEncoded++ = ASN_CONSTRUCTOR | ASN_SETOF; CRYPT_EncodeLen(bytesNeeded - lenBytes - 1, pbEncoded, &lenBytes); pbEncoded += lenBytes; - for (i = 0; ret && i < set->cBlob; i++) + for (i = 0; i < set->cBlob; i++) { memcpy(pbEncoded, set->rgBlob[i].pbData, set->rgBlob[i].cbData); pbEncoded += set->rgBlob[i].cbData;
1
0
0
0
Juan Lang : crypt32: Fix memory leaks when encoding fails.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 687e29b9125633f9fa3c08ed26b94153f8d0cfe4 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=687e29b9125633f9fa3c08ed2…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Tue Jan 18 19:17:46 2011 -0800 crypt32: Fix memory leaks when encoding fails. --- dlls/crypt32/encode.c | 264 +++++++++++++++++++++++++++++++------------------ 1 files changed, 167 insertions(+), 97 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=687e29b9125633f9fa3c0…
1
0
0
0
Michael Stefaniuc : ddraw: COM cleanup for the IDirectDraw7 iface.
by Alexandre Julliard
19 Jan '11
19 Jan '11
Module: wine Branch: master Commit: 97451080964a50c1ed14ae6656e2bf61c222ba3d URL:
http://source.winehq.org/git/wine.git/?a=commit;h=97451080964a50c1ed14ae665…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Wed Jan 19 01:42:43 2011 +0100 ddraw: COM cleanup for the IDirectDraw7 iface. --- dlls/ddraw/ddraw.c | 289 +++++++++++++++++++++++--------------------- dlls/ddraw/ddraw_private.h | 4 +- dlls/ddraw/device.c | 2 +- dlls/ddraw/main.c | 12 +- dlls/ddraw/palette.c | 2 +- dlls/ddraw/surface.c | 2 +- 6 files changed, 160 insertions(+), 151 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=97451080964a50c1ed14a…
1
0
0
0
← Newer
1
...
30
31
32
33
34
35
36
...
88
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
Results per page:
10
25
50
100
200