src/tron/gLanguageMenu.cpp File Reference

#include "gLanguageMenu.h"
#include "uMenu.h"
#include "tLocale.h"
#include "tConfiguration.h"

Include dependency graph for gLanguageMenu.cpp:

Go to the source code of this file.

Functions

static void sg_UpdateLanguage (tString &language)
void sg_LanguageInit ()
void sg_LanguageMenu ()

Variables

static tString sg_FirstLanguage ("American English")
static tString sg_SecondLanguage ("American English")
static tConfItemLine sg_fl ("LANGUAGE_FIRST", sg_FirstLanguage)
static tConfItemLine sg_sl ("LANGUAGE_SECOND", sg_SecondLanguage)


Function Documentation

void sg_LanguageInit (  ) 

Definition at line 48 of file gLanguageMenu.cpp.

References tLanguage::Find(), tLanguage::SetFirstLanguage(), tLanguage::SetSecondLanguage(), sg_FirstLanguage, sg_SecondLanguage, and sg_UpdateLanguage().

Referenced by main(), and sg_LanguageMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

void sg_LanguageMenu (  ) 

Definition at line 57 of file gLanguageMenu.cpp.

References uMenu::Enter(), tLanguage::FirstLanguage(), tLanguage::Name(), uMenuItemSelection< T >::NewChoice(), tListItem< T >::Next(), sg_FirstLanguage, sg_LanguageInit(), and sg_SecondLanguage.

Referenced by MainMenu(), and welcome().

00058 {
00059     if (!tLanguage::FirstLanguage())
00060         return;
00061 
00062     uMenu menu("$language_menu_title", false);
00063     //  uMenu menu("Sprach Menu", false);
00064 
00065     uMenuItemExit exit(&menu, "$menuitem_accept", "$menuitem_accept_help");
00066 
00067     uMenuItemSelection<tString> second(&menu,
00068                                        "$language_menu_item_second",
00069                                        "$language_menu_item_second_help",
00070                                        sg_SecondLanguage);
00071 
00072     uMenuItemSelection<tString> first(&menu,
00073                                       "$language_menu_item_fist",
00074                                       "$language_menu_item_first_help",
00075                                       sg_FirstLanguage);
00076 
00077     tLanguage* run = tLanguage::FirstLanguage();
00078 
00079 
00080     while (run)
00081     {
00082         first.NewChoice(run->Name(),"", run->Name());
00083         second.NewChoice(run->Name(),"", run->Name());
00084         run = run->Next();
00085     }
00086 
00087     menu.Enter();
00088 
00089     sg_LanguageInit();
00090 }

Here is the call graph for this function:

Here is the caller graph for this function:

static void sg_UpdateLanguage ( tString language  )  [static]

Definition at line 38 of file gLanguageMenu.cpp.

Referenced by sg_LanguageInit().

00039 {
00040     // update outdated language choices
00041     if ( language == "English" )
00042         language = "British English";
00043 
00044     if ( language == "American" )
00045         language = "American English";
00046 }

Here is the caller graph for this function:


Variable Documentation

tString sg_FirstLanguage("American English") [static]

Referenced by sg_LanguageInit(), and sg_LanguageMenu().

tConfItemLine sg_fl("LANGUAGE_FIRST", sg_FirstLanguage) [static]

tString sg_SecondLanguage("American English")

Referenced by sg_LanguageInit(), and sg_LanguageMenu().

tConfItemLine sg_sl("LANGUAGE_SECOND", sg_SecondLanguage) [static]


Generated on Sat Mar 15 23:17:12 2008 for Armagetron Advanced by  doxygen 1.5.4