* src/GrampsDb/_GrampsDbBase.py: prevent null event types and

attribute types from being added
	* src/Editors/_EditAttribute.py: prevent null attribute types
	* src/Editors/_EditEvent.py: prevent null attribute types
	* src/AutoComp.py: filter out empty strings
	* src/ImgManip.py: check for file before attempting thumbnailer


svn: r6898
This commit is contained in:
Don Allingham
2006-06-16 03:32:51 +00:00
parent 8366c12818
commit 4cf930d039
6 changed files with 35 additions and 11 deletions

View File

@ -139,6 +139,7 @@ class StandardCustomSelector:
self.active_key = active_key
self.active_index = 0
self.additional = additional
# make model
self.store = gtk.ListStore(int,str)
@ -176,9 +177,11 @@ class StandardCustomSelector:
if self.additional:
for event_type in self.additional:
if type(event_type) == str or type(event_type) == unicode :
self.store.append(row=[self.custom_key, event_type])
if event_type:
self.store.append(row=[self.custom_key, event_type])
elif type(event_type) == tuple:
self.store.append(row=[event_type[0], event_type[1]])
if event_type[1]:
self.store.append(row=[event_type[0], event_type[1]])
else:
self.store.append(row=[int(event_type), str(event_type)])
if key == self.active_key: