]> code.delx.au - pymsnt/blobdiff - src/lang.py
Reject authorisation for new contacts should work now.
[pymsnt] / src / lang.py
index 0e616e44ad231023fe8314897841e7ff242677d1..477188a65fdc37f45d9b64c31fb3d1b2a0561e19 100644 (file)
@@ -3,13 +3,14 @@
 import config
 
 def get(lang=config.lang):
-       if not (lang.__class__ == str or lang.__class__ == unicode):
+       if not isinstance(lang, basestring):
                lang = config.lang
-       try:
-               lang = lang.replace("-", "_")
-               return strings.__dict__[lang]
-       except KeyError:
-               return strings.__dict__[config.lang]
+       lang = lang.replace("-", "_")
+       if hasattr(strings, lang):
+               return getattr(strings, lang)
+       if hasattr(strings, config.lang):
+               return getattr(strings, config.lang)
+       return strings.en
 
 
 # If you change or add any strings in this file please contact the translators listed below
@@ -39,7 +40,9 @@ class strings:
                msnDroppedMessage = u"(Automated message)\nA message from this person did not get delivered to you. Please report this to your Jabber server administrator."
                msnInitialMail = u"Hotmail notification\n\nUnread message in inbox: %s\nUnread messages in folders: %s"
                msnRealtimeMail = u"Hotmail notification\n\nFrom: %s <%s>\n Subject: %s"
-               msnDisconnected = u"Disconnection from MSN servers: %s"
+               msnDisconnected = u"Disconnected from MSN servers: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
 
                command_CommandList = u"PyMSNt Commands"
                command_Done = "Command completed."
@@ -85,6 +88,8 @@ class strings:
                msnInitialMail = u"Hotmail notification\n\nUnread message in inbox: %s\nUnread messages in folders: %s"
                msnRealtimeMail = u"Hotmail notification\n\nFrom: %s <%s>\n Subject: %s"
                msnDisconnected = u"Desligado dos servidores MSN: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
 
                command_CommandList = u"PyMSNt Commands"
                command_Done = "Command completed."
@@ -126,6 +131,8 @@ class strings:
                msnInitialMail = u"Hotmail-meldingen\n\nAantal ongelezen berichten in postvak in: %s\nAantal ongelezen berichten in mappen: %s"
                msnRealtimeMail = u"Hotmail-meldingen\n\nVan: %s <%s>\n Onderwerp: %s"
                msnDisconnected = u"De verbinding met de MSN-servers werd verbroken: %s"
+               msnConnectFailed = u"Verbinden met MSN-servers mislukte: %s"
+               msnFtSizeRejected = u"Het bestand '%s' werd geweigerd omdat het groter was dan %s. Als u grotere bestanden naar deze contactpersoon wilt verzenden, gebruik dan Jabber. Zie %s voor details."
 
                command_CommandList = u"Commando's voor PyMSNt"
                command_Done = "Commando beëindigd."
@@ -171,6 +178,8 @@ class strings:
                msnInitialMail = u"Hotmail notification\n\nUngelesene Nachrichten in der Inbox: %s\nUngelesene Nachrichten in anderen Ordnern: %s"
                msnRealtimeMail = u"Hotmail notification\n\nNeue Nachricht von %s <%s>\n Subject: %s"
                msnDisconnected = u"Die Verbindung zum MSN-Server wurde getrennt: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
 
                command_CommandList = u"PyMSNt Commands"
                command_Done = "Command completed."
@@ -213,6 +222,8 @@ class strings:
                msnInitialMail = u"Notification Hotmail\n\n Message(s) non lu(s) dans votre boîte de réception : %s\nMessage(s) non lu(s) dans le dossier : %s"
                msnRealtimeMail = u"Notification Hotmail\n\nDe: %s <%s>\n Sujet: %s"
                msnDisconnected = u"Déconnecté du serveur MSN: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
                
                command_CommandList = u"Commandes PyMSNt"
                command_Done = "Command completed."
@@ -260,6 +271,8 @@ class strings:
                msnInitialMail = u"Notificación de Hotmail\n\nMensajes sin leer en la bandeja de entrada: %s\nMensajes sin leer en otras carpetas: %s"
                msnRealtimeMail = u"Notificación de Hotmail\n\nDe: %s <%s>\nAsunto: %s"
                msnDisconnected = u"Desconexión de los servidores MSN: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
 
                command_CommandList = u"PyMSNt Commands"
                command_Done = "Command completed."
@@ -320,6 +333,8 @@ class strings:
                msnInitialMail = u"Powiadomienie Hotmail\n\nNieprzeczytane wiadomości w skrzynce odbiorczej: %s\nNieprzeczytane wiadomości w folderach: %s"
                msnRealtimeMail = u"Powiadomienie Hotmail\n\nOd: %s <%s>\n Temat: %s"
                msnDisconnected = u"Rozłączenie z sieci MSN: %s"
+               msnConnectFailed = u"Failed to connect to MSN servers: %s"
+               msnFtSizeRejected = u"A file '%s' was rejected because it was over the size limit of %s. To send larger files to this person, please use Jabber. See %s for details."
 
                command_CommandList = u"Polecenia PyMSNt"
                command_Done = "Polecenie zakończone."