-rw-r--r-- | library/config.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/library/config.cpp b/library/config.cpp index 9634571..e07eecb 100644 --- a/library/config.cpp +++ b/library/config.cpp @@ -32,9 +32,11 @@ #include <fcntl.h> #include <stdlib.h> #include <unistd.h> +#define QTOPIA_INTERNAL_LANGLIST #include "config.h" +#include "global.h" /*! \internal @@ -94,16 +96,11 @@ Config::Config( const QString &name, Domain domain ) : filename( configFilename(name,domain) ) { git = groups.end(); read(); - - lang = getenv("LANG"); - int i = lang.find("."); - if ( i > 0 ) - lang = lang.left( i ); - i = lang.find( "_" ); - if ( i > 0 ) - glang = lang.left(i); + QStringList l = Global::languageList(); + lang = l[0]; + glang = l[1]; } /*! Writes any changes to disk and destroys the in-memory object. |