[Scummvm-cvs-logs] SF.net SVN: scummvm:[49872] scummvm/trunk/common/translation.h

lordhoto at users.sourceforge.net lordhoto at users.sourceforge.net
Tue Jun 15 19:34:08 CEST 2010


Revision: 49872
          http://scummvm.svn.sourceforge.net/scummvm/?rev=49872&view=rev
Author:   lordhoto
Date:     2010-06-15 17:34:07 +0000 (Tue, 15 Jun 2010)

Log Message:
-----------
Extend (and along with it add) some doxygen comments.

Modified Paths:
--------------
    scummvm/trunk/common/translation.h

Modified: scummvm/trunk/common/translation.h
===================================================================
--- scummvm/trunk/common/translation.h	2010-06-15 17:33:45 UTC (rev 49871)
+++ scummvm/trunk/common/translation.h	2010-06-15 17:34:07 UTC (rev 49872)
@@ -79,18 +79,40 @@
 	TranslationManager();
 	~TranslationManager();
 
+	/**
+	 * Retrieves the language string to the given id.
+	 *
+	 * @param id Id of the language
+	 * @return the matching string description of the language
+	 */
 	const char *getLangById(int id);
 
 	/**
 	 * Sets the current translation language to the one specified in the
 	 * parameter. If the parameter is an empty string, it sets the default
 	 * system language.
+	 *
+	 * @param lang Language to setup.
 	 */
-	void setLanguage(const char *);
+	void setLanguage(const char *lang);
+
+	/**
+	 * Sets the current translation language to the one specified by the
+	 * id parameter.
+	 *
+	 * @param id The id of the language.
+	 */
 	void setLanguage(int id) {
 		setLanguage(getLangById(id));
 	}
 
+	/**
+	 * Parses a language string and returns an id instead.
+	 *
+	 * @param lang Language string
+	 * @return id of the language or kTranslationBuiltinId in case the
+	 *         language could not be found.
+	 */
 	int parseLanguage(const String lang);
 
 	/**
@@ -100,6 +122,11 @@
 	 */
 	const char *getTranslation(const char *message);
 
+	/**
+	 * Returns the translation into the current language of the parameter
+	 * message. In case the message isn't found in the translation catalog,
+	 * it returns the original untranslated message.
+	 */
 	String getTranslation(const String &message);
 
 	/**
@@ -108,6 +135,11 @@
 	 */
 	const char *convertTerm(const char *message);
 
+	/**
+	 * Returns a list of supported languages.
+	 *
+	 * @return The list of supported languages.
+	 */
 	const TLangArray getSupportedLanguages() const;
 };
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list