Author: mpiulachs
Date: Tue Dec 25 23:24:19 2007
New Revision: 31437
URL:
http://svn.reactos.org/svn/reactos?rev=31437&view=rev
Log:
- Allow LANGUAGE_PAGE localization
- Use DefaultLanguage setting to set the user interface language even for the language
selection itself
- Add missing language page entries to current localizations, translators get to work!
Modified:
trunk/reactos/base/setup/usetup/interface/usetup.c
trunk/reactos/base/setup/usetup/lang/de-DE.h
trunk/reactos/base/setup/usetup/lang/el-GR.h
trunk/reactos/base/setup/usetup/lang/en-US.h
trunk/reactos/base/setup/usetup/lang/es-ES.h
trunk/reactos/base/setup/usetup/lang/fr-FR.h
trunk/reactos/base/setup/usetup/lang/it-IT.h
trunk/reactos/base/setup/usetup/lang/ru-RU.h
trunk/reactos/base/setup/usetup/lang/sv-SE.h
trunk/reactos/base/setup/usetup/lang/uk-UA.h
trunk/reactos/base/setup/usetup/mui.c
trunk/reactos/base/setup/usetup/mui.h
trunk/reactos/base/setup/usetup/settings.c
trunk/reactos/base/setup/usetup/usetup.h
Modified: trunk/reactos/base/setup/usetup/interface/usetup.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/interfac…
==============================================================================
--- trunk/reactos/base/setup/usetup/interface/usetup.c (original)
+++ trunk/reactos/base/setup/usetup/interface/usetup.c Tue Dec 25 23:24:19 2007
@@ -44,6 +44,7 @@
LONG UnattendFormatPartition = 0;
LONG AutoPartition = 0;
WCHAR UnattendInstallationDirectory[MAX_PATH];
+PWCHAR SelectedLanguageId;
BOOLEAN RepairUpdateFlag = FALSE;
HANDLE hPnpThread = INVALID_HANDLE_VALUE;
@@ -571,11 +572,19 @@
if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_DOWN)) /* DOWN */
{
+#if 0 //Dinamically update user interface
+ SelectedLanguageId = (PWCHAR)LanguageList->CurrentEntry->UserData;
+ MUIDisplayPage(LANGUAGE_PAGE);
+#endif
ScrollDownGenericList (LanguageList);
}
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
(Ir->Event.KeyEvent.wVirtualKeyCode == VK_UP)) /* UP */
{
+#if 0
+ SelectedLanguageId = (PWCHAR)LanguageList->CurrentEntry->UserData;
+ MUIDisplayPage(LANGUAGE_PAGE);
+#endif
ScrollUpGenericList (LanguageList);
}
else if ((Ir->Event.KeyEvent.uChar.AsciiChar == 0x00) &&
@@ -586,7 +595,7 @@
}
else if (Ir->Event.KeyEvent.uChar.AsciiChar == 0x0D) /* ENTER */
{
- MUISelectLanguage((PWCHAR)LanguageList->CurrentEntry->UserData);
+ SelectedLanguageId = (PWCHAR)LanguageList->CurrentEntry->UserData;
return INTRO_PAGE;
}
}
Modified: trunk/reactos/base/setup/usetup/lang/de-DE.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/de-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/de-DE.h (original)
+++ trunk/reactos/base/setup/usetup/lang/de-DE.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_DE_DE_H__
#define LANG_DE_DE_H__
+
+static MUI_ENTRY deDELanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY deDEWelcomePageEntries[] =
{
@@ -1267,6 +1307,10 @@
MUI_PAGE deDEPages[] =
{
{
+ LANGUAGE_PAGE,
+ deDELanguagePageEntries
+ },
+ {
START_PAGE,
deDEWelcomePageEntries
},
Modified: trunk/reactos/base/setup/usetup/lang/el-GR.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/el-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/el-GR.h (original)
+++ trunk/reactos/base/setup/usetup/lang/el-GR.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_EL_GR_H__
#define LANG_EL_GR_H__
+
+static MUI_ENTRY elGRLanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY elGRWelcomePageEntries[] =
{
@@ -1268,7 +1308,7 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
+ elGRLanguagePageEntries
},
{
START_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/en-US.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/en-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/en-US.h (original)
+++ trunk/reactos/base/setup/usetup/lang/en-US.h Tue Dec 25 23:24:19 2007
@@ -1,13 +1,12 @@
#ifndef LANG_EN_US_H__
#define LANG_EN_US_H__
-// do not translate these
-static MUI_ENTRY LanguagePageEntries[] =
-{
- {
- 6,
- 8,
- "Language Selection.",
+static MUI_ENTRY enUSLanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection",
TEXT_NORMAL
},
{
@@ -1308,7 +1307,7 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
+ enUSLanguagePageEntries
},
{
START_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/es-ES.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/es-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/es-ES.h (original)
+++ trunk/reactos/base/setup/usetup/lang/es-ES.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_ES_ES_H__
#define LANG_ES_ES_H__
+
+static MUI_ENTRY esESLanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Selección de idioma",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY esESWelcomePageEntries[] =
{
@@ -1074,11 +1114,11 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
- },
- {
- START_PAGE,
- esESWelcomePageEntries
+ esESLanguagePageEntries
+ },
+ {
+ START_PAGE,
+ esESWelcomePageEntries
},
{
INSTALL_INTRO_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/fr-FR.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/fr-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/fr-FR.h (original)
+++ trunk/reactos/base/setup/usetup/lang/fr-FR.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_FR_FR_H__
#define LANG_FR_FR_H__
+
+static MUI_ENTRY frFRLanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY frFRWelcomePageEntries[] =
{
@@ -1280,7 +1320,7 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
+ frFRLanguagePageEntries
},
{
START_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/it-IT.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/it-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/it-IT.h (original)
+++ trunk/reactos/base/setup/usetup/lang/it-IT.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_IT_IT_H__
#define LANG_IT_IT_H__
+
+static MUI_ENTRY itITLanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY itITWelcomePageEntries[] =
{
@@ -1267,7 +1307,7 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
+ itITLanguagePageEntries
},
{
START_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/ru-RU.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/ru-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/ru-RU.h (original)
+++ trunk/reactos/base/setup/usetup/lang/ru-RU.h Tue Dec 25 23:24:19 2007
@@ -6,7 +6,25 @@
{
6,
8,
- "Select your language:",
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
TEXT_NORMAL
},
{
Modified: trunk/reactos/base/setup/usetup/lang/sv-SE.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/sv-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/sv-SE.h (original)
+++ trunk/reactos/base/setup/usetup/lang/sv-SE.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_SV_SE_H__
#define LANG_SV_SE_H__
+
+static MUI_ENTRY svSELanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY svSEWelcomePageEntries[] =
{
@@ -1075,7 +1115,7 @@
{
{
LANGUAGE_PAGE,
- LanguagePageEntries
+ svSELanguagePageEntries
},
{
START_PAGE,
Modified: trunk/reactos/base/setup/usetup/lang/uk-UA.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/lang/uk-…
==============================================================================
--- trunk/reactos/base/setup/usetup/lang/uk-UA.h (original)
+++ trunk/reactos/base/setup/usetup/lang/uk-UA.h Tue Dec 25 23:24:19 2007
@@ -1,5 +1,45 @@
#ifndef LANG_UK_UA_H__
#define LANG_UK_UA_H__
+
+static MUI_ENTRY ukUALanguagePageEntries[] =
+{
+ {
+ 6,
+ 8,
+ "Language Selection.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 10,
+ "\x07 Please choose the language used for the installation process.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 11,
+ " Then press ENTER.",
+ TEXT_NORMAL
+ },
+ {
+ 8,
+ 13,
+ "\x07 This Language will be the default language for the final
system.",
+ TEXT_NORMAL
+ },
+ {
+ 0,
+ 0,
+ " ENTER = Continue F3 = Quit",
+ TEXT_STATUS
+ },
+ {
+ 0,
+ 0,
+ NULL,
+ 0
+ }
+};
static MUI_ENTRY ukUAWelcomePageEntries[] =
{
@@ -1074,6 +1114,10 @@
MUI_PAGE ukUAPages[] =
{
{
+ LANGUAGE_PAGE,
+ ukUALanguagePageEntries
+ },
+ {
START_PAGE,
ukUAWelcomePageEntries
},
Modified: trunk/reactos/base/setup/usetup/mui.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/mui.c?re…
==============================================================================
--- trunk/reactos/base/setup/usetup/mui.c (original)
+++ trunk/reactos/base/setup/usetup/mui.c Tue Dec 25 23:24:19 2007
@@ -38,9 +38,6 @@
#include "lang/sv-SE.h"
#include "lang/uk-UA.h"
-/* The current selected language , by default en-us for now */
-static PWCHAR SelectedLanguageId = L"00000409";
-
static MUI_LANGUAGE LanguageList[] =
{
{
@@ -111,16 +108,6 @@
PINPUT_RECORD Ir,
ULONG WaitEvent);
-BOOLEAN
-MUISelectLanguage(PWCHAR LanguageID)
-{
- if (LanguageID == NULL)
- return FALSE;
-
- SelectedLanguageId = LanguageID;
- return TRUE;
-}
-
static
MUI_ENTRY *
FindMUIEntriesOfPage (ULONG PageNumber)
@@ -188,8 +175,8 @@
CONSOLE_SetUnderlinedTextXY(entry[index].X, entry[index].Y,
entry[index].Buffer);
break;
case TEXT_STATUS:
- CONSOLE_SetStatusText(entry[index].Buffer);
- break;
+ CONSOLE_SetStatusText(entry[index].Buffer);
+ break;
default:
break;
}
Modified: trunk/reactos/base/setup/usetup/mui.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/mui.h?re…
==============================================================================
--- trunk/reactos/base/setup/usetup/mui.h (original)
+++ trunk/reactos/base/setup/usetup/mui.h Tue Dec 25 23:24:19 2007
@@ -34,11 +34,6 @@
#define TEXT_ALIGN_CENTER 8
VOID
-MUIDisplayPage(ULONG PageNumber);
-
-BOOLEAN
-//MUISelectLanguage(ULONG LanguageIndex);
-MUISelectLanguage(PWCHAR LanguageID);
-
+MUIDisplayPage (ULONG PageNumber);
#endif
Modified: trunk/reactos/base/setup/usetup/settings.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/settings…
==============================================================================
--- trunk/reactos/base/setup/usetup/settings.c (original)
+++ trunk/reactos/base/setup/usetup/settings.c Tue Dec 25 23:24:19 2007
@@ -674,6 +674,8 @@
return NULL;
wcscpy(DefaultLanguage, KeyValue);
+
+ SelectedLanguageId = KeyValue;
List = CreateGenericList();
if (List == NULL)
Modified: trunk/reactos/base/setup/usetup/usetup.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/usetup.h…
==============================================================================
--- trunk/reactos/base/setup/usetup/usetup.h (original)
+++ trunk/reactos/base/setup/usetup/usetup.h Tue Dec 25 23:24:19 2007
@@ -79,6 +79,7 @@
extern UNICODE_STRING SourceRootDir;
extern UNICODE_STRING SourcePath;
extern BOOLEAN IsUnattendedSetup;
+extern PWCHAR SelectedLanguageId;
typedef enum _PAGE_NUMBER
{