Merge pull request #47 from sam-m888/8352changelessertoless
8352 Change "lesser than" to "less than"
This commit is contained in:
commit
6d1689467e
@ -49,7 +49,7 @@ 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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -60,7 +60,7 @@ class HasGalleryBase(Rule):
|
||||
|
||||
def apply(self, db, obj):
|
||||
count = len( obj.get_media_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -52,7 +52,7 @@ 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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -63,7 +63,7 @@ class HasLDSBase(Rule):
|
||||
|
||||
def apply(self, db, obj):
|
||||
count = len( obj.get_lds_ord_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -58,7 +58,7 @@ 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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -70,7 +70,7 @@ class HasNoteBase(Rule):
|
||||
|
||||
def apply(self, db, obj):
|
||||
count = len( obj.get_note_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -47,7 +47,7 @@ class HasReferenceCountBase(Rule):
|
||||
|
||||
def prepare(self, db):
|
||||
# things we want to do just once, not for every handle
|
||||
if self.list[0] == 'lesser than':
|
||||
if self.list[0] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[0] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -63,7 +63,7 @@ class HasReferenceCountBase(Rule):
|
||||
for item in db.find_backlink_handles(handle):
|
||||
count += 1
|
||||
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -50,7 +50,7 @@ class HasSourceCountBase(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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -61,7 +61,7 @@ class HasSourceCountBase(Rule):
|
||||
|
||||
def apply(self, db, obj):
|
||||
count = len(obj.get_citation_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -53,7 +53,7 @@ class HasAddress(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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -64,7 +64,7 @@ class HasAddress(Rule):
|
||||
|
||||
def apply(self, db, person):
|
||||
count = len( person.get_address_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -52,7 +52,7 @@ class HasAssociation(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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -63,7 +63,7 @@ class HasAssociation(Rule):
|
||||
|
||||
def apply(self, db, person):
|
||||
count = len(person.get_person_ref_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.selected_count
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.selected_count
|
||||
|
@ -50,7 +50,7 @@ class HasRepository(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] == 'less than':
|
||||
self.count_type = 0
|
||||
elif self.list[1] == 'greater than':
|
||||
self.count_type = 2
|
||||
@ -61,7 +61,7 @@ class HasRepository(Rule):
|
||||
|
||||
def apply(self, db, obj):
|
||||
count = len(obj.get_reporef_list())
|
||||
if self.count_type == 0: # "lesser than"
|
||||
if self.count_type == 0: # "less than"
|
||||
return count < self.userSelectedCount
|
||||
elif self.count_type == 2: # "greater than"
|
||||
return count > self.userSelectedCount
|
||||
|
@ -243,8 +243,8 @@ 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']
|
||||
self.clist_trans = [_('lesser than'), _('equal to'), _('greater than')]
|
||||
self.clist = ['less than', 'equal to', 'greater than']
|
||||
self.clist_trans = [_('less than'), _('equal to'), _('greater than')]
|
||||
for name in self.clist_trans:
|
||||
store.append(row=[name])
|
||||
self.set_active(default)
|
||||
|
Loading…
Reference in New Issue
Block a user