[kupfer: 5/13] plugin.google_translate: Change action name



commit acb9562b4e780b1a245be6c7c4a60ef643da6299
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date:   Fri Oct 30 00:28:31 2009 +0100

    plugin.google_translate: Change action name
    
    This is just a *suggestion* for action and object names that align
    better with Kupfer's current customs.
    
    An action that requires an indirect "third" object should mostly have
    a name ending with "..."
    
    If we name the language objects simply "English" we can read the
    action like a sentence:
    
    	(Block of text) -> Translate To... -> English
    
    This mimics the common SVO sentence structure of many languages.
    Does it fit well with Polish?

 kupfer/plugin/google_translate.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/kupfer/plugin/google_translate.py b/kupfer/plugin/google_translate.py
index adc3812..fc2a814 100644
--- a/kupfer/plugin/google_translate.py
+++ b/kupfer/plugin/google_translate.py
@@ -111,7 +111,7 @@ def _load_languages():
 
 class Translate (Action):
 	def __init__(self):
-		Action.__init__(self, _("Translate"))
+		Action.__init__(self, _("Translate To..."))
 
 	def activate(self, leaf, iobj):
 		text = unicode(leaf.object)
@@ -169,7 +169,7 @@ class _LangSource(Source):
 	def get_items(self):
 		if not self._LANG_CACHE:
 			self._LANG_CACHE = tuple((
-					_Language(key, _("Translate into %s") % name)
+					_Language(key, name.title())
 					for key, name in _load_languages()
 			))
 		return self._LANG_CACHE



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