ReactOS.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
2024
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
List overview
Download
Ros-diffs
June 2013
----- 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
ros-diffs@reactos.org
14 participants
274 discussions
Start a n
N
ew thread
[ekohl] 59214: [SYSDM] Fix a typo that was found by cppcheck.
by ekohl@svn.reactos.org
Author: ekohl Date: Fri Jun 14 16:12:15 2013 New Revision: 59214 URL:
http://svn.reactos.org/svn/reactos?rev=59214&view=rev
Log: [SYSDM] Fix a typo that was found by cppcheck. Modified: trunk/reactos/dll/cpl/sysdm/virtmem.c Modified: trunk/reactos/dll/cpl/sysdm/virtmem.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/sysdm/virtmem.c?re…
============================================================================== --- trunk/reactos/dll/cpl/sysdm/virtmem.c [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/sysdm/virtmem.c [iso-8859-1] Fri Jun 14 16:12:15 2013 @@ -624,7 +624,7 @@ return TRUE; case IDC_PAGEFILELIST: - switch HIWORD(wParam) + switch (HIWORD(wParam)) { case LBN_SELCHANGE: OnSelChange(hwndDlg, pVirtMem);
11 years, 3 months
1
0
0
0
[spetreolle] 59213: [DEVMGR] Fix exceptions occuring because of missing parameters.
by spetreolle@svn.reactos.org
Author: spetreolle Date: Fri Jun 14 09:11:25 2013 New Revision: 59213 URL:
http://svn.reactos.org/svn/reactos?rev=59213&view=rev
Log: [DEVMGR] Fix exceptions occuring because of missing parameters. Modified: trunk/reactos/dll/win32/devmgr/devprblm.c Modified: trunk/reactos/dll/win32/devmgr/devprblm.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/devmgr/devprblm.…
============================================================================== --- trunk/reactos/dll/win32/devmgr/devprblm.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/devmgr/devprblm.c [iso-8859-1] Fri Jun 14 09:11:25 2013 @@ -505,7 +505,7 @@ } else { - LPWSTR szProblem, szInfo = NULL; + LPWSTR szProblem, szInfo = L"FIXME"; DWORD dwRet; BOOL AdvFormat = FALSE; UINT StringIDs[] = @@ -521,7 +521,7 @@ /* FIXME - if not a root bus devloader then use IDS_DEV_DEVLOADER_FAILED2 */ /* FIXME - get the type string (ie. ISAPNP, PCI or BIOS for root bus devloaders, or FLOP, ESDI, SCSI, etc for others */ - AdvFormat = (szInfo != NULL); + AdvFormat = TRUE; break; } @@ -538,7 +538,7 @@ - use IDS_DEV_DEVLOADER_NOT_FOUND3 - AdvFormat = FALSE! */ - AdvFormat = (szInfo != NULL); + AdvFormat = TRUE; break; } @@ -549,12 +549,12 @@ case CM_PROB_NORMAL_CONFLICT: /* FIXME - get resource type (IRQ, DMA, Memory or I/O) */ - AdvFormat = (szInfo != NULL); + AdvFormat = TRUE; break; case CM_PROB_UNKNOWN_RESOURCE: /* FIXME - get the .inf file name */ - AdvFormat = (szInfo != NULL); + AdvFormat = TRUE; break; case CM_PROB_DISABLED: @@ -563,7 +563,7 @@ case CM_PROB_FAILED_ADD: /* FIXME - get the name of the sub-device with the error */ - AdvFormat = (szInfo != NULL); + AdvFormat = TRUE; break; }
11 years, 3 months
1
0
0
0
[hbelusca] 59212: [CONSRV] - Use a Unicode screen-buffer for the console. - Fix some pointers miscalculations in Read/Write console output routines, which lead to character display problems sometim...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Fri Jun 14 01:10:43 2013 New Revision: 59212 URL:
http://svn.reactos.org/svn/reactos?rev=59212&view=rev
Log: [CONSRV] - Use a Unicode screen-buffer for the console. - Fix some pointers miscalculations in Read/Write console output routines, which lead to character display problems sometimes. CORE-7277 #resolve #comment Should be fixed in revision r59212. Thanks for your report :) Modified: trunk/reactos/win32ss/user/consrv/coninput.c trunk/reactos/win32ss/user/consrv/frontends/gui/guiterm.c trunk/reactos/win32ss/user/consrv/frontends/gui/text.c trunk/reactos/win32ss/user/consrv/frontends/tui/tuiterm.c trunk/reactos/win32ss/user/consrv/include/conio.h trunk/reactos/win32ss/user/consrv/lineinput.c trunk/reactos/win32ss/user/consrv/text.c Modified: trunk/reactos/win32ss/user/consrv/coninput.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/coninp…
============================================================================== --- trunk/reactos/win32ss/user/consrv/coninput.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/coninput.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -99,7 +99,7 @@ } } - /* add event to the queue */ + /* Add event to the queue */ ConInRec = ConsoleAllocHeap(0, sizeof(ConsoleInput)); if (ConInRec == NULL) return STATUS_INSUFFICIENT_RESOURCES; Modified: trunk/reactos/win32ss/user/consrv/frontends/gui/guiterm.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/fronte…
============================================================================== --- trunk/reactos/win32ss/user/consrv/frontends/gui/guiterm.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/frontends/gui/guiterm.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -744,8 +744,6 @@ { PCONSOLE Console = GuiData->Console; PCONSOLE_SCREEN_BUFFER ActiveBuffer; - MSG Message; - WORD VirtualKeyCode = LOWORD(wParam); if (!ConSrvValidateConsoleUnsafe(Console, CONSOLE_RUNNING, TRUE)) return; @@ -753,6 +751,8 @@ if (Console->Selection.dwFlags & CONSOLE_SELECTION_IN_PROGRESS) { + WORD VirtualKeyCode = LOWORD(wParam); + if (msg != WM_KEYDOWN) goto Quit; if (VirtualKeyCode == VK_RETURN) @@ -767,12 +767,13 @@ /* Cancel selection if ESC or Ctrl-C are pressed */ GuiConsoleUpdateSelection(Console, NULL); SetWindowText(GuiData->hWindow, Console->Title.Buffer); + goto Quit; } if ((Console->Selection.dwFlags & CONSOLE_MOUSE_SELECTION) == 0) { - /* Selection mode with keyboard */ + /* Keyboard selection mode */ BOOL Interpreted = FALSE; BOOL MajPressed = (GetKeyState(VK_SHIFT) & 0x8000); @@ -865,20 +866,30 @@ /* Emit an error beep sound */ SendNotifyMessage(GuiData->hWindow, PM_CONSOLE_BEEP, 0, 0); } + + goto Quit; } else { - /* Selection mode with mouse, clear the selection if needed */ + /* Mouse selection mode */ + if (!IsSystemKey(VirtualKeyCode)) { + /* Clear the selection and send the key into the input buffer */ GuiConsoleUpdateSelection(Console, NULL); SetWindowText(GuiData->hWindow, Console->Title.Buffer); } + else + { + goto Quit; + } } } if ((Console->Selection.dwFlags & CONSOLE_SELECTION_IN_PROGRESS) == 0) { + MSG Message; + Message.hwnd = GuiData->hWindow; Message.message = msg; Message.wParam = wParam; @@ -2247,7 +2258,7 @@ static VOID WINAPI GuiWriteStream(PCONSOLE Console, SMALL_RECT* Region, SHORT CursorStartX, SHORT CursorStartY, - UINT ScrolledLines, CHAR *Buffer, UINT Length) + UINT ScrolledLines, PWCHAR Buffer, UINT Length) { PGUI_CONSOLE_DATA GuiData = Console->TermIFace.Data; PCONSOLE_SCREEN_BUFFER Buff = Console->ActiveBuffer; Modified: trunk/reactos/win32ss/user/consrv/frontends/gui/text.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/fronte…
============================================================================== --- trunk/reactos/win32ss/user/consrv/frontends/gui/text.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/frontends/gui/text.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -20,13 +20,6 @@ #include <debug.h> -/* GLOBALS ********************************************************************/ - -/* Copied from consrv/text.c */ -#define ConsoleAnsiCharToUnicodeChar(Console, dWChar, sChar) \ - MultiByteToWideChar((Console)->OutputCodePage, 0, (sChar), 1, (dWChar), 1) - - /* FUNCTIONS ******************************************************************/ VOID @@ -45,7 +38,7 @@ BOOL InlineCopyMode = (GetKeyState(VK_SHIFT) & 0x8000); HANDLE hData; - PBYTE ptr; + PCHAR_INFO ptr; LPWSTR data, dstPos; ULONG selWidth, selHeight; ULONG xPos, yPos, size; @@ -90,7 +83,7 @@ /* Copy only the characters, leave attributes alone */ for (xPos = 0; xPos < selWidth; xPos++) { - ConsoleAnsiCharToUnicodeChar(Console, &dstPos[xPos], (LPCSTR)&ptr[xPos * 2]); + dstPos[xPos] = ptr[xPos].Char.UnicodeChar; } dstPos += selWidth; @@ -192,9 +185,9 @@ ULONG TopLine, BottomLine, LeftChar, RightChar; ULONG Line, Char, Start; - PBYTE From; + PCHAR_INFO From; PWCHAR To; - BYTE LastAttribute, Attribute; + WORD LastAttribute, Attribute; ULONG CursorX, CursorY, CursorHeight; HBRUSH CursorBrush, OldBrush; HFONT OldFont; @@ -205,35 +198,40 @@ BottomLine = (rc->bottom + (GuiData->CharHeight - 1)) / GuiData->CharHeight - 1 + Buffer->ViewOrigin.Y; LeftChar = rc->left / GuiData->CharWidth + Buffer->ViewOrigin.X; RightChar = (rc->right + (GuiData->CharWidth - 1)) / GuiData->CharWidth - 1 + Buffer->ViewOrigin.X; - LastAttribute = ConioCoordToPointer(Buffer, LeftChar, TopLine)[1]; + + LastAttribute = ConioCoordToPointer(Buffer, LeftChar, TopLine)->Attributes; SetTextColor(hDC, RGBFromAttrib(Console, TextAttribFromAttrib(LastAttribute))); SetBkColor(hDC, RGBFromAttrib(Console, BkgdAttribFromAttrib(LastAttribute))); if (BottomLine >= Buffer->ScreenBufferSize.Y) BottomLine = Buffer->ScreenBufferSize.Y - 1; - if (RightChar >= Buffer->ScreenBufferSize.X) RightChar = Buffer->ScreenBufferSize.X - 1; + if (RightChar >= Buffer->ScreenBufferSize.X) RightChar = Buffer->ScreenBufferSize.X - 1; OldFont = SelectObject(hDC, GuiData->Font); for (Line = TopLine; Line <= BottomLine; Line++) { - WCHAR LineBuffer[80]; - From = ConioCoordToPointer(Buffer, LeftChar, Line); + WCHAR LineBuffer[80]; // Buffer containing a part or all the line to be displayed + From = ConioCoordToPointer(Buffer, LeftChar, Line); // Get the first code of the line Start = LeftChar; - To = LineBuffer; + To = LineBuffer; for (Char = LeftChar; Char <= RightChar; Char++) { - if (*(From + 1) != LastAttribute || (Char - Start == sizeof(LineBuffer) / sizeof(WCHAR))) + /* + * We flush the buffer if the new attribute is different + * from the current one, or if the buffer is full. + */ + if (From->Attributes != LastAttribute || (Char - Start == sizeof(LineBuffer) / sizeof(WCHAR))) { TextOutW(hDC, - (Start - Buffer->ViewOrigin.X) * GuiData->CharWidth, - (Line - Buffer->ViewOrigin.Y) * GuiData->CharHeight, + (Start - Buffer->ViewOrigin.X) * GuiData->CharWidth , + (Line - Buffer->ViewOrigin.Y) * GuiData->CharHeight, LineBuffer, Char - Start); Start = Char; - To = LineBuffer; - Attribute = *(From + 1); + To = LineBuffer; + Attribute = From->Attributes; if (Attribute != LastAttribute) { SetTextColor(hDC, RGBFromAttrib(Console, TextAttribFromAttrib(Attribute))); @@ -242,15 +240,12 @@ } } - MultiByteToWideChar(Console->OutputCodePage, - 0, (PCHAR)From, 1, To, 1); - To++; - From += 2; + *(To++) = (From++)->Char.UnicodeChar; } TextOutW(hDC, - (Start - Buffer->ViewOrigin.X) * GuiData->CharWidth, - (Line - Buffer->ViewOrigin.Y) * GuiData->CharHeight, + (Start - Buffer->ViewOrigin.X) * GuiData->CharWidth , + (Line - Buffer->ViewOrigin.Y) * GuiData->CharHeight, LineBuffer, RightChar - Start + 1); } @@ -268,11 +263,11 @@ TopLine <= CursorY && CursorY <= BottomLine) { CursorHeight = ConioEffectiveCursorSize(Console, GuiData->CharHeight); - From = ConioCoordToPointer(Buffer, Buffer->CursorPosition.X, Buffer->CursorPosition.Y) + 1; - - if (*From != DEFAULT_SCREEN_ATTRIB) - { - CursorBrush = CreateSolidBrush(RGBFromAttrib(Console, *From)); + Attribute = ConioCoordToPointer(Buffer, Buffer->CursorPosition.X, Buffer->CursorPosition.Y)->Attributes; + + if (Attribute != DEFAULT_SCREEN_ATTRIB) + { + CursorBrush = CreateSolidBrush(RGBFromAttrib(Console, Attribute)); } else { Modified: trunk/reactos/win32ss/user/consrv/frontends/tui/tuiterm.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/fronte…
============================================================================== --- trunk/reactos/win32ss/user/consrv/frontends/tui/tuiterm.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/frontends/tui/tuiterm.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -230,23 +230,25 @@ } static VOID FASTCALL -TuiCopyRect(char *Dest, PTEXTMODE_SCREEN_BUFFER Buff, SMALL_RECT* Region) +TuiCopyRect(PCHAR Dest, PTEXTMODE_SCREEN_BUFFER Buff, SMALL_RECT* Region) { UINT SrcDelta, DestDelta; LONG i; - PBYTE Src, SrcEnd; + PCHAR_INFO Src, SrcEnd; Src = ConioCoordToPointer(Buff, Region->Left, Region->Top); - SrcDelta = Buff->ScreenBufferSize.X * 2; - SrcEnd = Buff->Buffer + Buff->ScreenBufferSize.Y * Buff->ScreenBufferSize.X * 2; - DestDelta = ConioRectWidth(Region) * 2; + SrcDelta = Buff->ScreenBufferSize.X * sizeof(CHAR_INFO); + SrcEnd = Buff->Buffer + Buff->ScreenBufferSize.Y * Buff->ScreenBufferSize.X * sizeof(CHAR_INFO); + DestDelta = ConioRectWidth(Region) * 2 /* 2 == sizeof(CHAR) + sizeof(BYTE) */; for (i = Region->Top; i <= Region->Bottom; i++) { - memcpy(Dest, Src, DestDelta); + ConsoleUnicodeCharToAnsiChar(Buff->Header.Console, (PCHAR)Dest, &Src->Char.UnicodeChar); + *(PBYTE)(Dest + 1) = (BYTE)Src->Attributes; + Src += SrcDelta; if (SrcEnd <= Src) { - Src -= Buff->ScreenBufferSize.Y * Buff->ScreenBufferSize.X * 2; + Src -= Buff->ScreenBufferSize.Y * Buff->ScreenBufferSize.X * sizeof(CHAR_INFO); } Dest += DestDelta; } @@ -501,7 +503,7 @@ ConsoleDraw->CursorX = Buff->CursorPosition.X; ConsoleDraw->CursorY = Buff->CursorPosition.Y; - TuiCopyRect((char*)(ConsoleDraw + 1), (PTEXTMODE_SCREEN_BUFFER)Buff, Region); + TuiCopyRect((PCHAR)(ConsoleDraw + 1), (PTEXTMODE_SCREEN_BUFFER)Buff, Region); if (!DeviceIoControl(ConsoleDeviceHandle, IOCTL_CONSOLE_DRAW, NULL, 0, ConsoleDraw, ConsoleDrawSize, &BytesReturned, NULL)) @@ -516,17 +518,31 @@ static VOID WINAPI TuiWriteStream(PCONSOLE Console, SMALL_RECT* Region, SHORT CursorStartX, SHORT CursorStartY, - UINT ScrolledLines, CHAR *Buffer, UINT Length) -{ + UINT ScrolledLines, PWCHAR Buffer, UINT Length) +{ + PCONSOLE_SCREEN_BUFFER Buff = Console->ActiveBuffer; + PCHAR NewBuffer; + ULONG NewLength; DWORD BytesWritten; - PCONSOLE_SCREEN_BUFFER Buff = Console->ActiveBuffer; if (ActiveConsole->Console->ActiveBuffer != Buff) return; - if (!WriteFile(ConsoleDeviceHandle, Buffer, Length, &BytesWritten, NULL)) + NewLength = WideCharToMultiByte(Console->OutputCodePage, 0, + Buffer, Length, + NULL, 0, NULL, NULL); + NewBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, NewLength * sizeof(CHAR)); + if (!NewBuffer) return; + + WideCharToMultiByte(Console->OutputCodePage, 0, + Buffer, Length, + NewBuffer, NewLength, NULL, NULL); + + if (!WriteFile(ConsoleDeviceHandle, NewBuffer, NewLength * sizeof(CHAR), &BytesWritten, NULL)) { DPRINT1("Error writing to BlueScreen\n"); } + + RtlFreeHeap(RtlGetProcessHeap(), 0, NewBuffer); } static BOOL WINAPI Modified: trunk/reactos/win32ss/user/consrv/include/conio.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/includ…
============================================================================== --- trunk/reactos/win32ss/user/consrv/include/conio.h [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/include/conio.h [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -126,12 +126,12 @@ typedef struct _TEXTMODE_SCREEN_BUFFER { - CONSOLE_SCREEN_BUFFER; /* Screen buffer base class - MUST BE IN FIRST PLACE */ - - BYTE *Buffer; /* CHAR_INFO */ /* Pointer to screen buffer */ - - WORD ScreenDefaultAttrib; /* Default screen char attribute */ - WORD PopupDefaultAttrib; /* Default popup char attribute */ + CONSOLE_SCREEN_BUFFER; /* Screen buffer base class - MUST BE IN FIRST PLACE */ + + PCHAR_INFO Buffer; /* Pointer to UNICODE screen buffer (Buffer->Char.UnicodeChar only is valid, not Char.AsciiChar) */ + + WORD ScreenDefaultAttrib; /* Default screen char attribute */ + WORD PopupDefaultAttrib; /* Default popup char attribute */ } TEXTMODE_SCREEN_BUFFER, *PTEXTMODE_SCREEN_BUFFER; @@ -189,7 +189,7 @@ SHORT CursorStartX, SHORT CursorStartY, UINT ScrolledLines, - CHAR *Buffer, + PWCHAR Buffer, UINT Length); BOOL (WINAPI *SetCursorInfo)(struct _CONSOLE* Console, PCONSOLE_SCREEN_BUFFER ScreenBuffer); @@ -286,7 +286,6 @@ BOOLEAN QuickEdit; BOOLEAN InsertMode; UINT CodePage; - UINT OutputCodePage; CONSOLE_SELECTION_INFO Selection; /* Contains information about the selection */ COORD dwSelectionCursor; /* Selection cursor position, most of the time different from Selection.dwSelectionAnchor */ @@ -297,6 +296,7 @@ BYTE PauseFlags; HANDLE UnpauseEvent; LIST_ENTRY WriteWaitQueue; /* List head for the queue of write wait blocks */ + UINT OutputCodePage; /**************************** Aliases and Histories ***************************/ struct _ALIAS_HEADER *Aliases; @@ -348,14 +348,20 @@ #define ConioRectWidth(Rect) \ (((Rect)->Left) > ((Rect)->Right) ? 0 : ((Rect)->Right) - ((Rect)->Left) + 1) -PBYTE ConioCoordToPointer(PTEXTMODE_SCREEN_BUFFER Buff, ULONG X, ULONG Y); +#define ConsoleUnicodeCharToAnsiChar(Console, dChar, sWChar) \ + WideCharToMultiByte((Console)->OutputCodePage, 0, (sWChar), 1, (dChar), 1, NULL, NULL) + +#define ConsoleAnsiCharToUnicodeChar(Console, dWChar, sChar) \ + MultiByteToWideChar((Console)->OutputCodePage, 0, (sChar), 1, (dWChar), 1) + +PCHAR_INFO ConioCoordToPointer(PTEXTMODE_SCREEN_BUFFER Buff, ULONG X, ULONG Y); VOID FASTCALL ConioDrawConsole(PCONSOLE Console); NTSTATUS ConioResizeBuffer(PCONSOLE Console, PTEXTMODE_SCREEN_BUFFER ScreenBuffer, COORD Size); NTSTATUS ConioWriteConsole(PCONSOLE Console, PTEXTMODE_SCREEN_BUFFER Buff, - CHAR *Buffer, + PWCHAR Buffer, DWORD Length, BOOL Attrib); DWORD FASTCALL ConioEffectiveCursorSize(PCONSOLE Console, Modified: trunk/reactos/win32ss/user/consrv/lineinput.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/linein…
============================================================================== --- trunk/reactos/win32ss/user/consrv/lineinput.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/lineinput.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -214,15 +214,11 @@ { for (i = Pos; i < NewSize; i++) { - CHAR AsciiChar; - WideCharToMultiByte(Console->OutputCodePage, 0, - &Console->LineBuffer[i], 1, - &AsciiChar, 1, NULL, NULL); - ConioWriteConsole(Console, ActiveBuffer, &AsciiChar, 1, TRUE); + ConioWriteConsole(Console, ActiveBuffer, &Console->LineBuffer[i], 1, TRUE); } for (; i < Console->LineSize; i++) { - ConioWriteConsole(Console, ActiveBuffer, " ", 1, TRUE); + ConioWriteConsole(Console, ActiveBuffer, L" ", 1, TRUE); } Console->LinePos = i; } @@ -413,7 +409,7 @@ { if (GetType(Console->ActiveBuffer) == TEXTMODE_BUFFER) { - ConioWriteConsole(Console, (PTEXTMODE_SCREEN_BUFFER)(Console->ActiveBuffer), "\r", 1, TRUE); + ConioWriteConsole(Console, (PTEXTMODE_SCREEN_BUFFER)(Console->ActiveBuffer), L"\r", 1, TRUE); } } @@ -428,7 +424,7 @@ { if (GetType(Console->ActiveBuffer) == TEXTMODE_BUFFER) { - ConioWriteConsole(Console, (PTEXTMODE_SCREEN_BUFFER)(Console->ActiveBuffer), "\n", 1, TRUE); + ConioWriteConsole(Console, (PTEXTMODE_SCREEN_BUFFER)(Console->ActiveBuffer), L"\n", 1, TRUE); } } } Modified: trunk/reactos/win32ss/user/consrv/text.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/consrv/text.c…
============================================================================== --- trunk/reactos/win32ss/user/consrv/text.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/consrv/text.c [iso-8859-1] Fri Jun 14 01:10:43 2013 @@ -29,12 +29,6 @@ #define TAB_WIDTH 8 -#define ConsoleUnicodeCharToAnsiChar(Console, dChar, sWChar) \ - WideCharToMultiByte((Console)->OutputCodePage, 0, (sWChar), 1, (dChar), 1, NULL, NULL) - -#define ConsoleAnsiCharToUnicodeChar(Console, dWChar, sChar) \ - MultiByteToWideChar((Console)->OutputCodePage, 0, (sChar), 1, (dWChar), 1) - /* PRIVATE FUNCTIONS **********************************************************/ @@ -84,8 +78,9 @@ NewBuffer->Vtbl = &TextVtbl; NewBuffer->Buffer = ConsoleAllocHeap(HEAP_ZERO_MEMORY, - 2 * TextModeInfo->ScreenBufferSize.X - * TextModeInfo->ScreenBufferSize.Y); + TextModeInfo->ScreenBufferSize.X * + TextModeInfo->ScreenBufferSize.Y * + sizeof(CHAR_INFO)); if (NewBuffer->Buffer == NULL) { CONSOLE_SCREEN_BUFFER_Destroy((PCONSOLE_SCREEN_BUFFER)NewBuffer); @@ -137,23 +132,23 @@ } -PBYTE +PCHAR_INFO ConioCoordToPointer(PTEXTMODE_SCREEN_BUFFER Buff, ULONG X, ULONG Y) { - return &Buff->Buffer[2 * (((Y + Buff->VirtualY) % Buff->ScreenBufferSize.Y) * Buff->ScreenBufferSize.X + X)]; + return &Buff->Buffer[((Y + Buff->VirtualY) % Buff->ScreenBufferSize.Y) * Buff->ScreenBufferSize.X + X]; } static VOID FASTCALL ClearLineBuffer(PTEXTMODE_SCREEN_BUFFER Buff) { - PBYTE Ptr = ConioCoordToPointer(Buff, 0, Buff->CursorPosition.Y); + PCHAR_INFO Ptr = ConioCoordToPointer(Buff, 0, Buff->CursorPosition.Y); SHORT Pos; - for (Pos = 0; Pos < Buff->ScreenBufferSize.X; Pos++) + for (Pos = 0; Pos < Buff->ScreenBufferSize.X; Pos++, Ptr++) { /* Fill the cell */ - *Ptr++ = ' '; - *Ptr++ = (BYTE)Buff->ScreenDefaultAttrib; + Ptr->Char.UnicodeChar = L' '; + Ptr->Attributes = Buff->ScreenDefaultAttrib; } } @@ -252,9 +247,9 @@ SMALL_RECT* SrcRegion, SMALL_RECT* DstRegion, SMALL_RECT* ClipRegion, - WORD Fill) -{ - int Width = ConioRectWidth(SrcRegion); + CHAR_INFO FillChar) +{ + int Width = ConioRectWidth(SrcRegion); int Height = ConioRectHeight(SrcRegion); int SX, SY; int DX, DY; @@ -273,8 +268,8 @@ } for (i = 0; i < Height; i++) { - PWORD SRow = (PWORD)ConioCoordToPointer(ScreenBuffer, 0, SY); - PWORD DRow = (PWORD)ConioCoordToPointer(ScreenBuffer, 0, DY); + PCHAR_INFO SRow = ConioCoordToPointer(ScreenBuffer, 0, SY); + PCHAR_INFO DRow = ConioCoordToPointer(ScreenBuffer, 0, DY); SX = SrcRegion->Left; DX = DstRegion->Left; @@ -288,14 +283,14 @@ } for (j = 0; j < Width; j++) { - WORD Cell = SRow[SX]; - if (SX >= ClipRegion->Left && SX <= ClipRegion->Right - && SY >= ClipRegion->Top && SY <= ClipRegion->Bottom) - { - SRow[SX] = Fill; - } - if (DX >= ClipRegion->Left && DX <= ClipRegion->Right - && DY >= ClipRegion->Top && DY <= ClipRegion->Bottom) + CHAR_INFO Cell = SRow[SX]; + if (SX >= ClipRegion->Left && SX <= ClipRegion->Right && + SY >= ClipRegion->Top && SY <= ClipRegion->Bottom) + { + SRow[SX] = FillChar; + } + if (DX >= ClipRegion->Left && DX <= ClipRegion->Right && + DY >= ClipRegion->Top && DY <= ClipRegion->Bottom) { DRow[DX] = Cell; } @@ -322,11 +317,11 @@ PTEXTMODE_SCREEN_BUFFER ScreenBuffer, COORD Size) { - BYTE * Buffer; + PCHAR_INFO Buffer; DWORD Offset = 0; - BYTE * OldPtr; + PCHAR_INFO ptr; USHORT CurrentY; - BYTE * OldBuffer; + PCHAR_INFO OldBuffer; #ifdef HAVE_WMEMSET USHORT value = MAKEWORD(' ', ScreenBuffer->ScreenDefaultAttrib); #else @@ -355,7 +350,7 @@ return STATUS_NOT_SUPPORTED; // STATUS_SUCCESS } - Buffer = ConsoleAllocHeap(0, Size.X * Size.Y * 2); + Buffer = ConsoleAllocHeap(HEAP_ZERO_MEMORY, Size.X * Size.Y * sizeof(CHAR_INFO)); if (!Buffer) return STATUS_NO_MEMORY; DPRINT1("Resizing (%d,%d) to (%d,%d)\n", ScreenBuffer->ScreenBufferSize.X, ScreenBuffer->ScreenBufferSize.Y, Size.X, Size.Y); @@ -363,28 +358,30 @@ for (CurrentY = 0; CurrentY < ScreenBuffer->ScreenBufferSize.Y && CurrentY < Size.Y; CurrentY++) { - OldPtr = ConioCoordToPointer(ScreenBuffer, 0, CurrentY); + ptr = ConioCoordToPointer(ScreenBuffer, 0, CurrentY); if (Size.X <= ScreenBuffer->ScreenBufferSize.X) { - /* reduce size */ - RtlCopyMemory(&Buffer[Offset], OldPtr, Size.X * 2); - Offset += (Size.X * 2); + /* Reduce size */ + RtlCopyMemory(Buffer + Offset, ptr, Size.X * sizeof(CHAR_INFO)); + Offset += Size.X; } else { - /* enlarge size */ - RtlCopyMemory(&Buffer[Offset], OldPtr, ScreenBuffer->ScreenBufferSize.X * 2); - Offset += (ScreenBuffer->ScreenBufferSize.X * 2); + /* Enlarge size */ + RtlCopyMemory(Buffer + Offset, ptr, ScreenBuffer->ScreenBufferSize.X * sizeof(CHAR_INFO)); + Offset += ScreenBuffer->ScreenBufferSize.X; diff = Size.X - ScreenBuffer->ScreenBufferSize.X; - /* zero new part of it */ + /* Zero new part of it */ #ifdef HAVE_WMEMSET wmemset((PWCHAR)&Buffer[Offset], value, diff); #else for (i = 0; i < diff; i++) { - Buffer[Offset++] = ' '; - Buffer[Offset++] = (BYTE)ScreenBuffer->ScreenDefaultAttrib; + ptr = Buffer + Offset; + ptr->Char.UnicodeChar = L' '; + ptr->Attributes = ScreenBuffer->ScreenDefaultAttrib; + ++Offset; } #endif } @@ -398,8 +395,10 @@ #else for (i = 0; i < diff; i++) { - Buffer[Offset++] = ' '; - Buffer[Offset++] = (BYTE)ScreenBuffer->ScreenDefaultAttrib; + ptr = Buffer + Offset; + ptr->Char.UnicodeChar = L' '; + ptr->Attributes = ScreenBuffer->ScreenDefaultAttrib; + ++Offset; } #endif } @@ -461,12 +460,12 @@ NTSTATUS ConioWriteConsole(PCONSOLE Console, PTEXTMODE_SCREEN_BUFFER Buff, - CHAR *Buffer, + PWCHAR Buffer, DWORD Length, BOOL Attrib) { UINT i; - PBYTE Ptr; + PCHAR_INFO Ptr; SMALL_RECT UpdateRect; SHORT CursorStartX, CursorStartY; UINT ScrolledLines; @@ -488,7 +487,7 @@ if (Buff->Mode & ENABLE_PROCESSED_OUTPUT) { /* --- CR --- */ - if (Buffer[i] == '\r') + if (Buffer[i] == L'\r') { Buff->CursorPosition.X = 0; UpdateRect.Left = min(UpdateRect.Left, Buff->CursorPosition.X); @@ -496,14 +495,14 @@ continue; } /* --- LF --- */ - else if (Buffer[i] == '\n') + else if (Buffer[i] == L'\n') { Buff->CursorPosition.X = 0; ConioNextLine(Buff, &UpdateRect, &ScrolledLines); continue; } /* --- BS --- */ - else if (Buffer[i] == '\b') + else if (Buffer[i] == L'\b') { /* Only handle BS if we're not on the first pos of the first line */ if (0 != Buff->CursorPosition.X || 0 != Buff->CursorPosition.Y) @@ -520,15 +519,15 @@ Buff->CursorPosition.X--; } Ptr = ConioCoordToPointer(Buff, Buff->CursorPosition.X, Buff->CursorPosition.Y); - Ptr[0] = ' '; - Ptr[1] = (BYTE)Buff->ScreenDefaultAttrib; - UpdateRect.Left = min(UpdateRect.Left, Buff->CursorPosition.X); + Ptr->Char.UnicodeChar = L' '; + Ptr->Attributes = Buff->ScreenDefaultAttrib; + UpdateRect.Left = min(UpdateRect.Left, Buff->CursorPosition.X); UpdateRect.Right = max(UpdateRect.Right, Buff->CursorPosition.X); } continue; } /* --- TAB --- */ - else if (Buffer[i] == '\t') + else if (Buffer[i] == L'\t') { UINT EndX; @@ -538,8 +537,9 @@ Ptr = ConioCoordToPointer(Buff, Buff->CursorPosition.X, Buff->CursorPosition.Y); while (Buff->CursorPosition.X < EndX) { - *Ptr++ = ' '; - *Ptr++ = (BYTE)Buff->ScreenDefaultAttrib; + Ptr->Char.UnicodeChar = L' '; + Ptr->Attributes = Buff->ScreenDefaultAttrib; + ++Ptr; Buff->CursorPosition.X++; } UpdateRect.Right = max(UpdateRect.Right, Buff->CursorPosition.X - 1); @@ -558,7 +558,7 @@ continue; } // /* --- BEL ---*/ - // else if (Buffer[i] == '\a') + // else if (Buffer[i] == L'\a') // { // // FIXME: This MUST BE moved to the terminal emulator frontend!! // DPRINT1("Bell\n"); @@ -566,14 +566,13 @@ // continue; // } } - UpdateRect.Left = min(UpdateRect.Left, Buff->CursorPosition.X); + UpdateRect.Left = min(UpdateRect.Left, Buff->CursorPosition.X); UpdateRect.Right = max(UpdateRect.Right, Buff->CursorPosition.X); + Ptr = ConioCoordToPointer(Buff, Buff->CursorPosition.X, Buff->CursorPosition.Y); - Ptr[0] = Buffer[i]; - if (Attrib) - { - Ptr[1] = (BYTE)Buff->ScreenDefaultAttrib; - } + Ptr->Char.UnicodeChar = Buffer[i]; + if (Attrib) Ptr->Attributes = Buff->ScreenDefaultAttrib; + Buff->CursorPosition.X++; if (Buff->CursorPosition.X == Buff->ScreenBufferSize.X) { @@ -650,7 +649,7 @@ PCONSOLE_WRITECONSOLE WriteConsoleRequest = &((PCONSOLE_API_MESSAGE)ApiMessage)->Data.WriteConsoleRequest; PCONSOLE Console; PTEXTMODE_SCREEN_BUFFER Buff; - PCHAR Buffer; + PVOID Buffer; DWORD Written = 0; ULONG Length; @@ -684,41 +683,44 @@ { if (WriteConsoleRequest->Unicode) { - Length = WideCharToMultiByte(Console->OutputCodePage, 0, - (PWCHAR)WriteConsoleRequest->Buffer, + Buffer = WriteConsoleRequest->Buffer; + } + else + { + Length = MultiByteToWideChar(Console->OutputCodePage, 0, + (PCHAR)WriteConsoleRequest->Buffer, WriteConsoleRequest->NrCharactersToWrite, - NULL, 0, NULL, NULL); - Buffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, Length); + NULL, 0); + Buffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, Length * sizeof(WCHAR)); if (Buffer) { - WideCharToMultiByte(Console->OutputCodePage, 0, - (PWCHAR)WriteConsoleRequest->Buffer, + MultiByteToWideChar(Console->OutputCodePage, 0, + (PCHAR)WriteConsoleRequest->Buffer, WriteConsoleRequest->NrCharactersToWrite, - Buffer, Length, NULL, NULL); + (PWCHAR)Buffer, Length); } else { Status = STATUS_NO_MEMORY; } } - else - { - Buffer = (PCHAR)WriteConsoleRequest->Buffer; - } if (Buffer) { if (NT_SUCCESS(Status)) { - Status = ConioWriteConsole(Console, Buff, Buffer, - WriteConsoleRequest->NrCharactersToWrite, TRUE); + Status = ConioWriteConsole(Console, + Buff, + Buffer, + WriteConsoleRequest->NrCharactersToWrite, + TRUE); if (NT_SUCCESS(Status)) { Written = WriteConsoleRequest->NrCharactersToWrite; } } - if (WriteConsoleRequest->Unicode) + if (!WriteConsoleRequest->Unicode) RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer); } @@ -746,7 +748,7 @@ SMALL_RECT ReadRegion; SMALL_RECT ScreenRect; DWORD i; - PBYTE Ptr; + PCHAR_INFO Ptr; LONG X, Y; UINT CodePage; @@ -792,16 +794,16 @@ { if (ReadOutputRequest->Unicode) { - // ConsoleAnsiCharToUnicodeChar(ProcessData->Console, (PCHAR)Ptr++, &CurCharInfo->Char.UnicodeChar); - MultiByteToWideChar(CodePage, 0, - (PCHAR)Ptr++, 1, - &CurCharInfo->Char.UnicodeChar, 1); + CurCharInfo->Char.UnicodeChar = Ptr->Char.UnicodeChar; } else { - CurCharInfo->Char.AsciiChar = *Ptr++; - } - CurCharInfo->Attributes = *Ptr++; + // ConsoleUnicodeCharToAnsiChar(ProcessData->Console, &CurCharInfo->Char.AsciiChar, &Ptr->Char.UnicodeChar); + WideCharToMultiByte(CodePage, 0, &Ptr->Char.UnicodeChar, 1, + &CurCharInfo->Char.AsciiChar, 1, NULL, NULL); + } + CurCharInfo->Attributes = Ptr->Attributes; + ++Ptr; ++CurCharInfo; } } @@ -824,13 +826,13 @@ PCONSOLE Console; PTEXTMODE_SCREEN_BUFFER Buff; SMALL_RECT ScreenBuffer; - CHAR_INFO* CurCharInfo; + PCHAR_INFO CurCharInfo; SMALL_RECT WriteRegion; - CHAR_INFO* CharInfo; + PCHAR_INFO CharInfo; COORD BufferCoord; COORD BufferSize; NTSTATUS Status; - PBYTE Ptr; + PCHAR_INFO Ptr; DPRINT("SrvWriteConsoleOutput\n"); @@ -847,10 +849,10 @@ } Status = ConSrvGetTextModeBuffer(ProcessData, - WriteOutputRequest->OutputHandle, - &Buff, - GENERIC_WRITE, - TRUE); + WriteOutputRequest->OutputHandle, + &Buff, + GENERIC_WRITE, + TRUE); if (!NT_SUCCESS(Status)) return Status; Console = Buff->Header.Console; @@ -876,21 +878,21 @@ for (i = 0, Y = WriteRegion.Top; Y <= WriteRegion.Bottom; i++, Y++) { CurCharInfo = CharInfo + (i + BufferCoord.Y) * BufferSize.X + BufferCoord.X; + Ptr = ConioCoordToPointer(Buff, WriteRegion.Left, Y); for (X = WriteRegion.Left; X <= WriteRegion.Right; X++) { - CHAR AsciiChar; if (WriteOutputRequest->Unicode) { - ConsoleUnicodeCharToAnsiChar(Console, &AsciiChar, &CurCharInfo->Char.UnicodeChar); + Ptr->Char.UnicodeChar = CurCharInfo->Char.UnicodeChar; } else { - AsciiChar = CurCharInfo->Char.AsciiChar; - } - *Ptr++ = AsciiChar; - *Ptr++ = (BYTE)CurCharInfo->Attributes; - CurCharInfo++; + ConsoleAnsiCharToUnicodeChar(Console, &Ptr->Char.UnicodeChar, &CurCharInfo->Char.AsciiChar); + } + Ptr->Attributes = CurCharInfo->Attributes; + ++Ptr; + ++CurCharInfo; } } @@ -942,7 +944,7 @@ PVOID ReadBuffer; DWORD i; ULONG CodeSize; - BYTE Code; + PCHAR_INFO Ptr; DPRINT("SrvReadConsoleOutputString\n"); @@ -973,7 +975,11 @@ return STATUS_INVALID_PARAMETER; } - Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), ReadOutputCodeRequest->OutputHandle, &Buff, GENERIC_READ, TRUE); + Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), + ReadOutputCodeRequest->OutputHandle, + &Buff, + GENERIC_READ, + TRUE); if (!NT_SUCCESS(Status)) return Status; Console = Buff->Header.Console; @@ -995,25 +1001,28 @@ * TODO: Do NOT loop up to NumCodesToRead, but stop before * if we are going to overflow... */ - for (i = 0; i < min(ReadOutputCodeRequest->NumCodesToRead, Buff->ScreenBufferSize.X * Buff->ScreenBufferSize.Y * 2); ++i) - { - Code = Buff->Buffer[2 * (Xpos + Ypos * Buff->ScreenBufferSize.X) + (CodeType == CODE_ATTRIBUTE ? 1 : 0)]; + // Ptr = ConioCoordToPointer(Buff, Xpos, Ypos); // Doesn't work + for (i = 0; i < min(ReadOutputCodeRequest->NumCodesToRead, Buff->ScreenBufferSize.X * Buff->ScreenBufferSize.Y); ++i) + { + // Ptr = ConioCoordToPointer(Buff, Xpos, Ypos); // Doesn't work either + Ptr = &Buff->Buffer[Xpos + Ypos * Buff->ScreenBufferSize.X]; switch (CodeType) { + case CODE_ASCII: + ConsoleUnicodeCharToAnsiChar(Console, (PCHAR)ReadBuffer, &Ptr->Char.UnicodeChar); + break; + case CODE_UNICODE: - ConsoleAnsiCharToUnicodeChar(Console, (PWCHAR)ReadBuffer, (PCHAR)&Code); + *(PWCHAR)ReadBuffer = Ptr->Char.UnicodeChar; break; - case CODE_ASCII: - *(PCHAR)ReadBuffer = (CHAR)Code; + case CODE_ATTRIBUTE: + *(PWORD)ReadBuffer = Ptr->Attributes; break; - - case CODE_ATTRIBUTE: - *(PWORD)ReadBuffer = (WORD)Code; - break; } ReadBuffer = (PVOID)((ULONG_PTR)ReadBuffer + CodeSize); + // ++Ptr; Xpos++; @@ -1062,11 +1071,12 @@ PCONSOLE Console; PTEXTMODE_SCREEN_BUFFER Buff; USHORT CodeType; - PBYTE Buffer; // PUCHAR - PCHAR String, tmpString = NULL; + PVOID ReadBuffer = NULL; + PWCHAR tmpString = NULL; DWORD X, Y, Length; // , Written = 0; ULONG CodeSize; SMALL_RECT UpdateRect; + PCHAR_INFO Ptr; DPRINT("SrvWriteConsoleOutputString\n"); @@ -1098,85 +1108,90 @@ } Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), - WriteOutputCodeRequest->OutputHandle, - &Buff, - GENERIC_WRITE, - TRUE); + WriteOutputCodeRequest->OutputHandle, + &Buff, + GENERIC_WRITE, + TRUE); if (!NT_SUCCESS(Status)) return Status; Console = Buff->Header.Console; - switch (CodeType) - { - case CODE_UNICODE: - { - Length = WideCharToMultiByte(Console->OutputCodePage, 0, - (PWCHAR)WriteOutputCodeRequest->pCode.UnicodeChar, - WriteOutputCodeRequest->Length, - NULL, 0, NULL, NULL); - tmpString = String = RtlAllocateHeap(RtlGetProcessHeap(), 0, Length); - if (String) - { - WideCharToMultiByte(Console->OutputCodePage, 0, - (PWCHAR)WriteOutputCodeRequest->pCode.UnicodeChar, - WriteOutputCodeRequest->Length, - String, Length, NULL, NULL); - } - else - { - Status = STATUS_NO_MEMORY; - } - - break; - } - - case CODE_ASCII: - String = (PCHAR)WriteOutputCodeRequest->pCode.AsciiChar; - break; - - case CODE_ATTRIBUTE: - default: - // *(ReadBuffer++) = Code; - String = (PCHAR)WriteOutputCodeRequest->pCode.Attribute; - break; - } - - if (String && NT_SUCCESS(Status)) - { - X = WriteOutputCodeRequest->Coord.X; - Y = (WriteOutputCodeRequest->Coord.Y + Buff->VirtualY) % Buff->ScreenBufferSize.Y; - Length = WriteOutputCodeRequest->Length; - Buffer = &Buff->Buffer[2 * (Y * Buff->ScreenBufferSize.X + X) + (CodeType == CODE_ATTRIBUTE ? 1 : 0)]; - - while (Length--) - { - *Buffer = *String++; - // ReadBuffer = (PVOID)((ULONG_PTR)ReadBuffer + CodeSize); - String = (PCHAR)((ULONG_PTR)String + CodeSize); - // Written++; - Buffer += 2; - if (++X == Buff->ScreenBufferSize.X) - { - if (++Y == Buff->ScreenBufferSize.Y) - { - Y = 0; - Buffer = Buff->Buffer + (CodeType == CODE_ATTRIBUTE ? 1 : 0); - } - X = 0; - } - } - - if ((PCONSOLE_SCREEN_BUFFER)Buff == Console->ActiveBuffer) - { - ConioComputeUpdateRect(Buff, &UpdateRect, &WriteOutputCodeRequest->Coord, - WriteOutputCodeRequest->Length); - ConioDrawRegion(Console, &UpdateRect); - } - - // WriteOutputCodeRequest->EndCoord.X = X; - // WriteOutputCodeRequest->EndCoord.Y = (Y + Buff->ScreenBufferSize.Y - Buff->VirtualY) % Buff->ScreenBufferSize.Y; - } - + if (CodeType == CODE_ASCII) + { + /* Convert the ASCII string into Unicode before writing it to the console */ + Length = MultiByteToWideChar(Console->OutputCodePage, 0, + WriteOutputCodeRequest->pCode.AsciiChar, + WriteOutputCodeRequest->Length, + NULL, 0); + tmpString = ReadBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, Length * sizeof(WCHAR)); + if (ReadBuffer) + { + MultiByteToWideChar(Console->OutputCodePage, 0, + WriteOutputCodeRequest->pCode.AsciiChar, + WriteOutputCodeRequest->Length, + (PWCHAR)ReadBuffer, Length); + } + else + { + Status = STATUS_NO_MEMORY; + } + } + else + { + /* For CODE_UNICODE or CODE_ATTRIBUTE, we are already OK */ + ReadBuffer = WriteOutputCodeRequest->pCode.pCode; + } + + if (ReadBuffer == NULL || !NT_SUCCESS(Status)) goto Cleanup; + + X = WriteOutputCodeRequest->Coord.X; + Y = (WriteOutputCodeRequest->Coord.Y + Buff->VirtualY) % Buff->ScreenBufferSize.Y; + Length = WriteOutputCodeRequest->Length; + // Ptr = ConioCoordToPointer(Buff, X, Y); // Doesn't work + // Ptr = &Buff->Buffer[X + Y * Buff->ScreenBufferSize.X]; // May work + + while (Length--) + { + // Ptr = ConioCoordToPointer(Buff, X, Y); // Doesn't work either + Ptr = &Buff->Buffer[X + Y * Buff->ScreenBufferSize.X]; + + switch (CodeType) + { + case CODE_ASCII: + case CODE_UNICODE: + Ptr->Char.UnicodeChar = *(PWCHAR)ReadBuffer; + break; + + case CODE_ATTRIBUTE: + Ptr->Attributes = *(PWORD)ReadBuffer; + break; + } + ReadBuffer = (PVOID)((ULONG_PTR)ReadBuffer + CodeSize); + // ++Ptr; + + // Written++; + if (++X == Buff->ScreenBufferSize.X) + { + X = 0; + + if (++Y == Buff->ScreenBufferSize.Y) + { + Y = 0; + } + } + } + + if ((PCONSOLE_SCREEN_BUFFER)Buff == Console->ActiveBuffer) + { + ConioComputeUpdateRect(Buff, &UpdateRect, &WriteOutputCodeRequest->Coord, + WriteOutputCodeRequest->Length); + ConioDrawRegion(Console, &UpdateRect); + } + + // WriteOutputCodeRequest->EndCoord.X = X; + // WriteOutputCodeRequest->EndCoord.Y = (Y + Buff->ScreenBufferSize.Y - Buff->VirtualY) % Buff->ScreenBufferSize.Y; + +Cleanup: if (tmpString) RtlFreeHeap(RtlGetProcessHeap(), 0, tmpString); @@ -1194,56 +1209,77 @@ PTEXTMODE_SCREEN_BUFFER Buff; DWORD X, Y, Length; // , Written = 0; USHORT CodeType; - BYTE Code; - PBYTE Buffer; + PVOID Code = NULL; + PCHAR_INFO Ptr; SMALL_RECT UpdateRect; DPRINT("SrvFillConsoleOutput\n"); - Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), FillOutputRequest->OutputHandle, &Buff, GENERIC_WRITE, TRUE); + CodeType = FillOutputRequest->CodeType; + if ( (CodeType != CODE_ASCII ) && + (CodeType != CODE_UNICODE ) && + (CodeType != CODE_ATTRIBUTE) ) + { + return STATUS_INVALID_PARAMETER; + } + + Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), + FillOutputRequest->OutputHandle, + &Buff, + GENERIC_WRITE, + TRUE); if (!NT_SUCCESS(Status)) return Status; Console = Buff->Header.Console; - CodeType = FillOutputRequest->CodeType; + switch (CodeType) + { + case CODE_ASCII: + /* On-place conversion from the ASCII char to the UNICODE char */ + ConsoleAnsiCharToUnicodeChar(Console, &FillOutputRequest->Code.UnicodeChar, &FillOutputRequest->Code.AsciiChar); + /* Fall through */ + case CODE_UNICODE: + Code = &FillOutputRequest->Code.UnicodeChar; + break; + + case CODE_ATTRIBUTE: + Code = &FillOutputRequest->Code.Attribute; + break; + } X = FillOutputRequest->Coord.X; Y = (FillOutputRequest->Coord.Y + Buff->VirtualY) % Buff->ScreenBufferSize.Y; Length = FillOutputRequest->Length; - Buffer = &Buff->Buffer[2 * (Y * Buff->ScreenBufferSize.X + X) + (CodeType == CODE_ATTRIBUTE ? 1 : 0)]; - - switch (CodeType) - { - case CODE_ASCII: - Code = (BYTE)FillOutputRequest->Code.AsciiChar; - break; - - case CODE_UNICODE: - ConsoleUnicodeCharToAnsiChar(Console, (PCHAR)&Code, &FillOutputRequest->Code.UnicodeChar); - break; - - case CODE_ATTRIBUTE: - Code = (BYTE)FillOutputRequest->Code.Attribute; - break; - - default: - ConSrvReleaseScreenBuffer(Buff, TRUE); - return STATUS_INVALID_PARAMETER; - } + // Ptr = ConioCoordToPointer(Buff, X, Y); // Doesn't work + // Ptr = &Buff->Buffer[X + Y * Buff->ScreenBufferSize.X]; // May work while (Length--) { - *Buffer = Code; - Buffer += 2; + // Ptr = ConioCoordToPointer(Buff, X, Y); // Doesn't work either + Ptr = &Buff->Buffer[X + Y * Buff->ScreenBufferSize.X]; + + switch (CodeType) + { + case CODE_ASCII: + case CODE_UNICODE: + Ptr->Char.UnicodeChar = *(PWCHAR)Code; + break; + + case CODE_ATTRIBUTE: + Ptr->Attributes = *(PWORD)Code; + break; + } + // ++Ptr; + // Written++; if (++X == Buff->ScreenBufferSize.X) { + X = 0; + if (++Y == Buff->ScreenBufferSize.Y) { Y = 0; - Buffer = Buff->Buffer + (CodeType == CODE_ATTRIBUTE ? 1 : 0); - } - X = 0; + } } } @@ -1341,15 +1377,14 @@ HANDLE OutputHandle; BOOLEAN UseClipRectangle; COORD DestinationOrigin; - CHAR_INFO Fill; - CHAR FillChar; + CHAR_INFO FillChar; DPRINT("SrvScrollConsoleScreenBuffer\n"); OutputHandle = ScrollScreenBufferRequest->OutputHandle; UseClipRectangle = ScrollScreenBufferRequest->UseClipRectangle; DestinationOrigin = ScrollScreenBufferRequest->DestinationOrigin; - Fill = ScrollScreenBufferRequest->Fill; + FillChar = ScrollScreenBufferRequest->Fill; Status = ConSrvGetTextModeBuffer(ConsoleGetPerProcessData(CsrGetClientThread()->Process), OutputHandle, &Buff, GENERIC_WRITE, TRUE); if (!NT_SUCCESS(Status)) return Status; @@ -1396,12 +1431,10 @@ DestinationOrigin.Y + ConioRectHeight(&SrcRegion) - 1, DestinationOrigin.X + ConioRectWidth(&SrcRegion) - 1); - if (ScrollScreenBufferRequest->Unicode) - ConsoleUnicodeCharToAnsiChar(Console, &FillChar, &Fill.Char.UnicodeChar); - else - FillChar = Fill.Char.AsciiChar; - - ConioMoveRegion(Buff, &SrcRegion, &DstRegion, &ClipRectangle, Fill.Attributes << 8 | (BYTE)FillChar); + if (!ScrollScreenBufferRequest->Unicode) + ConsoleAnsiCharToUnicodeChar(Console, &FillChar.Char.UnicodeChar, &FillChar.Char.AsciiChar); + + ConioMoveRegion(Buff, &SrcRegion, &DstRegion, &ClipRectangle, FillChar); if ((PCONSOLE_SCREEN_BUFFER)Buff == Console->ActiveBuffer) {
11 years, 3 months
1
0
0
0
[hbelusca] 59211: [KERNEL32] Code formatting only + member variable type fix.
by hbelusca@svn.reactos.org
Author: hbelusca Date: Fri Jun 14 01:00:49 2013 New Revision: 59211 URL:
http://svn.reactos.org/svn/reactos?rev=59211&view=rev
Log: [KERNEL32] Code formatting only + member variable type fix. Modified: trunk/reactos/dll/win32/kernel32/client/console/console.c trunk/reactos/include/reactos/subsys/win/conmsg.h Modified: trunk/reactos/dll/win32/kernel32/client/console/console.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/client/…
============================================================================== --- trunk/reactos/dll/win32/kernel32/client/console/console.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/kernel32/client/console/console.c [iso-8859-1] Fri Jun 14 01:00:49 2013 @@ -1958,17 +1958,15 @@ CONSOLE_API_MESSAGE ApiMessage; /* Get the Input Code Page */ - ApiMessage.Data.ConsoleCPRequest.InputCP = TRUE; + ApiMessage.Data.ConsoleCPRequest.InputCP = TRUE; + ApiMessage.Data.ConsoleCPRequest.CodePage = 0; Status = CsrClientCallServer((PCSR_API_MESSAGE)&ApiMessage, NULL, CSR_CREATE_API_NUMBER(CONSRV_SERVERDLL_INDEX, ConsolepGetCP), sizeof(CONSOLE_GETSETINPUTOUTPUTCP)); - if (!NT_SUCCESS(Status)) - { - BaseSetLastNTError(Status); - return 0; - } + + if (!NT_SUCCESS(Status)) BaseSetLastNTError(Status); return ApiMessage.Data.ConsoleCPRequest.CodePage; } @@ -1987,17 +1985,15 @@ CONSOLE_API_MESSAGE ApiMessage; /* Set the Input Code Page */ - ApiMessage.Data.ConsoleCPRequest.InputCP = TRUE; + ApiMessage.Data.ConsoleCPRequest.InputCP = TRUE; ApiMessage.Data.ConsoleCPRequest.CodePage = wCodePageID; Status = CsrClientCallServer((PCSR_API_MESSAGE)&ApiMessage, NULL, CSR_CREATE_API_NUMBER(CONSRV_SERVERDLL_INDEX, ConsolepSetCP), sizeof(CONSOLE_GETSETINPUTOUTPUTCP)); - if (!NT_SUCCESS(Status)) - { - BaseSetLastNTError(Status); - } + + if (!NT_SUCCESS(Status)) BaseSetLastNTError(Status); return NT_SUCCESS(Status); } @@ -2016,17 +2012,15 @@ CONSOLE_API_MESSAGE ApiMessage; /* Get the Output Code Page */ - ApiMessage.Data.ConsoleCPRequest.InputCP = FALSE; + ApiMessage.Data.ConsoleCPRequest.InputCP = FALSE; + ApiMessage.Data.ConsoleCPRequest.CodePage = 0; Status = CsrClientCallServer((PCSR_API_MESSAGE)&ApiMessage, NULL, CSR_CREATE_API_NUMBER(CONSRV_SERVERDLL_INDEX, ConsolepGetCP), sizeof(CONSOLE_GETSETINPUTOUTPUTCP)); - if (!NT_SUCCESS(Status)) - { - BaseSetLastNTError (Status); - return 0; - } + + if (!NT_SUCCESS(Status)) BaseSetLastNTError(Status); return ApiMessage.Data.ConsoleCPRequest.CodePage; } @@ -2045,17 +2039,15 @@ CONSOLE_API_MESSAGE ApiMessage; /* Set the Output Code Page */ - ApiMessage.Data.ConsoleCPRequest.InputCP = FALSE; + ApiMessage.Data.ConsoleCPRequest.InputCP = FALSE; ApiMessage.Data.ConsoleCPRequest.CodePage = wCodePageID; Status = CsrClientCallServer((PCSR_API_MESSAGE)&ApiMessage, NULL, CSR_CREATE_API_NUMBER(CONSRV_SERVERDLL_INDEX, ConsolepSetCP), sizeof(CONSOLE_GETSETINPUTOUTPUTCP)); - if (!NT_SUCCESS(Status)) - { - BaseSetLastNTError(Status); - } + + if (!NT_SUCCESS(Status)) BaseSetLastNTError(Status); return NT_SUCCESS(Status); } Modified: trunk/reactos/include/reactos/subsys/win/conmsg.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/subsys/win…
============================================================================== --- trunk/reactos/include/reactos/subsys/win/conmsg.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/subsys/win/conmsg.h [iso-8859-1] Fri Jun 14 01:00:49 2013 @@ -361,10 +361,10 @@ CODE_TYPE CodeType; union { - PVOID pCode; - PCHAR AsciiChar; + PVOID pCode; + PCHAR AsciiChar; PWCHAR UnicodeChar; - PWORD Attribute; + PWORD Attribute; } pCode; // Either a pointer to a character or to an attribute. } CONSOLE_READOUTPUTCODE, *PCONSOLE_READOUTPUTCODE; @@ -379,27 +379,26 @@ ULONG NrCharactersWritten; - USHORT CodeType; - union - { - // PVOID String; - PVOID pCode; - PCHAR AsciiChar; - PWCHAR UnicodeChar; - PWORD Attribute; - } pCode; // Either a pointer to a character or to an attribute. -} CONSOLE_WRITEOUTPUTCODE, *PCONSOLE_WRITEOUTPUTCODE; - -typedef struct -{ - HANDLE OutputHandle; - CODE_TYPE CodeType; union { - CHAR AsciiChar; + PVOID pCode; + PCHAR AsciiChar; + PWCHAR UnicodeChar; + PWORD Attribute; + } pCode; // Either a pointer to a character or to an attribute. +} CONSOLE_WRITEOUTPUTCODE, *PCONSOLE_WRITEOUTPUTCODE; + +typedef struct +{ + HANDLE OutputHandle; + + CODE_TYPE CodeType; + union + { + CHAR AsciiChar; WCHAR UnicodeChar; - WORD Attribute; + WORD Attribute; } Code; // Either a character or an attribute. COORD Coord;
11 years, 3 months
1
0
0
0
[ekohl] 59210: [NETAPI32] Move the NETAPI_IsLocalComputer prototype to netapi32.h.
by ekohl@svn.reactos.org
Author: ekohl Date: Thu Jun 13 21:20:45 2013 New Revision: 59210 URL:
http://svn.reactos.org/svn/reactos?rev=59210&view=rev
Log: [NETAPI32] Move the NETAPI_IsLocalComputer prototype to netapi32.h. Modified: trunk/reactos/dll/win32/netapi32/access.c trunk/reactos/dll/win32/netapi32/netapi32.c trunk/reactos/dll/win32/netapi32/netapi32.h Modified: trunk/reactos/dll/win32/netapi32/access.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/access.…
============================================================================== --- trunk/reactos/dll/win32/netapi32/access.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/netapi32/access.c [iso-8859-1] Thu Jun 13 21:20:45 2013 @@ -22,7 +22,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(netapi32); -BOOL NETAPI_IsLocalComputer(LPCWSTR ServerName); /************************************************************ * ACCESS_QueryAdminDisplayInformation Modified: trunk/reactos/dll/win32/netapi32/netapi32.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/netapi3…
============================================================================== --- trunk/reactos/dll/win32/netapi32/netapi32.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/netapi32/netapi32.c [iso-8859-1] Thu Jun 13 21:20:45 2013 @@ -25,13 +25,11 @@ #define NTOS_MODE_USER #include <ndk/rtlfuncs.h> -//#include "netapi32.h" +#include "netapi32.h" WINE_DEFAULT_DEBUG_CHANNEL(netbios); static HMODULE NETAPI32_hModule; - -BOOL NETAPI_IsLocalComputer(LMCSTR ServerName); BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) { Modified: trunk/reactos/dll/win32/netapi32/netapi32.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/netapi3…
============================================================================== --- trunk/reactos/dll/win32/netapi32/netapi32.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/netapi32/netapi32.h [iso-8859-1] Thu Jun 13 21:20:45 2013 @@ -57,4 +57,9 @@ IN ULONG RelativeId, OUT PSID *DestSid); +/* wksta.c */ + +BOOL +NETAPI_IsLocalComputer(LMCSTR ServerName); + #endif
11 years, 3 months
1
0
0
0
[ekohl] 59209: [NETAPI32] NetLocalGroupSetInfo: Implement level 1002.
by ekohl@svn.reactos.org
Author: ekohl Date: Thu Jun 13 19:51:14 2013 New Revision: 59209 URL:
http://svn.reactos.org/svn/reactos?rev=59209&view=rev
Log: [NETAPI32] NetLocalGroupSetInfo: Implement level 1002. Modified: trunk/reactos/dll/win32/netapi32/local_group.c Modified: trunk/reactos/dll/win32/netapi32/local_group.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/local_g…
============================================================================== --- trunk/reactos/dll/win32/netapi32/local_group.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/netapi32/local_group.c [iso-8859-1] Thu Jun 13 19:51:14 2013 @@ -1817,9 +1817,14 @@ break; case 1: + case 1002: /* Set the alias admin comment */ - RtlInitUnicodeString(&AdminCommentInfo.AdminComment, - ((PLOCALGROUP_INFO_1)buf)->lgrpi1_comment); + if (level == 1) + RtlInitUnicodeString(&AdminCommentInfo.AdminComment, + ((PLOCALGROUP_INFO_1)buf)->lgrpi1_comment); + else + RtlInitUnicodeString(&AdminCommentInfo.AdminComment, + ((PLOCALGROUP_INFO_1002)buf)->lgrpi1002_comment); Status = SamSetInformationAlias(AliasHandle, AliasAdminCommentInformation,
11 years, 3 months
1
0
0
0
[jgardou] 59208: [HIVESYS] - Committed something unwanted, sorry.
by jgardou@svn.reactos.org
Author: jgardou Date: Thu Jun 13 16:10:52 2013 New Revision: 59208 URL:
http://svn.reactos.org/svn/reactos?rev=59208&view=rev
Log: [HIVESYS] - Committed something unwanted, sorry. Modified: trunk/reactos/boot/bootdata/hivesys.inf Modified: trunk/reactos/boot/bootdata/hivesys.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/bootdata/hivesys.inf?…
============================================================================== --- trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] (original) +++ trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] Thu Jun 13 16:10:52 2013 @@ -1556,7 +1556,7 @@ ; PCI Bus driver HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ErrorControl",0x00010001,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Group",0x00000000,"Boot Bus Extender" -HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ImagePath",0x00020000,"system32\drivers\pcix.sys" +HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ImagePath",0x00020000,"system32\drivers\pci.sys" HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Start",0x00010001,0x00000000 HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Type",0x00010001,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\Pci\Parameters","1045C621",0x00030003,04,00,00,00,00,00,00,00
11 years, 3 months
1
0
0
0
[jgardou] 59207: [INF] - recognize PCI\CC_0000 as a valid ID for VBE adapters. CORE-6773. #resolve #comment Should be fixed with r59207, thanks.
by jgardou@svn.reactos.org
Author: jgardou Date: Thu Jun 13 15:09:45 2013 New Revision: 59207 URL:
http://svn.reactos.org/svn/reactos?rev=59207&view=rev
Log: [INF] - recognize PCI\CC_0000 as a valid ID for VBE adapters. CORE-6773. #resolve #comment Should be fixed with r59207, thanks. Modified: trunk/reactos/boot/bootdata/hivesys.inf trunk/reactos/media/inf/display.inf Modified: trunk/reactos/boot/bootdata/hivesys.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/bootdata/hivesys.inf?…
============================================================================== --- trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] (original) +++ trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] Thu Jun 13 15:09:45 2013 @@ -60,6 +60,9 @@ HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\HID_DEVICE_SYSTEM_MOUSE","Service",0x00000000,"mouhid" HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\HID_DEVICE_SYSTEM_MOUSE","ClassGUID",0x00000000,"{4D36E96F-E325-11CE-BFC1-08002BE10318}" + +HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\PCI#CC_0000","Service",0x00000000,"VBE" +HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\PCI#CC_0000","ClassGUID",0x00000000,"{4D36E968-E325-11CE-BFC1-08002BE10318}" HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\PCI#CC_0001","Service",0x00000000,"VBE" HKLM,"SYSTEM\CurrentControlSet\Control\CriticalDeviceDatabase\PCI#CC_0001","ClassGUID",0x00000000,"{4D36E968-E325-11CE-BFC1-08002BE10318}" @@ -1553,7 +1556,7 @@ ; PCI Bus driver HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ErrorControl",0x00010001,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Group",0x00000000,"Boot Bus Extender" -HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ImagePath",0x00020000,"system32\drivers\pci.sys" +HKLM,"SYSTEM\CurrentControlSet\Services\Pci","ImagePath",0x00020000,"system32\drivers\pcix.sys" HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Start",0x00010001,0x00000000 HKLM,"SYSTEM\CurrentControlSet\Services\Pci","Type",0x00010001,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\Pci\Parameters","1045C621",0x00030003,04,00,00,00,00,00,00,00 Modified: trunk/reactos/media/inf/display.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/inf/display.inf?rev=…
============================================================================== Binary files - no diff available.
11 years, 3 months
1
0
0
0
[ekohl] 59206: [NETAPI32] NetLocalGroupSetInfo: Implement level 1.
by ekohl@svn.reactos.org
Author: ekohl Date: Wed Jun 12 21:37:31 2013 New Revision: 59206 URL:
http://svn.reactos.org/svn/reactos?rev=59206&view=rev
Log: [NETAPI32] NetLocalGroupSetInfo: Implement level 1. Modified: trunk/reactos/dll/win32/netapi32/local_group.c Modified: trunk/reactos/dll/win32/netapi32/local_group.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/local_g…
============================================================================== --- trunk/reactos/dll/win32/netapi32/local_group.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/netapi32/local_group.c [iso-8859-1] Wed Jun 12 21:37:31 2013 @@ -1718,7 +1718,7 @@ SAM_HANDLE DomainHandle = NULL; SAM_HANDLE AliasHandle = NULL; ALIAS_NAME_INFORMATION AliasNameInfo; - + ALIAS_ADM_COMMENT_INFORMATION AdminCommentInfo; NET_API_STATUS ApiStatus = NERR_Success; NTSTATUS Status = STATUS_SUCCESS; @@ -1808,6 +1808,22 @@ Status = SamSetInformationAlias(AliasHandle, AliasNameInformation, &AliasNameInfo); + if (!NT_SUCCESS(Status)) + { + TRACE("SamSetInformationAlias failed (ApiStatus %lu)\n", ApiStatus); + ApiStatus = NetpNtStatusToApiStatus(Status); + goto done; + } + break; + + case 1: + /* Set the alias admin comment */ + RtlInitUnicodeString(&AdminCommentInfo.AdminComment, + ((PLOCALGROUP_INFO_1)buf)->lgrpi1_comment); + + Status = SamSetInformationAlias(AliasHandle, + AliasAdminCommentInformation, + &AdminCommentInfo); if (!NT_SUCCESS(Status)) { TRACE("SamSetInformationAlias failed (ApiStatus %lu)\n", ApiStatus);
11 years, 3 months
1
0
0
0
[dreimer] 59205: Update for some German resource files by zehnvor.
by dreimer@svn.reactos.org
Author: dreimer Date: Tue Jun 11 22:21:49 2013 New Revision: 59205 URL:
http://svn.reactos.org/svn/reactos?rev=59205&view=rev
Log: Update for some German resource files by zehnvor. Modified: trunk/reactos/base/applications/taskmgr/lang/de-DE.rc trunk/reactos/dll/cpl/console/lang/de-DE.rc trunk/reactos/dll/cpl/desk/lang/de-DE.rc trunk/reactos/dll/cpl/input/lang/de-DE.rc trunk/reactos/dll/cpl/sysdm/lang/de-DE.rc trunk/reactos/dll/win32/syssetup/lang/de-DE.rc Modified: trunk/reactos/base/applications/taskmgr/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/taskmgr/…
============================================================================== --- trunk/reactos/base/applications/taskmgr/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/taskmgr/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -527,12 +527,12 @@ BLOCK "040904b0" BEGIN VALUE "CompanyName", "Brian Palmer\0" - VALUE "FileDescription", "Task Manager von Brian Palmer\0" + VALUE "FileDescription", "ReactOS Task-Manager von Brian Palmer\0" VALUE "FileVersion", "1.0.0.1\0" VALUE "InternalName", "taskmgr\0" VALUE "LegalCopyright", "Copyright © Brian Palmer 2000\0" VALUE "OriginalFilename", "taskmgr.exe\0" - VALUE "ProductName", "Task Manager von Brian Palmer\0" + VALUE "ProductName", "ReactOS Task-Manager\0" VALUE "ProductVersion", "1.0.0.1\0" END END Modified: trunk/reactos/dll/cpl/console/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/console/lang/de-DE…
============================================================================== --- trunk/reactos/dll/cpl/console/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/console/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -2,7 +2,7 @@ * PROJECT: ReactOS Console Configuration DLL * LICENSE: GPL - See COPYING in the top level directory * FILE: dll/win32/console/de-DE.rc - * PURPOSE: English resource file + * PURPOSE: German resource file * PROGRAMMERS: Daniel Reimer (reimer.daniel(a)freenet.de) */ @@ -47,12 +47,12 @@ LTEXT "&Schrift", -1, 10, 105, 35, 10 CHECKBOX "&Fette Schriften", IDC_CHECK_BOLD_FONTS, 45, 105, 60, 10 LISTBOX IDC_LBOX_TYPE, 10, 120, 110, 50, LBS_DISABLENOSCROLL | WS_VSCROLL - GROUPBOX "", IDC_GROUPBOX_FONT_NAME, 10, 155, 200, 50 - CONTROL "", IDC_STATIC_SELECT_FONT_PREVIEW, "Static", SS_OWNERDRAW | SS_SUNKEN, 15, 165, 95, 35 - LTEXT "Jedes Zeichen ist:", -1, 130, 165, 75, 10 - LTEXT "Bildschirmpixeö breit\nBildschirmpixel hoch", -1, 140, 180, 65, 20 - LTEXT "", IDC_FONT_SIZE_X, 125, 180, 10, 10 - LTEXT "", IDC_FONT_SIZE_Y, 125, 188, 10, 10 + GROUPBOX "", IDC_GROUPBOX_FONT_NAME, 10, 155, 200, 50 + CONTROL "", IDC_STATIC_SELECT_FONT_PREVIEW, "Static", SS_OWNERDRAW | SS_SUNKEN, 15, 165, 95, 35 + LTEXT "Jedes Zeichen ist:", -1, 130, 165, 75, 10 + LTEXT "Bildschirmpixel breit\nBildschirmpixel hoch", -1, 140, 180, 65, 20 + LTEXT "", IDC_FONT_SIZE_X, 125, 180, 10, 10 + LTEXT "", IDC_FONT_SIZE_Y, 125, 188, 10, 10 END IDD_PROPPAGELAYOUT DIALOGEX 0, 0, 250, 220 @@ -92,13 +92,13 @@ FONT 8, "MS Shell Dlg" BEGIN CONTROL "Fenster&text", IDC_RADIO_SCREEN_TEXT, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 15, 90, 10 - CONTROL "Fenster&hintergrund", IDC_RADIO_SCREEN_BACKGROUND, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 25, 90, 10 - CONTROL "&Popuptext", IDC_RADIO_POPUP_TEXT, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 35, 90, 10 - CONTROL "Pop&uphintergrund", IDC_RADIO_POPUP_BACKGROUND, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 45, 90, 10 - GROUPBOX "Selected Color Components", -1, 120, 15, 90, 45 - LTEXT "&Rot:", -1, 125, 25, 30, 10 - EDITTEXT IDC_EDIT_COLOR_RED, 150, 25, 30, 10, ES_RIGHT | ES_NUMBER | WS_GROUP - CONTROL "", IDC_UPDOWN_COLOR_RED, UPDOWN_CLASS, UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | WS_GROUP, 165, 25, 30, 10 + CONTROL "Fenster&hintergrund", IDC_RADIO_SCREEN_BACKGROUND, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 25, 90, 10 + CONTROL "&Popuptext", IDC_RADIO_POPUP_TEXT, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 35, 90, 10 + CONTROL "Pop&uphintergrund", IDC_RADIO_POPUP_BACKGROUND, "Button", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 15, 45, 90, 10 + GROUPBOX "Farbkomponenten", -1, 120, 15, 90, 45 + LTEXT "&Rot:", -1, 125, 25, 30, 10 + EDITTEXT IDC_EDIT_COLOR_RED, 150, 25, 30, 10, ES_RIGHT | ES_NUMBER | WS_GROUP + CONTROL "", IDC_UPDOWN_COLOR_RED, UPDOWN_CLASS, UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | WS_GROUP, 165, 25, 30, 10 LTEXT "&Grün:", -1, 125, 35, 30, 10 EDITTEXT IDC_EDIT_COLOR_GREEN, 150, 35, 30, 10, ES_RIGHT | ES_NUMBER | WS_GROUP CONTROL "", IDC_UPDOWN_COLOR_GREEN, UPDOWN_CLASS, UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | WS_GROUP, 165, 35, 30, 10 Modified: trunk/reactos/dll/cpl/desk/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/de-DE.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -51,11 +51,11 @@ BEGIN CONTROL "", IDC_APPEARANCE_PREVIEW, "PreviewWndClass", WS_VISIBLE | WS_BORDER, 7, 7, 232, 120 - LTEXT "Visual Style", IDC_STATIC, 7, 130, 64, 7 + LTEXT "Fenster und Schaltflächen", IDC_STATIC, 7, 130, 64, 7 COMBOBOX IDC_APPEARANCE_VISUAL_STYLE, 7, 140, 134, 90, CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_SORT | WS_VSCROLL | WS_TABSTOP LTEXT "Farbschema", IDC_STATIC, 7, 160, 64, 7 COMBOBOX IDC_APPEARANCE_COLORSCHEME, 7, 170, 134, 90, CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "Size", IDC_STATIC, 7, 190, 64, 7 + LTEXT "SchriftgröÃe", IDC_STATIC, 7, 190, 64, 7 COMBOBOX IDC_APPEARANCE_SIZE, 7, 200, 134, 90, CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_SORT | WS_VSCROLL | WS_TABSTOP PUSHBUTTON "&Effekte...", IDC_APPEARANCE_EFFECTS, 182, 150, 56, 15 PUSHBUTTON "Erweitert", IDC_APPEARANCE_ADVANCED, 182, 170, 56, 15 @@ -213,9 +213,9 @@ BEGIN IDS_COLOR_4BIT "16 Farben" IDS_COLOR_8BIT "256 Farben" - IDS_COLOR_16BIT "High Color (16 Bit)" - IDS_COLOR_24BIT "True Color (24 Bit)" - IDS_COLOR_32BIT "True Color (32 Bit)" + IDS_COLOR_16BIT "Mittlere (16 Bit)" + IDS_COLOR_24BIT "Hoch (24 Bit)" + IDS_COLOR_32BIT "Höchste (32 Bit)" IDS_PIXEL "%lux%lu Pixel" END @@ -233,7 +233,7 @@ IDS_MESSBOX "Dialogfeld" IDS_MESSTEXT "Dialogfeldtext" IDS_BUTTEXT "OK" - IDS_CLASSIC_THEME "Classic Theme" + IDS_CLASSIC_THEME "Klassischer Stil" END STRINGTABLE DISCARDABLE Modified: trunk/reactos/dll/cpl/input/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/input/lang/de-DE.r…
============================================================================== --- trunk/reactos/dll/cpl/input/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/input/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -17,12 +17,12 @@ IDD_PROPPAGEADVANCEDSETTINGS DIALOGEX 0, 0, 254, 228 STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION -CAPTION "Advanced Settings" +CAPTION "Erweiterte Einstellungen" FONT 8, "MS Shell Dlg" BEGIN GROUPBOX "System Configuration", -1, 7, 7, 240, 70 - AUTOCHECKBOX "&Turn off advanced text services", IDC_TURNOFFTEXTSVCS_CB, 14, 20, 130, 12 - LTEXT "Select this check box to turn off advanced text services in all programs.\nThis is not recommended for East Asian users because this closes the language bar.", -1, 14, 40, 230, 35 + AUTOCHECKBOX "&Erweiterte &Textdienste deaktivieren", IDC_TURNOFFTEXTSVCS_CB, 14, 20, 130, 12 + LTEXT "Auswählen, um die erweiterte Sprachunterstützung in allen Programmen zu deaktivieren.\nNicht empfohlen für ostasiatische Benutzer, da die Sprachleiste hierdurch geschlossen wird.", -1, 14, 40, 230, 35 END IDD_KEYSETTINGS DIALOGEX 0, 0, 272, 163 Modified: trunk/reactos/dll/cpl/sysdm/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/sysdm/lang/de-DE.r…
============================================================================== --- trunk/reactos/dll/cpl/sysdm/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/sysdm/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -26,7 +26,7 @@ LTEXT "", IDC_MACHINELINE3, 130, 162, 118, 9 LTEXT "", IDC_MACHINELINE4, 130, 171, 118, 9 LTEXT "", IDC_MACHINELINE5, 130, 180, 118, 9 - CONTROL "<A HREF=""
http://www.reactos.de/
"">ReactOS-Homepage</A> besuchen", IDC_ROSHOMEPAGE_LINK, "SysLink", WS_CHILD | WS_VISIBLE | WS_TABSTOP, 20, 200, 100, 10 + CONTROL "<A HREF=""
http://www.reactos.org/
"">ReactOS-Homepage</A> besuchen", IDC_ROSHOMEPAGE_LINK, "SysLink", WS_CHILD | WS_VISIBLE | WS_TABSTOP, 20, 200, 100, 10 PUSHBUTTON "&Lizenz anzeigen...", IDC_LICENCE, 170, 199, 78, 14 END @@ -71,7 +71,7 @@ LTEXT "Start- und Wiederherstellungseinstellungen regeln, wie der Computer gestartet werden soll und was passieren soll, wenn ein Fehler auftritt.", IDC_STATIC, 16, 144, 210, 27 PUSHBUTTON "Einstellungen", IDC_STAREC, 194, 162, 50, 14 - PUSHBUTTON "System Settings", IDC_SYSSETTINGS, 2, 192, 80, 15//FIXME + PUSHBUTTON "Systemeinstellungen", IDC_SYSSETTINGS, 2, 192, 80, 15//FIXME PUSHBUTTON "Umgebungsvariablen", IDC_ENVVAR, 84, 192, 80, 14 PUSHBUTTON "Fehler melden", IDC_ERRORREPORT, 170, 192, 80, 14 END Modified: trunk/reactos/dll/win32/syssetup/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/syssetup/lang/de…
============================================================================== --- trunk/reactos/dll/win32/syssetup/lang/de-DE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/win32/syssetup/lang/de-DE.rc [iso-8859-1] Tue Jun 11 22:21:49 2013 @@ -40,7 +40,7 @@ IDC_STATIC,15,7,286,19 LISTBOX IDC_PROJECTS,15,30,286,75,LBS_NOSEL | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | WS_VSCROLL - LTEXT "ReactOS ist unter der GNU General Public License (GPL) veröffentlicht. Wenn Sie ReactOS oder Teile davon wiederverwenden oder wiederveröffentlichen wollen, müssen Sie die Bestimmungen der GPL anerkennen.", + LTEXT "ReactOS ist unter der GNU General Public License (GPL) veröffentlicht. Wenn Sie ReactOS oder Teile davon weiterverwenden wollen, müssen Sie die Bestimmungen der GPL anerkennen.", IDC_STATIC,15,110,227,24 PUSHBUTTON "GPL &ansehen...",IDC_VIEWGPL,251,110,55,19 LTEXT "Klicken Sie auf Weiter, um mit der Einrichtung fortzufahren.",IDC_STATIC,15,136,
11 years, 3 months
1
0
0
0
← Newer
1
...
17
18
19
20
21
22
23
...
28
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
Results per page:
10
25
50
100
200