[conduit] Fixed Flickr configuration and added translation strings.
- From: Alexandre Rosenfeld <arosenfeld src gnome org>
- To: svn-commits-list gnome org
- Subject: [conduit] Fixed Flickr configuration and added translation strings.
- Date: Wed, 27 May 2009 22:41:35 -0400 (EDT)
commit 6d33db96bd092f58a19f928d307d4a5f8e1d5286
Author: Alexandre Rosenfeld <airmind gmail com>
Date: Sat May 23 11:08:35 2009 -0300
Fixed Flickr configuration and added translation strings.
---
conduit/modules/FlickrModule/FlickrModule.py | 35 ++++++++++++--------------
1 files changed, 16 insertions(+), 19 deletions(-)
diff --git a/conduit/modules/FlickrModule/FlickrModule.py b/conduit/modules/FlickrModule/FlickrModule.py
index 4c7b893..a106370 100644
--- a/conduit/modules/FlickrModule/FlickrModule.py
+++ b/conduit/modules/FlickrModule/FlickrModule.py
@@ -279,20 +279,17 @@ class FlickrTwoWay(Image.ImageTwoWay):
def _login_finished(*args):
try:
if self.logged_in:
- status_label.value = 'Loading album list...'
+ status_label.value = _('Loading album list...')
try:
#FIXME: Blocks and brings the whole UI with it.
photosets = self._get_photosets()
except:
- status_label.value = '<span foreground="red">Failed to connect.</span>'
+ status_label.value = _('Failed to connect.')
else:
photoset_config.choices = [name for name, photoSetId in photosets]
- status_label.value = 'Album names loaded.'
+ status_label.value = _('Album names loaded.')
else:
- #FIXME: The red color is pretty eye-candy, but might be too
- #distracting and unnecessary, we should re-evaluate it's
- #usefulness
- status_label.value = '<span foreground="red">Failed to login.</span>'
+ status_label.value = _('Failed to login.')
finally:
load_photosets_config.enabled = True
account_section.enabled = True
@@ -302,36 +299,36 @@ class FlickrTwoWay(Image.ImageTwoWay):
config.set_busy(True)
load_photosets_config.enabled = False
account_section.enabled = False
- #FIXME: This applies the username value before OK/Apply is clicked,
- #we should do a better job
username_config.apply()
- status_label.value = 'Logging in, please wait...'
+ status_label.value = _('Logging in, please wait...')
conduit.GLOBALS.syncManager.run_blocking_dataprovider_function_calls(
self, _login_finished, self._login)
- account_section = config.add_section('Account details')
+ account_section = config.add_section(_('Account details'))
username_config = config.add_item('Username', 'text',
config_name = 'username',
)
username_config.connect('value-changed',
lambda item, initial, value: load_photosets_config.set_enabled(bool(value)))
- status_label = config.add_item('Status', 'label',
+ status_label = config.add_item(None, 'label',
initial_value = self.status,
use_markup = True,
+ xalignment = 0.5,
)
- config.add_section('Saved photo settings')
- load_photosets_config = config.add_item("Load photosets", "button",
- initial_value = _load_photosets
- )
+ load_photosets_config = config.add_item(_("Authenticate"), "button",
+ initial_value = _load_photosets,
+ image = "dialog-password"
+ )
+ config.add_section(_('Saved photo settings'))
photoset_config = config.add_item('Photoset name', 'combotext',
config_name = 'photoSetName',
choices = [],
)
- config.add_item("Resize photos", "combo",
- choices = [("None", "Do not resize"), "640x480", "800x600", "1024x768"],
+ config.add_item(_("Resize photos"), "combo",
+ choices = [("None", _("Do not resize")), "640x480", "800x600", "1024x768"],
config_name = "imageSize"
)
- config.add_item('Photos are public', 'check',
+ config.add_item(_('Photos are public'), 'check',
config_name = 'showPublic'
)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]