mirror of
https://github.com/reactos/reactos.git
synced 2024-07-01 10:20:03 +00:00
[USETUP] Factor out the UI-specific code from the GenList code, and wrap it inside a GENERIC_LIST_UI structure.
The aim here is to decouple the UI-specific code from code that can be used by both the text-mode USETUP and a future 1st-stage GUI setup. Indeed, the GenLists can actually be used in the 1st-stage GUI; and their contents be displayed inside ListBoxes/ListViews... (this is just one example amongst others). Additionally (in usetup.c): - Make both FormatPartitionPage and CheckFileSystemPage return PAGE_NUMBERs. - Improve a couple of comments. svn path=/branches/setup_improvements/; revision=74553
This commit is contained in:
parent
199fb91939
commit
92692eae3d
|
@ -38,7 +38,7 @@ typedef struct _GENERIC_LIST_ENTRY
|
||||||
LIST_ENTRY Entry;
|
LIST_ENTRY Entry;
|
||||||
PGENERIC_LIST List;
|
PGENERIC_LIST List;
|
||||||
PVOID UserData;
|
PVOID UserData;
|
||||||
CHAR Text[1];
|
CHAR Text[1]; // FIXME: UI stuff
|
||||||
} GENERIC_LIST_ENTRY;
|
} GENERIC_LIST_ENTRY;
|
||||||
|
|
||||||
|
|
||||||
|
@ -47,18 +47,11 @@ typedef struct _GENERIC_LIST
|
||||||
LIST_ENTRY ListHead;
|
LIST_ENTRY ListHead;
|
||||||
ULONG NumOfEntries;
|
ULONG NumOfEntries;
|
||||||
|
|
||||||
PLIST_ENTRY FirstShown;
|
|
||||||
PLIST_ENTRY LastShown;
|
|
||||||
SHORT Left;
|
|
||||||
SHORT Top;
|
|
||||||
SHORT Right;
|
|
||||||
SHORT Bottom;
|
|
||||||
BOOL Redraw;
|
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY CurrentEntry;
|
PGENERIC_LIST_ENTRY CurrentEntry;
|
||||||
PGENERIC_LIST_ENTRY BackupEntry;
|
PGENERIC_LIST_ENTRY BackupEntry;
|
||||||
} GENERIC_LIST;
|
} GENERIC_LIST;
|
||||||
|
|
||||||
|
|
||||||
PGENERIC_LIST
|
PGENERIC_LIST
|
||||||
CreateGenericList(VOID)
|
CreateGenericList(VOID)
|
||||||
{
|
{
|
||||||
|
@ -73,23 +66,16 @@ CreateGenericList(VOID)
|
||||||
InitializeListHead(&List->ListHead);
|
InitializeListHead(&List->ListHead);
|
||||||
List->NumOfEntries = 0;
|
List->NumOfEntries = 0;
|
||||||
|
|
||||||
List->Left = 0;
|
|
||||||
List->Top = 0;
|
|
||||||
List->Right = 0;
|
|
||||||
List->Bottom = 0;
|
|
||||||
List->Redraw = TRUE;
|
|
||||||
|
|
||||||
List->CurrentEntry = NULL;
|
List->CurrentEntry = NULL;
|
||||||
List->BackupEntry = NULL;
|
List->BackupEntry = NULL;
|
||||||
|
|
||||||
return List;
|
return List;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
DestroyGenericList(
|
DestroyGenericList(
|
||||||
PGENERIC_LIST List,
|
IN OUT PGENERIC_LIST List,
|
||||||
BOOLEAN FreeUserData)
|
IN BOOLEAN FreeUserData)
|
||||||
{
|
{
|
||||||
PGENERIC_LIST_ENTRY ListEntry;
|
PGENERIC_LIST_ENTRY ListEntry;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
|
@ -112,13 +98,12 @@ DestroyGenericList(
|
||||||
RtlFreeHeap (ProcessHeap, 0, List);
|
RtlFreeHeap (ProcessHeap, 0, List);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
AppendGenericListEntry(
|
AppendGenericListEntry(
|
||||||
PGENERIC_LIST List,
|
IN OUT PGENERIC_LIST List,
|
||||||
PCHAR Text,
|
IN PCHAR Text,
|
||||||
PVOID UserData,
|
IN PVOID UserData,
|
||||||
BOOLEAN Current)
|
IN BOOLEAN Current)
|
||||||
{
|
{
|
||||||
PGENERIC_LIST_ENTRY Entry;
|
PGENERIC_LIST_ENTRY Entry;
|
||||||
|
|
||||||
|
@ -145,18 +130,34 @@ AppendGenericListEntry(
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
VOID
|
||||||
|
InitGenericListUi(
|
||||||
|
IN OUT PGENERIC_LIST_UI ListUi,
|
||||||
|
IN PGENERIC_LIST List)
|
||||||
|
{
|
||||||
|
ListUi->List = List;
|
||||||
|
ListUi->FirstShown = NULL;
|
||||||
|
ListUi->LastShown = NULL;
|
||||||
|
|
||||||
|
ListUi->Left = 0;
|
||||||
|
ListUi->Top = 0;
|
||||||
|
ListUi->Right = 0;
|
||||||
|
ListUi->Bottom = 0;
|
||||||
|
ListUi->Redraw = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
static
|
static
|
||||||
VOID
|
VOID
|
||||||
DrawListFrame(
|
DrawListFrame(
|
||||||
PGENERIC_LIST GenericList)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
COORD coPos;
|
COORD coPos;
|
||||||
DWORD Written;
|
DWORD Written;
|
||||||
SHORT i;
|
SHORT i;
|
||||||
|
|
||||||
/* Draw upper left corner */
|
/* Draw upper left corner */
|
||||||
coPos.X = GenericList->Left;
|
coPos.X = ListUi->Left;
|
||||||
coPos.Y = GenericList->Top;
|
coPos.Y = ListUi->Top;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xDA, // '+',
|
0xDA, // '+',
|
||||||
1,
|
1,
|
||||||
|
@ -164,17 +165,17 @@ DrawListFrame(
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
/* Draw upper edge */
|
/* Draw upper edge */
|
||||||
coPos.X = GenericList->Left + 1;
|
coPos.X = ListUi->Left + 1;
|
||||||
coPos.Y = GenericList->Top;
|
coPos.Y = ListUi->Top;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xC4, // '-',
|
0xC4, // '-',
|
||||||
GenericList->Right - GenericList->Left - 1,
|
ListUi->Right - ListUi->Left - 1,
|
||||||
coPos,
|
coPos,
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
/* Draw upper right corner */
|
/* Draw upper right corner */
|
||||||
coPos.X = GenericList->Right;
|
coPos.X = ListUi->Right;
|
||||||
coPos.Y = GenericList->Top;
|
coPos.Y = ListUi->Top;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xBF, // '+',
|
0xBF, // '+',
|
||||||
1,
|
1,
|
||||||
|
@ -182,9 +183,9 @@ DrawListFrame(
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
/* Draw left and right edge */
|
/* Draw left and right edge */
|
||||||
for (i = GenericList->Top + 1; i < GenericList->Bottom; i++)
|
for (i = ListUi->Top + 1; i < ListUi->Bottom; i++)
|
||||||
{
|
{
|
||||||
coPos.X = GenericList->Left;
|
coPos.X = ListUi->Left;
|
||||||
coPos.Y = i;
|
coPos.Y = i;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xB3, // '|',
|
0xB3, // '|',
|
||||||
|
@ -192,7 +193,7 @@ DrawListFrame(
|
||||||
coPos,
|
coPos,
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
coPos.X = GenericList->Right;
|
coPos.X = ListUi->Right;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xB3, //'|',
|
0xB3, //'|',
|
||||||
1,
|
1,
|
||||||
|
@ -201,8 +202,8 @@ DrawListFrame(
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Draw lower left corner */
|
/* Draw lower left corner */
|
||||||
coPos.X = GenericList->Left;
|
coPos.X = ListUi->Left;
|
||||||
coPos.Y = GenericList->Bottom;
|
coPos.Y = ListUi->Bottom;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xC0, // '+',
|
0xC0, // '+',
|
||||||
1,
|
1,
|
||||||
|
@ -210,17 +211,17 @@ DrawListFrame(
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
/* Draw lower edge */
|
/* Draw lower edge */
|
||||||
coPos.X = GenericList->Left + 1;
|
coPos.X = ListUi->Left + 1;
|
||||||
coPos.Y = GenericList->Bottom;
|
coPos.Y = ListUi->Bottom;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xC4, // '-',
|
0xC4, // '-',
|
||||||
GenericList->Right - GenericList->Left - 1,
|
ListUi->Right - ListUi->Left - 1,
|
||||||
coPos,
|
coPos,
|
||||||
&Written);
|
&Written);
|
||||||
|
|
||||||
/* Draw lower right corner */
|
/* Draw lower right corner */
|
||||||
coPos.X = GenericList->Right;
|
coPos.X = ListUi->Right;
|
||||||
coPos.Y = GenericList->Bottom;
|
coPos.Y = ListUi->Bottom;
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
0xD9, // '+',
|
0xD9, // '+',
|
||||||
1,
|
1,
|
||||||
|
@ -232,29 +233,30 @@ DrawListFrame(
|
||||||
static
|
static
|
||||||
VOID
|
VOID
|
||||||
DrawListEntries(
|
DrawListEntries(
|
||||||
PGENERIC_LIST GenericList)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PGENERIC_LIST_ENTRY ListEntry;
|
PGENERIC_LIST_ENTRY ListEntry;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
COORD coPos;
|
COORD coPos;
|
||||||
DWORD Written;
|
DWORD Written;
|
||||||
USHORT Width;
|
USHORT Width;
|
||||||
|
|
||||||
coPos.X = GenericList->Left + 1;
|
coPos.X = ListUi->Left + 1;
|
||||||
coPos.Y = GenericList->Top + 1;
|
coPos.Y = ListUi->Top + 1;
|
||||||
Width = GenericList->Right - GenericList->Left - 1;
|
Width = ListUi->Right - ListUi->Left - 1;
|
||||||
|
|
||||||
Entry = GenericList->FirstShown;
|
Entry = ListUi->FirstShown;
|
||||||
while (Entry != &GenericList->ListHead)
|
while (Entry != &List->ListHead)
|
||||||
{
|
{
|
||||||
ListEntry = CONTAINING_RECORD (Entry, GENERIC_LIST_ENTRY, Entry);
|
ListEntry = CONTAINING_RECORD (Entry, GENERIC_LIST_ENTRY, Entry);
|
||||||
|
|
||||||
if (coPos.Y == GenericList->Bottom)
|
if (coPos.Y == ListUi->Bottom)
|
||||||
break;
|
break;
|
||||||
GenericList->LastShown = Entry;
|
ListUi->LastShown = Entry;
|
||||||
|
|
||||||
FillConsoleOutputAttribute (StdOutput,
|
FillConsoleOutputAttribute (StdOutput,
|
||||||
(GenericList->CurrentEntry == ListEntry) ?
|
(List->CurrentEntry == ListEntry) ?
|
||||||
FOREGROUND_BLUE | BACKGROUND_WHITE :
|
FOREGROUND_BLUE | BACKGROUND_WHITE :
|
||||||
FOREGROUND_WHITE | BACKGROUND_BLUE,
|
FOREGROUND_WHITE | BACKGROUND_BLUE,
|
||||||
Width,
|
Width,
|
||||||
|
@ -279,7 +281,7 @@ DrawListEntries(
|
||||||
Entry = Entry->Flink;
|
Entry = Entry->Flink;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (coPos.Y < GenericList->Bottom)
|
while (coPos.Y < ListUi->Bottom)
|
||||||
{
|
{
|
||||||
FillConsoleOutputAttribute (StdOutput,
|
FillConsoleOutputAttribute (StdOutput,
|
||||||
FOREGROUND_WHITE | BACKGROUND_BLUE,
|
FOREGROUND_WHITE | BACKGROUND_BLUE,
|
||||||
|
@ -300,15 +302,16 @@ DrawListEntries(
|
||||||
static
|
static
|
||||||
VOID
|
VOID
|
||||||
DrawScrollBarGenericList(
|
DrawScrollBarGenericList(
|
||||||
PGENERIC_LIST GenericList)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
COORD coPos;
|
COORD coPos;
|
||||||
DWORD Written;
|
DWORD Written;
|
||||||
|
|
||||||
coPos.X = GenericList->Right + 1;
|
coPos.X = ListUi->Right + 1;
|
||||||
coPos.Y = GenericList->Top;
|
coPos.Y = ListUi->Top;
|
||||||
|
|
||||||
if (GenericList->FirstShown != GenericList->ListHead.Flink)
|
if (ListUi->FirstShown != List->ListHead.Flink)
|
||||||
{
|
{
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
'\x18',
|
'\x18',
|
||||||
|
@ -325,8 +328,8 @@ DrawScrollBarGenericList(
|
||||||
&Written);
|
&Written);
|
||||||
}
|
}
|
||||||
|
|
||||||
coPos.Y = GenericList->Bottom;
|
coPos.Y = ListUi->Bottom;
|
||||||
if (GenericList->LastShown != GenericList->ListHead.Blink)
|
if (ListUi->LastShown != List->ListHead.Blink)
|
||||||
{
|
{
|
||||||
FillConsoleOutputCharacterA (StdOutput,
|
FillConsoleOutputCharacterA (StdOutput,
|
||||||
'\x19',
|
'\x19',
|
||||||
|
@ -348,18 +351,22 @@ DrawScrollBarGenericList(
|
||||||
static
|
static
|
||||||
VOID
|
VOID
|
||||||
CenterCurrentListItem(
|
CenterCurrentListItem(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
ULONG MaxVisibleItems, ItemCount, i;
|
ULONG MaxVisibleItems, ItemCount, i;
|
||||||
|
|
||||||
if ((List->Top == 0 && List->Bottom == 0) ||
|
if ((ListUi->Top == 0 && ListUi->Bottom == 0) ||
|
||||||
IsListEmpty(&List->ListHead) ||
|
IsListEmpty(&List->ListHead) ||
|
||||||
List->CurrentEntry == NULL)
|
List->CurrentEntry == NULL)
|
||||||
|
{
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
MaxVisibleItems = (ULONG)(List->Bottom - List->Top - 1);
|
MaxVisibleItems = (ULONG)(ListUi->Bottom - ListUi->Top - 1);
|
||||||
|
|
||||||
|
/*****************************************
|
||||||
ItemCount = 0;
|
ItemCount = 0;
|
||||||
Entry = List->ListHead.Flink;
|
Entry = List->ListHead.Flink;
|
||||||
while (Entry != &List->ListHead)
|
while (Entry != &List->ListHead)
|
||||||
|
@ -367,6 +374,8 @@ CenterCurrentListItem(
|
||||||
ItemCount++;
|
ItemCount++;
|
||||||
Entry = Entry->Flink;
|
Entry = Entry->Flink;
|
||||||
}
|
}
|
||||||
|
*****************************************/
|
||||||
|
ItemCount = List->NumOfEntries; // GetNumberOfListEntries(List);
|
||||||
|
|
||||||
if (ItemCount > MaxVisibleItems)
|
if (ItemCount > MaxVisibleItems)
|
||||||
{
|
{
|
||||||
|
@ -377,7 +386,7 @@ CenterCurrentListItem(
|
||||||
Entry = Entry->Blink;
|
Entry = Entry->Blink;
|
||||||
}
|
}
|
||||||
|
|
||||||
List->FirstShown = Entry;
|
ListUi->FirstShown = Entry;
|
||||||
|
|
||||||
for (i = 0; i < MaxVisibleItems; i++)
|
for (i = 0; i < MaxVisibleItems; i++)
|
||||||
{
|
{
|
||||||
|
@ -385,87 +394,90 @@ CenterCurrentListItem(
|
||||||
Entry = Entry->Flink;
|
Entry = Entry->Flink;
|
||||||
}
|
}
|
||||||
|
|
||||||
List->LastShown = Entry;
|
ListUi->LastShown = Entry;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
DrawGenericList(
|
DrawGenericList(
|
||||||
PGENERIC_LIST List,
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
SHORT Left,
|
IN SHORT Left,
|
||||||
SHORT Top,
|
IN SHORT Top,
|
||||||
SHORT Right,
|
IN SHORT Right,
|
||||||
SHORT Bottom)
|
IN SHORT Bottom)
|
||||||
{
|
{
|
||||||
List->FirstShown = List->ListHead.Flink;
|
PGENERIC_LIST List = ListUi->List;
|
||||||
List->Left = Left;
|
|
||||||
List->Top = Top;
|
|
||||||
List->Right = Right;
|
|
||||||
List->Bottom = Bottom;
|
|
||||||
|
|
||||||
DrawListFrame(List);
|
ListUi->FirstShown = List->ListHead.Flink;
|
||||||
|
ListUi->Left = Left;
|
||||||
|
ListUi->Top = Top;
|
||||||
|
ListUi->Right = Right;
|
||||||
|
ListUi->Bottom = Bottom;
|
||||||
|
|
||||||
|
DrawListFrame(ListUi);
|
||||||
|
|
||||||
if (IsListEmpty(&List->ListHead))
|
if (IsListEmpty(&List->ListHead))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
CenterCurrentListItem(List);
|
CenterCurrentListItem(ListUi);
|
||||||
|
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
ScrollPageDownGenericList(
|
ScrollPageDownGenericList(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
SHORT i;
|
SHORT i;
|
||||||
|
|
||||||
/* Suspend auto-redraw */
|
/* Suspend auto-redraw */
|
||||||
List->Redraw = FALSE;
|
ListUi->Redraw = FALSE;
|
||||||
|
|
||||||
for (i = List->Top + 1; i < List->Bottom - 1; i++)
|
for (i = ListUi->Top + 1; i < ListUi->Bottom - 1; i++)
|
||||||
{
|
{
|
||||||
ScrollDownGenericList (List);
|
ScrollDownGenericList(ListUi);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Update user interface */
|
/* Update user interface */
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
|
|
||||||
/* Re enable auto-redraw */
|
/* Re enable auto-redraw */
|
||||||
List->Redraw = TRUE;
|
ListUi->Redraw = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
ScrollPageUpGenericList(
|
ScrollPageUpGenericList(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
SHORT i;
|
SHORT i;
|
||||||
|
|
||||||
/* Suspend auto-redraw */
|
/* Suspend auto-redraw */
|
||||||
List->Redraw = FALSE;
|
ListUi->Redraw = FALSE;
|
||||||
|
|
||||||
for (i = List->Bottom - 1; i > List->Top + 1; i--)
|
for (i = ListUi->Bottom - 1; i > ListUi->Top + 1; i--)
|
||||||
{
|
{
|
||||||
ScrollUpGenericList (List);
|
ScrollUpGenericList(ListUi);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Update user interface */
|
/* Update user interface */
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
|
|
||||||
/* Re enable auto-redraw */
|
/* Re enable auto-redraw */
|
||||||
List->Redraw = TRUE;
|
ListUi->Redraw = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
ScrollDownGenericList(
|
ScrollDownGenericList(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
|
|
||||||
if (List->CurrentEntry == NULL)
|
if (List->CurrentEntry == NULL)
|
||||||
|
@ -474,17 +486,17 @@ ScrollDownGenericList(
|
||||||
if (List->CurrentEntry->Entry.Flink != &List->ListHead)
|
if (List->CurrentEntry->Entry.Flink != &List->ListHead)
|
||||||
{
|
{
|
||||||
Entry = List->CurrentEntry->Entry.Flink;
|
Entry = List->CurrentEntry->Entry.Flink;
|
||||||
if (List->LastShown == &List->CurrentEntry->Entry)
|
if (ListUi->LastShown == &List->CurrentEntry->Entry)
|
||||||
{
|
{
|
||||||
List->FirstShown = List->FirstShown->Flink;
|
ListUi->FirstShown = ListUi->FirstShown->Flink;
|
||||||
List->LastShown = List->LastShown->Flink;
|
ListUi->LastShown = ListUi->LastShown->Flink;
|
||||||
}
|
}
|
||||||
List->CurrentEntry = CONTAINING_RECORD (Entry, GENERIC_LIST_ENTRY, Entry);
|
List->CurrentEntry = CONTAINING_RECORD(Entry, GENERIC_LIST_ENTRY, Entry);
|
||||||
|
|
||||||
if (List->Redraw)
|
if (ListUi->Redraw)
|
||||||
{
|
{
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -492,9 +504,10 @@ ScrollDownGenericList(
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
ScrollToPositionGenericList(
|
ScrollToPositionGenericList(
|
||||||
PGENERIC_LIST List,
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
ULONG uIndex)
|
IN ULONG uIndex)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
ULONG uCount = 0;
|
ULONG uCount = 0;
|
||||||
|
|
||||||
|
@ -506,29 +519,30 @@ ScrollToPositionGenericList(
|
||||||
if (List->CurrentEntry->Entry.Flink != &List->ListHead)
|
if (List->CurrentEntry->Entry.Flink != &List->ListHead)
|
||||||
{
|
{
|
||||||
Entry = List->CurrentEntry->Entry.Flink;
|
Entry = List->CurrentEntry->Entry.Flink;
|
||||||
if (List->LastShown == &List->CurrentEntry->Entry)
|
if (ListUi->LastShown == &List->CurrentEntry->Entry)
|
||||||
{
|
{
|
||||||
List->FirstShown = List->FirstShown->Flink;
|
ListUi->FirstShown = ListUi->FirstShown->Flink;
|
||||||
List->LastShown = List->LastShown->Flink;
|
ListUi->LastShown = ListUi->LastShown->Flink;
|
||||||
}
|
}
|
||||||
List->CurrentEntry = CONTAINING_RECORD (Entry, GENERIC_LIST_ENTRY, Entry);
|
List->CurrentEntry = CONTAINING_RECORD(Entry, GENERIC_LIST_ENTRY, Entry);
|
||||||
}
|
}
|
||||||
uCount++;
|
uCount++;
|
||||||
}
|
}
|
||||||
while (uIndex != uCount);
|
while (uIndex != uCount);
|
||||||
|
|
||||||
if (List->Redraw)
|
if (ListUi->Redraw)
|
||||||
{
|
{
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
ScrollUpGenericList(
|
ScrollUpGenericList(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PLIST_ENTRY Entry;
|
PLIST_ENTRY Entry;
|
||||||
|
|
||||||
if (List->CurrentEntry == NULL)
|
if (List->CurrentEntry == NULL)
|
||||||
|
@ -537,17 +551,17 @@ ScrollUpGenericList(
|
||||||
if (List->CurrentEntry->Entry.Blink != &List->ListHead)
|
if (List->CurrentEntry->Entry.Blink != &List->ListHead)
|
||||||
{
|
{
|
||||||
Entry = List->CurrentEntry->Entry.Blink;
|
Entry = List->CurrentEntry->Entry.Blink;
|
||||||
if (List->FirstShown == &List->CurrentEntry->Entry)
|
if (ListUi->FirstShown == &List->CurrentEntry->Entry)
|
||||||
{
|
{
|
||||||
List->FirstShown = List->FirstShown->Blink;
|
ListUi->FirstShown = ListUi->FirstShown->Blink;
|
||||||
List->LastShown = List->LastShown->Blink;
|
ListUi->LastShown = ListUi->LastShown->Blink;
|
||||||
}
|
}
|
||||||
List->CurrentEntry = CONTAINING_RECORD (Entry, GENERIC_LIST_ENTRY, Entry);
|
List->CurrentEntry = CONTAINING_RECORD(Entry, GENERIC_LIST_ENTRY, Entry);
|
||||||
|
|
||||||
if (List->Redraw)
|
if (ListUi->Redraw)
|
||||||
{
|
{
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -555,23 +569,24 @@ ScrollUpGenericList(
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
RedrawGenericList(
|
RedrawGenericList(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST_UI ListUi)
|
||||||
{
|
{
|
||||||
if (List->CurrentEntry == NULL)
|
if (ListUi->List->CurrentEntry == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (List->Redraw)
|
if (ListUi->Redraw)
|
||||||
{
|
{
|
||||||
DrawListEntries(List);
|
DrawListEntries(ListUi);
|
||||||
DrawScrollBarGenericList(List);
|
DrawScrollBarGenericList(ListUi);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
SetCurrentListEntry(
|
SetCurrentListEntry(
|
||||||
PGENERIC_LIST List,
|
IN PGENERIC_LIST List,
|
||||||
PGENERIC_LIST_ENTRY Entry)
|
IN PGENERIC_LIST_ENTRY Entry)
|
||||||
{
|
{
|
||||||
if (Entry->List != List)
|
if (Entry->List != List)
|
||||||
return;
|
return;
|
||||||
|
@ -581,7 +596,7 @@ SetCurrentListEntry(
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetCurrentListEntry(
|
GetCurrentListEntry(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
return List->CurrentEntry;
|
return List->CurrentEntry;
|
||||||
}
|
}
|
||||||
|
@ -589,7 +604,7 @@ GetCurrentListEntry(
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetFirstListEntry(
|
GetFirstListEntry(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
PLIST_ENTRY Entry = List->ListHead.Flink;
|
PLIST_ENTRY Entry = List->ListHead.Flink;
|
||||||
|
|
||||||
|
@ -601,7 +616,7 @@ GetFirstListEntry(
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetNextListEntry(
|
GetNextListEntry(
|
||||||
PGENERIC_LIST_ENTRY Entry)
|
IN PGENERIC_LIST_ENTRY Entry)
|
||||||
{
|
{
|
||||||
PLIST_ENTRY Next = Entry->Entry.Flink;
|
PLIST_ENTRY Next = Entry->Entry.Flink;
|
||||||
|
|
||||||
|
@ -613,7 +628,7 @@ GetNextListEntry(
|
||||||
|
|
||||||
PVOID
|
PVOID
|
||||||
GetListEntryUserData(
|
GetListEntryUserData(
|
||||||
PGENERIC_LIST_ENTRY Entry)
|
IN PGENERIC_LIST_ENTRY Entry)
|
||||||
{
|
{
|
||||||
return Entry->UserData;
|
return Entry->UserData;
|
||||||
}
|
}
|
||||||
|
@ -621,7 +636,7 @@ GetListEntryUserData(
|
||||||
|
|
||||||
LPCSTR
|
LPCSTR
|
||||||
GetListEntryText(
|
GetListEntryText(
|
||||||
PGENERIC_LIST_ENTRY Entry)
|
IN PGENERIC_LIST_ENTRY Entry)
|
||||||
{
|
{
|
||||||
return Entry->Text;
|
return Entry->Text;
|
||||||
}
|
}
|
||||||
|
@ -629,40 +644,42 @@ GetListEntryText(
|
||||||
|
|
||||||
ULONG
|
ULONG
|
||||||
GetNumberOfListEntries(
|
GetNumberOfListEntries(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
return List->NumOfEntries;
|
return List->NumOfEntries;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
GenericListKeyPress(
|
GenericListKeyPress(
|
||||||
PGENERIC_LIST GenericList,
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
CHAR AsciiChar)
|
IN CHAR AsciiChar)
|
||||||
{
|
{
|
||||||
|
PGENERIC_LIST List = ListUi->List;
|
||||||
PGENERIC_LIST_ENTRY ListEntry;
|
PGENERIC_LIST_ENTRY ListEntry;
|
||||||
PGENERIC_LIST_ENTRY OldListEntry;
|
PGENERIC_LIST_ENTRY OldListEntry;
|
||||||
BOOLEAN Flag = FALSE;
|
BOOLEAN Flag = FALSE;
|
||||||
|
|
||||||
ListEntry = GenericList->CurrentEntry;
|
ListEntry = List->CurrentEntry;
|
||||||
OldListEntry = GenericList->CurrentEntry;
|
OldListEntry = List->CurrentEntry;
|
||||||
|
|
||||||
GenericList->Redraw = FALSE;
|
ListUi->Redraw = FALSE;
|
||||||
|
|
||||||
if ((strlen(ListEntry->Text) > 0) && (tolower(ListEntry->Text[0]) == AsciiChar) &&
|
if ((strlen(ListEntry->Text) > 0) && (tolower(ListEntry->Text[0]) == AsciiChar) &&
|
||||||
(GenericList->CurrentEntry->Entry.Flink != &GenericList->ListHead))
|
(List->CurrentEntry->Entry.Flink != &List->ListHead))
|
||||||
{
|
{
|
||||||
ScrollDownGenericList(GenericList);
|
ScrollDownGenericList(ListUi);
|
||||||
ListEntry = GenericList->CurrentEntry;
|
ListEntry = List->CurrentEntry;
|
||||||
|
|
||||||
if ((strlen(ListEntry->Text) > 0) && (tolower(ListEntry->Text[0]) == AsciiChar))
|
if ((strlen(ListEntry->Text) > 0) && (tolower(ListEntry->Text[0]) == AsciiChar))
|
||||||
goto End;
|
goto End;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (GenericList->CurrentEntry->Entry.Blink != &GenericList->ListHead)
|
while (List->CurrentEntry->Entry.Blink != &List->ListHead)
|
||||||
ScrollUpGenericList(GenericList);
|
ScrollUpGenericList(ListUi);
|
||||||
|
|
||||||
ListEntry = GenericList->CurrentEntry;
|
ListEntry = List->CurrentEntry;
|
||||||
|
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
|
@ -672,34 +689,35 @@ GenericListKeyPress(
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (GenericList->CurrentEntry->Entry.Flink == &GenericList->ListHead)
|
if (List->CurrentEntry->Entry.Flink == &List->ListHead)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
ScrollDownGenericList(GenericList);
|
ScrollDownGenericList(ListUi);
|
||||||
ListEntry = GenericList->CurrentEntry;
|
ListEntry = List->CurrentEntry;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!Flag)
|
if (!Flag)
|
||||||
{
|
{
|
||||||
while (GenericList->CurrentEntry->Entry.Blink != &GenericList->ListHead)
|
while (List->CurrentEntry->Entry.Blink != &List->ListHead)
|
||||||
{
|
{
|
||||||
if (GenericList->CurrentEntry != OldListEntry)
|
if (List->CurrentEntry != OldListEntry)
|
||||||
ScrollUpGenericList(GenericList);
|
ScrollUpGenericList(ListUi);
|
||||||
else
|
else
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
End:
|
|
||||||
DrawListEntries(GenericList);
|
|
||||||
DrawScrollBarGenericList(GenericList);
|
|
||||||
|
|
||||||
GenericList->Redraw = TRUE;
|
End:
|
||||||
|
DrawListEntries(ListUi);
|
||||||
|
DrawScrollBarGenericList(ListUi);
|
||||||
|
|
||||||
|
ListUi->Redraw = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
SaveGenericListState(
|
SaveGenericListState(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
List->BackupEntry = List->CurrentEntry;
|
List->BackupEntry = List->CurrentEntry;
|
||||||
}
|
}
|
||||||
|
@ -707,15 +725,15 @@ SaveGenericListState(
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
RestoreGenericListState(
|
RestoreGenericListState(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
List->CurrentEntry = List->BackupEntry;
|
List->CurrentEntry = List->BackupEntry;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOL
|
BOOLEAN
|
||||||
GenericListHasSingleEntry(
|
GenericListHasSingleEntry(
|
||||||
PGENERIC_LIST List)
|
IN PGENERIC_LIST List)
|
||||||
{
|
{
|
||||||
if (!IsListEmpty(&List->ListHead) && List->ListHead.Flink == List->ListHead.Blink)
|
if (!IsListEmpty(&List->ListHead) && List->ListHead.Flink == List->ListHead.Blink)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
|
@ -36,93 +36,115 @@ CreateGenericList(VOID);
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
DestroyGenericList(
|
DestroyGenericList(
|
||||||
PGENERIC_LIST List,
|
IN OUT PGENERIC_LIST List,
|
||||||
BOOLEAN FreeUserData);
|
IN BOOLEAN FreeUserData);
|
||||||
|
|
||||||
BOOLEAN
|
BOOLEAN
|
||||||
AppendGenericListEntry(
|
AppendGenericListEntry(
|
||||||
PGENERIC_LIST List,
|
IN OUT PGENERIC_LIST List,
|
||||||
PCHAR Text,
|
IN PCHAR Text,
|
||||||
PVOID UserData,
|
IN PVOID UserData,
|
||||||
BOOLEAN Current);
|
IN BOOLEAN Current);
|
||||||
|
|
||||||
VOID
|
|
||||||
DrawGenericList(
|
|
||||||
PGENERIC_LIST List,
|
|
||||||
SHORT Left,
|
|
||||||
SHORT Top,
|
|
||||||
SHORT Right,
|
|
||||||
SHORT Bottom);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
ScrollDownGenericList(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
ScrollUpGenericList(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
ScrollPageDownGenericList(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
ScrollPageUpGenericList(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
ScrollToPositionGenericList(
|
|
||||||
PGENERIC_LIST List,
|
|
||||||
ULONG uIndex);
|
|
||||||
|
|
||||||
VOID
|
|
||||||
RedrawGenericList(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
SetCurrentListEntry(
|
SetCurrentListEntry(
|
||||||
PGENERIC_LIST List,
|
IN PGENERIC_LIST List,
|
||||||
PGENERIC_LIST_ENTRY Entry);
|
IN PGENERIC_LIST_ENTRY Entry);
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetCurrentListEntry(
|
GetCurrentListEntry(
|
||||||
PGENERIC_LIST List);
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetFirstListEntry(
|
GetFirstListEntry(
|
||||||
PGENERIC_LIST List);
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
PGENERIC_LIST_ENTRY
|
PGENERIC_LIST_ENTRY
|
||||||
GetNextListEntry(
|
GetNextListEntry(
|
||||||
PGENERIC_LIST_ENTRY Entry);
|
IN PGENERIC_LIST_ENTRY Entry);
|
||||||
|
|
||||||
PVOID
|
PVOID
|
||||||
GetListEntryUserData(
|
GetListEntryUserData(
|
||||||
PGENERIC_LIST_ENTRY Entry);
|
IN PGENERIC_LIST_ENTRY Entry);
|
||||||
|
|
||||||
LPCSTR
|
LPCSTR
|
||||||
GetListEntryText(
|
GetListEntryText(
|
||||||
PGENERIC_LIST_ENTRY Entry);
|
IN PGENERIC_LIST_ENTRY Entry);
|
||||||
|
|
||||||
ULONG
|
ULONG
|
||||||
GetNumberOfListEntries(
|
GetNumberOfListEntries(
|
||||||
PGENERIC_LIST List);
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
SaveGenericListState(
|
SaveGenericListState(
|
||||||
PGENERIC_LIST List);
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
RestoreGenericListState(
|
RestoreGenericListState(
|
||||||
PGENERIC_LIST List);
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
|
BOOLEAN
|
||||||
|
GenericListHasSingleEntry(
|
||||||
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct _GENERIC_LIST_UI
|
||||||
|
{
|
||||||
|
PGENERIC_LIST List;
|
||||||
|
|
||||||
|
PLIST_ENTRY FirstShown;
|
||||||
|
PLIST_ENTRY LastShown;
|
||||||
|
|
||||||
|
SHORT Left;
|
||||||
|
SHORT Top;
|
||||||
|
SHORT Right;
|
||||||
|
SHORT Bottom;
|
||||||
|
BOOL Redraw;
|
||||||
|
} GENERIC_LIST_UI, *PGENERIC_LIST_UI;
|
||||||
|
|
||||||
|
VOID
|
||||||
|
InitGenericListUi(
|
||||||
|
IN OUT PGENERIC_LIST_UI ListUi,
|
||||||
|
IN PGENERIC_LIST List);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
DrawGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
|
IN SHORT Left,
|
||||||
|
IN SHORT Top,
|
||||||
|
IN SHORT Right,
|
||||||
|
IN SHORT Bottom);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
ScrollDownGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
ScrollUpGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
ScrollPageDownGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
ScrollPageUpGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
ScrollToPositionGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
|
IN ULONG uIndex);
|
||||||
|
|
||||||
|
VOID
|
||||||
|
RedrawGenericList(
|
||||||
|
IN PGENERIC_LIST_UI ListUi);
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
GenericListKeyPress(
|
GenericListKeyPress(
|
||||||
PGENERIC_LIST GenericList,
|
IN PGENERIC_LIST_UI ListUi,
|
||||||
CHAR AsciiChar);
|
IN CHAR AsciiChar);
|
||||||
|
|
||||||
BOOL
|
|
||||||
GenericListHasSingleEntry(
|
|
||||||
PGENERIC_LIST List);
|
|
||||||
|
|
||||||
/* EOF */
|
/* EOF */
|
||||||
|
|
|
@ -640,6 +640,7 @@ UpdateKBLayout(VOID)
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
LanguagePage(PINPUT_RECORD Ir)
|
LanguagePage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
GENERIC_LIST_UI ListUi;
|
||||||
PWCHAR NewLanguageId;
|
PWCHAR NewLanguageId;
|
||||||
BOOL RefreshPage = FALSE;
|
BOOL RefreshPage = FALSE;
|
||||||
|
|
||||||
|
@ -647,7 +648,6 @@ LanguagePage(PINPUT_RECORD Ir)
|
||||||
if (LanguageList == NULL)
|
if (LanguageList == NULL)
|
||||||
{
|
{
|
||||||
LanguageList = CreateLanguageList(SetupInf, DefaultLanguage);
|
LanguageList = CreateLanguageList(SetupInf, DefaultLanguage);
|
||||||
|
|
||||||
if (LanguageList == NULL)
|
if (LanguageList == NULL)
|
||||||
{
|
{
|
||||||
PopupError("Setup failed to initialize available translations", NULL, NULL, POPUP_WAIT_NONE);
|
PopupError("Setup failed to initialize available translations", NULL, NULL, POPUP_WAIT_NONE);
|
||||||
|
@ -668,13 +668,14 @@ LanguagePage(PINPUT_RECORD Ir)
|
||||||
return INTRO_PAGE;
|
return INTRO_PAGE;
|
||||||
}
|
}
|
||||||
|
|
||||||
DrawGenericList(LanguageList,
|
InitGenericListUi(&ListUi, LanguageList);
|
||||||
|
DrawGenericList(&ListUi,
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
xScreen - 3,
|
xScreen - 3,
|
||||||
yScreen - 3);
|
yScreen - 3);
|
||||||
|
|
||||||
ScrollToPositionGenericList(LanguageList, GetDefaultLanguageIndex());
|
ScrollToPositionGenericList(&ListUi, GetDefaultLanguageIndex());
|
||||||
|
|
||||||
MUIDisplayPage(LANGUAGE_PAGE);
|
MUIDisplayPage(LANGUAGE_PAGE);
|
||||||
|
|
||||||
|
@ -685,25 +686,25 @@ LanguagePage(PINPUT_RECORD Ir)
|
||||||
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_DOWN)) /* DOWN */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_DOWN)) /* DOWN */
|
||||||
{
|
{
|
||||||
ScrollDownGenericList(LanguageList);
|
ScrollDownGenericList(&ListUi);
|
||||||
RefreshPage = TRUE;
|
RefreshPage = TRUE;
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_UP)) /* UP */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_UP)) /* UP */
|
||||||
{
|
{
|
||||||
ScrollUpGenericList(LanguageList);
|
ScrollUpGenericList(&ListUi);
|
||||||
RefreshPage = TRUE;
|
RefreshPage = TRUE;
|
||||||
}
|
}
|
||||||
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_NEXT)) /* PAGE DOWN */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_NEXT)) /* PAGE DOWN */
|
||||||
{
|
{
|
||||||
ScrollPageDownGenericList(LanguageList);
|
ScrollPageDownGenericList(&ListUi);
|
||||||
RefreshPage = TRUE;
|
RefreshPage = TRUE;
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_PRIOR)) /* PAGE UP */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_PRIOR)) /* PAGE UP */
|
||||||
{
|
{
|
||||||
ScrollPageUpGenericList(LanguageList);
|
ScrollPageUpGenericList(&ListUi);
|
||||||
RefreshPage = TRUE;
|
RefreshPage = TRUE;
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
|
@ -712,7 +713,7 @@ LanguagePage(PINPUT_RECORD Ir)
|
||||||
if (ConfirmQuit(Ir) != FALSE)
|
if (ConfirmQuit(Ir) != FALSE)
|
||||||
return QUIT_PAGE;
|
return QUIT_PAGE;
|
||||||
else
|
else
|
||||||
RedrawGenericList(LanguageList);
|
RedrawGenericList(&ListUi);
|
||||||
}
|
}
|
||||||
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
|
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
|
||||||
{
|
{
|
||||||
|
@ -733,7 +734,7 @@ LanguagePage(PINPUT_RECORD Ir)
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar > 0x60) && (Ir->Event.KeyEvent.uChar.AsciiChar < 0x7b))
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar > 0x60) && (Ir->Event.KeyEvent.uChar.AsciiChar < 0x7b))
|
||||||
{
|
{
|
||||||
/* a-z */
|
/* a-z */
|
||||||
GenericListKeyPress(LanguageList, Ir->Event.KeyEvent.uChar.AsciiChar);
|
GenericListKeyPress(&ListUi, Ir->Event.KeyEvent.uChar.AsciiChar);
|
||||||
RefreshPage = TRUE;
|
RefreshPage = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -915,12 +916,11 @@ SetupStartPage(PINPUT_RECORD Ir)
|
||||||
LanguageList = CreateLanguageList(SetupInf, DefaultLanguage);
|
LanguageList = CreateLanguageList(SetupInf, DefaultLanguage);
|
||||||
|
|
||||||
/* new part */
|
/* new part */
|
||||||
wcscpy(SelectedLanguageId,LocaleID);
|
wcscpy(SelectedLanguageId, LocaleID);
|
||||||
LanguageId = (LANGID)(wcstol(SelectedLanguageId, NULL, 16) & 0xFFFF);
|
LanguageId = (LANGID)(wcstol(SelectedLanguageId, NULL, 16) & 0xFFFF);
|
||||||
|
|
||||||
/* first we hack LanguageList */
|
/* first we hack LanguageList */
|
||||||
ListEntry = GetFirstListEntry(LanguageList);
|
ListEntry = GetFirstListEntry(LanguageList);
|
||||||
|
|
||||||
while (ListEntry != NULL)
|
while (ListEntry != NULL)
|
||||||
{
|
{
|
||||||
if (!wcsicmp(LocaleID, GetListEntryUserData(ListEntry)))
|
if (!wcsicmp(LocaleID, GetListEntryUserData(ListEntry)))
|
||||||
|
@ -935,7 +935,6 @@ SetupStartPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
/* now LayoutList */
|
/* now LayoutList */
|
||||||
ListEntry = GetFirstListEntry(LayoutList);
|
ListEntry = GetFirstListEntry(LayoutList);
|
||||||
|
|
||||||
while (ListEntry != NULL)
|
while (ListEntry != NULL)
|
||||||
{
|
{
|
||||||
if (!wcsicmp(LocaleID, GetListEntryUserData(ListEntry)))
|
if (!wcsicmp(LocaleID, GetListEntryUserData(ListEntry)))
|
||||||
|
@ -1319,7 +1318,7 @@ DeviceSettingsPage(PINPUT_RECORD Ir)
|
||||||
* Ir: The PINPUT_RECORD
|
* Ir: The PINPUT_RECORD
|
||||||
*/
|
*/
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
HandleGenericList(PGENERIC_LIST GenericList,
|
HandleGenericList(PGENERIC_LIST_UI ListUi,
|
||||||
PAGE_NUMBER nextPage,
|
PAGE_NUMBER nextPage,
|
||||||
PINPUT_RECORD Ir)
|
PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
@ -1330,36 +1329,36 @@ HandleGenericList(PGENERIC_LIST GenericList,
|
||||||
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_DOWN)) /* DOWN */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_DOWN)) /* DOWN */
|
||||||
{
|
{
|
||||||
ScrollDownGenericList(GenericList);
|
ScrollDownGenericList(ListUi);
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_UP)) /* UP */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_UP)) /* UP */
|
||||||
{
|
{
|
||||||
ScrollUpGenericList(GenericList);
|
ScrollUpGenericList(ListUi);
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_NEXT)) /* PAGE DOWN */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_NEXT)) /* PAGE DOWN */
|
||||||
{
|
{
|
||||||
ScrollPageDownGenericList(GenericList);
|
ScrollPageDownGenericList(ListUi);
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_PRIOR)) /* PAGE UP */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_PRIOR)) /* PAGE UP */
|
||||||
{
|
{
|
||||||
ScrollPageUpGenericList(GenericList);
|
ScrollPageUpGenericList(ListUi);
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_F3)) /* F3 */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_F3)) /* F3 */
|
||||||
{
|
{
|
||||||
if (ConfirmQuit(Ir) != FALSE)
|
if (ConfirmQuit(Ir) != FALSE)
|
||||||
return QUIT_PAGE;
|
return QUIT_PAGE;
|
||||||
|
else
|
||||||
continue;
|
RedrawGenericList(ListUi);
|
||||||
}
|
}
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
|
||||||
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE)) /* ESC */
|
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE)) /* ESC */
|
||||||
{
|
{
|
||||||
RestoreGenericListState(GenericList);
|
RestoreGenericListState(ListUi->List);
|
||||||
return nextPage;
|
return nextPage; // Use some "prevPage;" instead?
|
||||||
}
|
}
|
||||||
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
|
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
|
||||||
{
|
{
|
||||||
|
@ -1368,7 +1367,7 @@ HandleGenericList(PGENERIC_LIST GenericList,
|
||||||
else if ((Ir->Event.KeyEvent.uChar.AsciiChar > 0x60) && (Ir->Event.KeyEvent.uChar.AsciiChar < 0x7b))
|
else if ((Ir->Event.KeyEvent.uChar.AsciiChar > 0x60) && (Ir->Event.KeyEvent.uChar.AsciiChar < 0x7b))
|
||||||
{
|
{
|
||||||
/* a-z */
|
/* a-z */
|
||||||
GenericListKeyPress(GenericList, Ir->Event.KeyEvent.uChar.AsciiChar);
|
GenericListKeyPress(ListUi, Ir->Event.KeyEvent.uChar.AsciiChar);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1387,9 +1386,11 @@ HandleGenericList(PGENERIC_LIST GenericList,
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
ComputerSettingsPage(PINPUT_RECORD Ir)
|
ComputerSettingsPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
GENERIC_LIST_UI ListUi;
|
||||||
MUIDisplayPage(COMPUTER_SETTINGS_PAGE);
|
MUIDisplayPage(COMPUTER_SETTINGS_PAGE);
|
||||||
|
|
||||||
DrawGenericList(ComputerList,
|
InitGenericListUi(&ListUi, ComputerList);
|
||||||
|
DrawGenericList(&ListUi,
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
xScreen - 3,
|
xScreen - 3,
|
||||||
|
@ -1397,7 +1398,7 @@ ComputerSettingsPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
SaveGenericListState(ComputerList);
|
SaveGenericListState(ComputerList);
|
||||||
|
|
||||||
return HandleGenericList(ComputerList, DEVICE_SETTINGS_PAGE, Ir);
|
return HandleGenericList(&ListUi, DEVICE_SETTINGS_PAGE, Ir);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1414,9 +1415,11 @@ ComputerSettingsPage(PINPUT_RECORD Ir)
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
DisplaySettingsPage(PINPUT_RECORD Ir)
|
DisplaySettingsPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
GENERIC_LIST_UI ListUi;
|
||||||
MUIDisplayPage(DISPLAY_SETTINGS_PAGE);
|
MUIDisplayPage(DISPLAY_SETTINGS_PAGE);
|
||||||
|
|
||||||
DrawGenericList(DisplayList,
|
InitGenericListUi(&ListUi, DisplayList);
|
||||||
|
DrawGenericList(&ListUi,
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
xScreen - 3,
|
xScreen - 3,
|
||||||
|
@ -1424,7 +1427,7 @@ DisplaySettingsPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
SaveGenericListState(DisplayList);
|
SaveGenericListState(DisplayList);
|
||||||
|
|
||||||
return HandleGenericList(DisplayList, DEVICE_SETTINGS_PAGE, Ir);
|
return HandleGenericList(&ListUi, DEVICE_SETTINGS_PAGE, Ir);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1441,9 +1444,11 @@ DisplaySettingsPage(PINPUT_RECORD Ir)
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
KeyboardSettingsPage(PINPUT_RECORD Ir)
|
KeyboardSettingsPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
GENERIC_LIST_UI ListUi;
|
||||||
MUIDisplayPage(KEYBOARD_SETTINGS_PAGE);
|
MUIDisplayPage(KEYBOARD_SETTINGS_PAGE);
|
||||||
|
|
||||||
DrawGenericList(KeyboardList,
|
InitGenericListUi(&ListUi, KeyboardList);
|
||||||
|
DrawGenericList(&ListUi,
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
xScreen - 3,
|
xScreen - 3,
|
||||||
|
@ -1451,7 +1456,7 @@ KeyboardSettingsPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
SaveGenericListState(KeyboardList);
|
SaveGenericListState(KeyboardList);
|
||||||
|
|
||||||
return HandleGenericList(KeyboardList, DEVICE_SETTINGS_PAGE, Ir);
|
return HandleGenericList(&ListUi, DEVICE_SETTINGS_PAGE, Ir);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1468,9 +1473,11 @@ KeyboardSettingsPage(PINPUT_RECORD Ir)
|
||||||
static PAGE_NUMBER
|
static PAGE_NUMBER
|
||||||
LayoutSettingsPage(PINPUT_RECORD Ir)
|
LayoutSettingsPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
|
GENERIC_LIST_UI ListUi;
|
||||||
MUIDisplayPage(LAYOUT_SETTINGS_PAGE);
|
MUIDisplayPage(LAYOUT_SETTINGS_PAGE);
|
||||||
|
|
||||||
DrawGenericList(LayoutList,
|
InitGenericListUi(&ListUi, LayoutList);
|
||||||
|
DrawGenericList(&ListUi,
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
xScreen - 3,
|
xScreen - 3,
|
||||||
|
@ -1478,7 +1485,7 @@ LayoutSettingsPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
SaveGenericListState(LayoutList);
|
SaveGenericListState(LayoutList);
|
||||||
|
|
||||||
return HandleGenericList(LayoutList, DEVICE_SETTINGS_PAGE, Ir);
|
return HandleGenericList(&ListUi, DEVICE_SETTINGS_PAGE, Ir);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -2945,7 +2952,7 @@ SelectFileSystemPage(PINPUT_RECORD Ir)
|
||||||
* RETURNS
|
* RETURNS
|
||||||
* Number of the next page.
|
* Number of the next page.
|
||||||
*/
|
*/
|
||||||
static ULONG
|
static PAGE_NUMBER
|
||||||
FormatPartitionPage(PINPUT_RECORD Ir)
|
FormatPartitionPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
UNICODE_STRING PartitionRootPath;
|
UNICODE_STRING PartitionRootPath;
|
||||||
|
@ -3135,7 +3142,7 @@ FormatPartitionPage(PINPUT_RECORD Ir)
|
||||||
* RETURNS
|
* RETURNS
|
||||||
* Number of the next page.
|
* Number of the next page.
|
||||||
*/
|
*/
|
||||||
static ULONG
|
static PAGE_NUMBER
|
||||||
CheckFileSystemPage(PINPUT_RECORD Ir)
|
CheckFileSystemPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
PFILE_SYSTEM_ITEM CurrentFileSystem;
|
PFILE_SYSTEM_ITEM CurrentFileSystem;
|
||||||
|
@ -3996,8 +4003,7 @@ FileCopyCallback(PVOID Context,
|
||||||
* RETURNS
|
* RETURNS
|
||||||
* Number of the next page.
|
* Number of the next page.
|
||||||
*/
|
*/
|
||||||
static
|
static PAGE_NUMBER
|
||||||
PAGE_NUMBER
|
|
||||||
FileCopyPage(PINPUT_RECORD Ir)
|
FileCopyPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
COPYCONTEXT CopyContext;
|
COPYCONTEXT CopyContext;
|
||||||
|
@ -4194,7 +4200,6 @@ RegistryPage(PINPUT_RECORD Ir)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Set GeoID */
|
/* Set GeoID */
|
||||||
|
|
||||||
if (!SetGeoID(MUIGetGeoID()))
|
if (!SetGeoID(MUIGetGeoID()))
|
||||||
{
|
{
|
||||||
MUIDisplayError(ERROR_UPDATE_GEOID, Ir, POPUP_WAIT_ENTER);
|
MUIDisplayError(ERROR_UPDATE_GEOID, Ir, POPUP_WAIT_ENTER);
|
||||||
|
@ -4428,7 +4433,7 @@ BootLoaderFloppyPage(PINPUT_RECORD Ir)
|
||||||
|
|
||||||
MUIDisplayPage(BOOT_LOADER_FLOPPY_PAGE);
|
MUIDisplayPage(BOOT_LOADER_FLOPPY_PAGE);
|
||||||
|
|
||||||
// SetStatusText(" Please wait...");
|
// CONSOLE_SetStatusText(MUIGetString(STRING_PLEASEWAIT));
|
||||||
|
|
||||||
while (TRUE)
|
while (TRUE)
|
||||||
{
|
{
|
||||||
|
@ -4592,48 +4597,49 @@ QuitPage(PINPUT_RECORD Ir)
|
||||||
{
|
{
|
||||||
MUIDisplayPage(QUIT_PAGE);
|
MUIDisplayPage(QUIT_PAGE);
|
||||||
|
|
||||||
/* Destroy partition list */
|
/* Destroy the partition list */
|
||||||
if (PartitionList != NULL)
|
if (PartitionList != NULL)
|
||||||
{
|
{
|
||||||
DestroyPartitionList(PartitionList);
|
DestroyPartitionList(PartitionList);
|
||||||
PartitionList = NULL;
|
PartitionList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Destroy filesystem list */
|
/* Destroy the filesystem list */
|
||||||
if (FileSystemList != NULL)
|
if (FileSystemList != NULL)
|
||||||
{
|
{
|
||||||
DestroyFileSystemList(FileSystemList);
|
DestroyFileSystemList(FileSystemList);
|
||||||
FileSystemList = NULL;
|
FileSystemList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Destroy computer settings list */
|
/* Destroy the computer settings list */
|
||||||
if (ComputerList != NULL)
|
if (ComputerList != NULL)
|
||||||
{
|
{
|
||||||
DestroyGenericList(ComputerList, TRUE);
|
DestroyGenericList(ComputerList, TRUE);
|
||||||
ComputerList = NULL;
|
ComputerList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Destroy display settings list */
|
/* Destroy the display settings list */
|
||||||
if (DisplayList != NULL)
|
if (DisplayList != NULL)
|
||||||
{
|
{
|
||||||
DestroyGenericList(DisplayList, TRUE);
|
DestroyGenericList(DisplayList, TRUE);
|
||||||
DisplayList = NULL;
|
DisplayList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Destroy keyboard settings list */
|
/* Destroy the keyboard settings list */
|
||||||
if (KeyboardList != NULL)
|
if (KeyboardList != NULL)
|
||||||
{
|
{
|
||||||
DestroyGenericList(KeyboardList, TRUE);
|
DestroyGenericList(KeyboardList, TRUE);
|
||||||
KeyboardList = NULL;
|
KeyboardList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Destroy keyboard layout list */
|
/* Destroy the keyboard layout list */
|
||||||
if (LayoutList != NULL)
|
if (LayoutList != NULL)
|
||||||
{
|
{
|
||||||
DestroyGenericList(LayoutList, TRUE);
|
DestroyGenericList(LayoutList, TRUE);
|
||||||
LayoutList = NULL;
|
LayoutList = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Destroy the languages list */
|
||||||
if (LanguageList != NULL)
|
if (LanguageList != NULL)
|
||||||
{
|
{
|
||||||
DestroyGenericList(LanguageList, FALSE);
|
DestroyGenericList(LanguageList, FALSE);
|
||||||
|
@ -4723,6 +4729,7 @@ RunUSetup(VOID)
|
||||||
|
|
||||||
NtQuerySystemTime(&Time);
|
NtQuerySystemTime(&Time);
|
||||||
|
|
||||||
|
/* Create the PnP thread in suspended state */
|
||||||
Status = RtlCreateUserThread(NtCurrentProcess(),
|
Status = RtlCreateUserThread(NtCurrentProcess(),
|
||||||
NULL,
|
NULL,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
@ -4800,9 +4807,7 @@ RunUSetup(VOID)
|
||||||
case SCSI_CONTROLLER_PAGE:
|
case SCSI_CONTROLLER_PAGE:
|
||||||
Page = ScsiControllerPage(&Ir);
|
Page = ScsiControllerPage(&Ir);
|
||||||
break;
|
break;
|
||||||
#endif
|
|
||||||
|
|
||||||
#if 0
|
|
||||||
case OEM_DRIVER_PAGE:
|
case OEM_DRIVER_PAGE:
|
||||||
Page = OemDriverPage(&Ir);
|
Page = OemDriverPage(&Ir);
|
||||||
break;
|
break;
|
||||||
|
@ -4857,11 +4862,11 @@ RunUSetup(VOID)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case FORMAT_PARTITION_PAGE:
|
case FORMAT_PARTITION_PAGE:
|
||||||
Page = (PAGE_NUMBER) FormatPartitionPage(&Ir);
|
Page = FormatPartitionPage(&Ir);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CHECK_FILE_SYSTEM_PAGE:
|
case CHECK_FILE_SYSTEM_PAGE:
|
||||||
Page = (PAGE_NUMBER) CheckFileSystemPage(&Ir);
|
Page = CheckFileSystemPage(&Ir);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case INSTALL_DIRECTORY_PAGE:
|
case INSTALL_DIRECTORY_PAGE:
|
||||||
|
|
Loading…
Reference in a new issue