X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ea14492351395f1dcea060e8db0860f865b92658..66c2bf7b1d9326fb650acfaae22ec50528cfbf7c:/include/wx/intl.h?ds=sidebyside diff --git a/include/wx/intl.h b/include/wx/intl.h index 3f60fb6335..f3e862ff43 100644 --- a/include/wx/intl.h +++ b/include/wx/intl.h @@ -5,7 +5,6 @@ // Modified by: Michael N. Filippov // (2003/09/30 - plural forms support) // Created: 29/01/98 -// RCS-ID: $Id$ // Copyright: (c) 1998 Vadim Zeitlin // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// @@ -60,17 +59,17 @@ struct WXDLLIMPEXP_BASE wxLanguageInfo { int Language; // wxLanguage id wxString CanonicalName; // Canonical name, e.g. fr_FR -#ifdef __WXMSW__ +#ifdef __WINDOWS__ wxUint32 WinLang, // Win32 language identifiers WinSublang; -#endif // __WXMSW__ +#endif // __WINDOWS__ wxString Description; // human-readable name of the language wxLayoutDirection LayoutDirection; -#ifdef __WXMSW__ +#ifdef __WINDOWS__ // return the LCID corresponding to this language wxUint32 GetLCID() const; -#endif // __WXMSW__ +#endif // __WINDOWS__ // return the locale name corresponding to this language usable with // setlocale() on the current system @@ -79,9 +78,9 @@ struct WXDLLIMPEXP_BASE wxLanguageInfo // for Unix systems GetLocaleName() is trivial so implement it inline here, for // MSW it's implemented in intl.cpp -#ifndef __WXMSW__ +#ifndef __WINDOWS__ inline wxString wxLanguageInfo::GetLocaleName() const { return CanonicalName; } -#endif // !__WXMSW__ +#endif // !__WINDOWS__ // ---------------------------------------------------------------------------- @@ -247,10 +246,8 @@ public: // The loaded catalog will be used for message lookup by GetString(). // // Returns 'true' if it was successfully loaded - bool AddCatalog(const wxString& domain) - { return m_translations.AddCatalog(domain); } - bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage) - { return m_translations.AddCatalog(domain, msgIdLanguage); } + bool AddCatalog(const wxString& domain); + bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage); bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage, const wxString& msgIdCharset); @@ -258,8 +255,7 @@ public: static bool IsAvailable(int lang); // check if the given catalog is loaded - bool IsLoaded(const wxString& domain) const - { return m_translations.IsLoaded(domain); } + bool IsLoaded(const wxString& domain) const; // Retrieve the language info struct for the given language // @@ -300,15 +296,15 @@ public: const wxString& GetString(const wxString& origString, const wxString& domain = wxEmptyString) const { - return m_translations.GetString(origString, domain); + return wxGetTranslation(origString, domain); } // plural form version of the same: const wxString& GetString(const wxString& origString, const wxString& origString2, - size_t n, + unsigned n, const wxString& domain = wxEmptyString) const { - return m_translations.GetString(origString, origString2, n, domain); + return wxGetTranslation(origString, origString2, n, domain); } // this is hack to work around a problem with wxGetTranslation() which @@ -322,10 +318,7 @@ public: // return the contents of .po file header wxString GetHeaderValue(const wxString& header, - const wxString& domain = wxEmptyString) const - { - return m_translations.GetHeaderValue(header, domain); - } + const wxString& domain = wxEmptyString) const; // These two methods are for internal use only. First one creates // ms_languagesDB if it doesn't already exist, second one destroys