From 41515d57cfc6f823a5d7a3edfc2561dbd93946b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Rapinat?= Date: Wed, 11 Feb 2009 14:02:13 +0000 Subject: [PATCH] #2700 #2490 do not translate argument on custom_filter.xml (Benny) svn: r11964 --- src/FilterEditor/_EditRule.py | 9 +++++---- src/Filters/Rules/_HasGalleryBase.py | 4 ++-- src/Filters/Rules/_HasLDSBase.py | 4 ++-- src/Filters/Rules/_HasNoteBase.py | 4 ++-- src/Filters/Rules/_HasSourceBase.py | 4 ++-- 5 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/FilterEditor/_EditRule.py b/src/FilterEditor/_EditRule.py index 5d689865c..6a160c3d5 100644 --- a/src/FilterEditor/_EditRule.py +++ b/src/FilterEditor/_EditRule.py @@ -195,8 +195,9 @@ class MyLesserEqualGreater(gtk.ComboBox): cell = gtk.CellRendererText() self.pack_start(cell, True) self.add_attribute(cell, 'text', 0) - self.clist = [_('lesser than'), _('equal to'), _('greater than')] - for name in self.clist: + self.clist = ['lesser than', 'equal to', 'greater than'] + self.clist_trans = [_('lesser than'), _('equal to'), _('greater than')] + for name in self.clist_trans: store.append(row=[name]) self.set_active(default) self.show() @@ -204,14 +205,14 @@ class MyLesserEqualGreater(gtk.ComboBox): def get_text(self): active = self.get_active() if active < 0: - return _('equal to') + return 'equal to' return self.clist[active] def set_text(self, val): if val in self.clist: self.set_active(self.clist.index(val)) else: - self.set_active(self.clist.index(_('equal to'))) + self.set_active(self.clist.index('equal to')) #------------------------------------------------------------------------- # diff --git a/src/Filters/Rules/_HasGalleryBase.py b/src/Filters/Rules/_HasGalleryBase.py index 1a2e63861..db1701cd1 100755 --- a/src/Filters/Rules/_HasGalleryBase.py +++ b/src/Filters/Rules/_HasGalleryBase.py @@ -47,9 +47,9 @@ class HasGalleryBase(Rule): def prepare(self, db): # things we want to do just once, not for every handle - if self.list[1] == _('lesser than'): + if self.list[1] == 'lesser than': self.count_type = 0 - elif self.list[1] == _('greater than'): + elif self.list[1] == 'greater than': self.count_type = 2 else: self.count_type = 1 # "equal to" diff --git a/src/Filters/Rules/_HasLDSBase.py b/src/Filters/Rules/_HasLDSBase.py index 779fd498d..a2aa3e77e 100755 --- a/src/Filters/Rules/_HasLDSBase.py +++ b/src/Filters/Rules/_HasLDSBase.py @@ -50,9 +50,9 @@ class HasLDSBase(Rule): def prepare(self, db): # things we want to do just once, not for every handle - if self.list[1] == _('lesser than'): + if self.list[1] == 'lesser than': self.count_type = 0 - elif self.list[1] == _('greater than'): + elif self.list[1] == 'greater than': self.count_type = 2 else: self.count_type = 1 # "equal to" diff --git a/src/Filters/Rules/_HasNoteBase.py b/src/Filters/Rules/_HasNoteBase.py index 418df1360..8ec781beb 100755 --- a/src/Filters/Rules/_HasNoteBase.py +++ b/src/Filters/Rules/_HasNoteBase.py @@ -56,9 +56,9 @@ class HasNoteBase(Rule): def prepare(self, db): # things we want to do just once, not for every handle - if self.list[1] == _('lesser than'): + if self.list[1] == 'lesser than': self.count_type = 0 - elif self.list[1] == _('greater than'): + elif self.list[1] == 'greater than': self.count_type = 2 else: self.count_type = 1 # "equal to" diff --git a/src/Filters/Rules/_HasSourceBase.py b/src/Filters/Rules/_HasSourceBase.py index 36c8e7618..b666f2cc9 100755 --- a/src/Filters/Rules/_HasSourceBase.py +++ b/src/Filters/Rules/_HasSourceBase.py @@ -48,9 +48,9 @@ class HasSourceBase(Rule): def prepare(self, db): # things we want to do just once, not for every handle - if self.list[1] == _('lesser than'): + if self.list[1] == 'lesser than': self.count_type = 0 - elif self.list[1] == _('greater than'): + elif self.list[1] == 'greater than': self.count_type = 2 else: self.count_type = 1 # "equal to"