[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [check/master] Display translation names in their language



commit dcd2a0e506d6350f2989c50f0797a5ed0a0adcee
Author: Arlo Breault <arlolra@xxxxxxxxx>
Date:   Tue Feb 25 22:36:41 2014 +0000

    Display translation names in their language
    
    Part of trac 10171.
---
 public/index.html |    2 +-
 utils.go          |   68 ++++++++++++++++++++++++++++++++---------------------
 2 files changed, 42 insertions(+), 28 deletions(-)

diff --git a/public/index.html b/public/index.html
index eb81799..dec740a 100644
--- a/public/index.html
+++ b/public/index.html
@@ -90,7 +90,7 @@
       {{ GetText .Lang "If you are attempting to use a Tor client, please refer to the <a href=\"https://www.torproject.org/\";>Tor website</a> and specifically the <a href=\"https://www.torproject.org/docs/faq#DoesntWork\";>instructions for configuring your Tor client</a>." | UnEscaped }}
     {{ end }}
   </p>
-  <a id="donate" href="https://www.torproject.org/donate/donate.html";>Donate to Support Tor</a>
+  <a id="donate" href="https://www.torproject.org/donate/donate.html";>{{ GetText .Lang "Donate to Support Tor" }}</a>
   <ul id="links">
     <li>
       <a href="https://torproject.org/dist/manual/short-user-manual_{{ UserManual .Lang }}.xhtml">{{ GetText .Lang "Short User Manual" }}</a>
diff --git a/utils.go b/utils.go
index d4912e7..1c85b28 100644
--- a/utils.go
+++ b/utils.go
@@ -125,34 +125,48 @@ type locale struct {
 }
 
 func GetLocaleList(base string) map[string]string {
-	// TODO: This should be it's own translation file
+	// populated from https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes
 	haveTranslatedNames := map[string]string{
-		"ar":    "&#1593;&#1585;&#1576;&#1610;&#1577;&nbsp;(Arabiya)",
-		"bms":   "Burmese",
-		"cs":    "&#269;esky",
-		"da":    "Dansk",
-		"de":    "Deutsch",
-		"el":    "&#917;&#955;&#955;&#951;&#957;&#953;&#954;&#940;&nbsp;(Ellinika)",
-		"en_US": "English",
-		"es":    "Espa&ntilde;ol",
-		"et":    "Estonian",
-		"fa_IR": "&#1601;&#1575;&#1585;&#1587;&#1740; (F&#257;rs&#299;)",
-		"fr":    "Fran&ccedil;ais",
-		"it_IT": "Italiano",
-		"ja":    "&#26085;&#26412;&#35486;&nbsp;(Nihongo)",
-		"nb":    "Norsk&nbsp;(Bokm&aring;l)",
-		"nl":    "Nederlands",
-		"pl":    "Polski",
-		"pt":    "Portugu&ecirc;s",
-		"pt_BR": "Portugu&ecirc;s do Brasil",
-		"ro":    "Rom&acirc;n&#259;",
-		"fi":    "Suomi",
-		"ru":    "&#1056;&#1091;&#1089;&#1089;&#1082;&#1080;&#1081;&nbsp;(Russkij)",
-		"th":    "Thai",
-		"tr":    "T&uuml;rk&ccedil;e",
-		"uk":    "&#1091;&#1082;&#1088;&#1072;&#1111;&#1085;&#1089;&#1100;&#1082;&#1072;&nbsp;(Ukrajins\"ka)",
-		"vi":    "Vietnamese",
-		"zh_CN": "&#20013;&#25991;(&#31616;)",
+		"ar": "اÙ?عربÙ?Ø©",
+		"bs": "Bosanski jezik",
+		"ca": "Català",
+		"cs": "Ä?eÅ¡tina",
+		"cy": "Cymraeg",
+		"da": "Dansk",
+		"de": "Deutsch",
+		"el": "ελληνικά",
+		"es": "Español",
+		"et": "Eesti",
+		"eu": "Euskara",
+		"fa": "Ù?ارسÛ?",
+		"fi": "Suomi",
+		"fr": "Français",
+		"gl": "Galego",
+		"he": "×¢×?ר×?ת",
+		"hi": "हिन�द�, हि�द�",
+		"hr": "Hrvatski jezik",
+		"hu": "Magyar",
+		"id": "Bahasa Indonesia",
+		"it": "Italiano",
+		"ja": "���",
+		"km": "á??á??á??",
+		"kn": "�ನ�ನಡ",
+		"ko": "í??êµ­ì?´",
+		"lv": "Latviešu valoda",
+		"my": "á??á??á?¬á??á?¬",
+		"nb": "Norsk bokmål",
+		"nl": "Nederlands",
+		"pa": "ਪੰ�ਾਬ�",
+		"pl": "JÄ?zyk polski",
+		"pt": "Português",
+		"ru": "Ñ?Ñ?Ñ?Ñ?кий Ñ?зÑ?к",
+		"sk": "SlovenÄ?ina",
+		"sl": "Slovenski jezik",
+		"sr": "Ñ?Ñ?пÑ?ки Ñ?език",
+		"sv": "Svenska",
+		"th": "��ย",
+		"tr": "Türkçe",
+		"uk": "Ñ?кÑ?аÑ?нÑ?Ñ?ка мова",
 	}
 
 	// for all folders in locale which match a locale from https://www.transifex.com/api/2/languages/

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits