diff --git a/include/wx/translation.h b/include/wx/translation.h index 2ca62cf4cc..95e293c2f6 100644 --- a/include/wx/translation.h +++ b/include/wx/translation.h @@ -141,8 +141,8 @@ public: // add catalog with given domain name and language, looking it up via // wxTranslationsLoader - bool AddCatalog(const wxString& domain); - bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage); + bool AddCatalog(const wxString& domain, + wxLanguage msgIdLanguage = wxLANGUAGE_ENGLISH_US); #if !wxUSE_UNICODE bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage, diff --git a/interface/wx/translation.h b/interface/wx/translation.h index 3bfbccd2c9..abe020ff73 100644 --- a/interface/wx/translation.h +++ b/interface/wx/translation.h @@ -157,21 +157,11 @@ public: All loaded catalogs will be used for message lookup by GetString() for the current locale. - In this overload, @c msgid strings are assumed + Bu default, i.e. if @a msgIdLanguage is not given, @c msgid strings are assumed to be in English and written only using 7-bit ASCII characters. If you have to deal with non-English strings or 8-bit characters in the source code, see the instructions in @ref overview_nonenglish. - @return - @true if catalog was successfully loaded, @false otherwise (which might - mean that the catalog is not found or that it isn't in the correct format). - */ - bool AddCatalog(const wxString& domain); - - /** - Same as AddCatalog(const wxString&), but takes an additional argument, - @a msgIdLanguage. - @param domain The catalog domain to add. @@ -186,7 +176,8 @@ public: @true if catalog was successfully loaded, @false otherwise (which might mean that the catalog is not found or that it isn't in the correct format). */ - bool AddCatalog(const wxString& domain, wxLanguage msgIdLanguage); + bool AddCatalog(const wxString& domain, + wxLanguage msgIdLanguage = wxLANGUAGE_ENGLISH_US); /** Same as AddCatalog(const wxString&, wxLanguage), but takes two diff --git a/src/common/translation.cpp b/src/common/translation.cpp index f82c08f4fa..bc0213d2e3 100644 --- a/src/common/translation.cpp +++ b/src/common/translation.cpp @@ -1485,12 +1485,6 @@ bool wxTranslations::AddStdCatalog() return true; } - -bool wxTranslations::AddCatalog(const wxString& domain) -{ - return AddCatalog(domain, wxLANGUAGE_ENGLISH_US); -} - #if !wxUSE_UNICODE bool wxTranslations::AddCatalog(const wxString& domain, wxLanguage msgIdLanguage,