MythTV  0.26-pre
Public Member Functions | Private Types | Private Member Functions | Private Attributes
MythLocale Class Reference

#include <mythlocale.h>

List of all members.

Public Member Functions

 MythLocale (QString localeName=QString())
 ~MythLocale ()
void ReInit ()
QString GetCountryCode () const
QString GetCountry () const
 ISO3166 2-letter.
QString GetNativeCountry () const
 Name of country in English.
QString GetLanguageCode () const
 Name of country in the native language.
QString GetLanguage () const
 ISO639 2-letter.
QString GetNativeLanguage () const
 Name of language in English.
QString GetLocaleCode () const
 Name of language in that language.
const QLocale ToQLocale () const
bool LoadDefaultsFromXML (void)
void SaveLocaleDefaults (bool overwrite=false)
void ResetToLocaleDefaults (void)
void ResetToStandardDefaults (void)
QString GetLocaleSetting (const QString &key)

Private Types

typedef QMap< QString, QString > SettingsMap

Private Member Functions

void Init (const QString &localeName=QString())

Private Attributes

QString m_localeCode
bool m_defaultsLoaded
QLocale m_qtLocale
SettingsMap m_globalSettings
SettingsMap m_hostSettings

Detailed Description

Definition at line 14 of file mythlocale.h.


Member Typedef Documentation

typedef QMap<QString, QString> MythLocale::SettingsMap [private]

Definition at line 48 of file mythlocale.h.


Constructor & Destructor Documentation

MythLocale::MythLocale ( QString  localeName = QString())

Definition at line 14 of file mythlocale.cpp.

Definition at line 18 of file mythlocale.h.


Member Function Documentation

Definition at line 52 of file mythlocale.cpp.

Referenced by MythCoreContext::ReInitLocale().

QString MythLocale::GetCountryCode ( void  ) const
QString MythLocale::GetCountry ( ) const

ISO3166 2-letter.

Definition at line 64 of file mythlocale.cpp.

Referenced by MythTranslation::getLanguages().

QString MythLocale::GetNativeCountry ( void  ) const

Name of country in English.

Definition at line 69 of file mythlocale.cpp.

Referenced by MythTranslation::getLanguages().

QString MythLocale::GetLanguageCode ( void  ) const

Name of country in the native language.

Definition at line 74 of file mythlocale.cpp.

Referenced by GetLanguage(), GetNativeLanguage(), and LanguageSelection::Load().

QString MythLocale::GetLanguage ( void  ) const

ISO639 2-letter.

Definition at line 81 of file mythlocale.cpp.

Referenced by MythTranslation::getLanguages().

QString MythLocale::GetNativeLanguage ( void  ) const

Name of language in English.

Definition at line 86 of file mythlocale.cpp.

Referenced by MythTranslation::getLanguages().

QString MythLocale::GetLocaleCode ( ) const [inline]
const QLocale MythLocale::ToQLocale ( ) const [inline]

Definition at line 91 of file mythlocale.cpp.

Referenced by GetLocaleSetting(), and SaveLocaleDefaults().

Definition at line 171 of file mythlocale.cpp.

Referenced by ResetToLocaleDefaults(), and MythCoreContext::SaveLocaleDefaults().

Definition at line 193 of file mythlocale.cpp.

Definition at line 198 of file mythlocale.cpp.

QString MythLocale::GetLocaleSetting ( const QString &  key)

Definition at line 206 of file mythlocale.cpp.

Referenced by LanguageSelection::Load().

void MythLocale::Init ( const QString &  localeName = QString()) [private]

Definition at line 20 of file mythlocale.cpp.

Referenced by MythLocale(), and ReInit().


Member Data Documentation

QString MythLocale::m_localeCode [private]

Definition at line 44 of file mythlocale.h.

Referenced by GetCountryCode(), GetLanguageCode(), Init(), and LoadDefaultsFromXML().

Definition at line 45 of file mythlocale.h.

Referenced by GetLocaleSetting(), LoadDefaultsFromXML(), and SaveLocaleDefaults().

QLocale MythLocale::m_qtLocale [private]

Definition at line 46 of file mythlocale.h.

Referenced by Init().

Definition at line 49 of file mythlocale.h.

Referenced by GetLocaleSetting(), LoadDefaultsFromXML(), and SaveLocaleDefaults().

Definition at line 50 of file mythlocale.h.

Referenced by GetLocaleSetting(), LoadDefaultsFromXML(), and SaveLocaleDefaults().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends