* src/Selectors/_SelectPerson.py: enable toggle button to display all
* src/glade/gramps.glade: add toggle button svn: r7379
This commit is contained in:
parent
ea0e6248f1
commit
a7815500e6
@ -1,4 +1,6 @@
|
||||
2006-10-09 Don Allingham <don@gramps-project.org>
|
||||
* src/Selectors/_SelectPerson.py: enable toggle button to display all
|
||||
* src/glade/gramps.glade: add toggle button
|
||||
* src/Editors/_EditPerson.py: add person's name to title
|
||||
* src/RelLib/_Name.py: add empty check
|
||||
|
||||
|
@ -65,19 +65,39 @@ class SelectPerson(ManagedWindow.ManagedWindow):
|
||||
self.db = dbstate.db
|
||||
self.glade = gtk.glade.XML(const.gladeFile,"select_person","gramps")
|
||||
self.plist = self.glade.get_widget('plist')
|
||||
self.showall = self.glade.get_widget('showall')
|
||||
self.notebook = self.glade.get_widget('notebook')
|
||||
|
||||
window = self.glade.get_widget('select_person')
|
||||
title_label = self.glade.get_widget('title')
|
||||
self.set_window(window,title_label,self.title)
|
||||
|
||||
self.filter = filter
|
||||
if self.filter:
|
||||
self.showall.show()
|
||||
|
||||
self.skip = skip
|
||||
|
||||
self.model = PeopleModel(self.db,
|
||||
(PeopleModel.FAST, filter),
|
||||
skip=skip)
|
||||
|
||||
self.add_columns(self.plist)
|
||||
self.plist.set_model(self.model)
|
||||
self.showall.connect('toggled',self.show_toggle)
|
||||
self.show()
|
||||
|
||||
def show_toggle(self, obj):
|
||||
if obj.get_active():
|
||||
filt = None
|
||||
else:
|
||||
filt = self.filter
|
||||
|
||||
self.model = PeopleModel(self.db,
|
||||
(PeopleModel.FAST, filt),
|
||||
skip=self.skip)
|
||||
self.plist.set_model(self.model)
|
||||
|
||||
def build_menu_names(self,obj):
|
||||
return (self.title, None)
|
||||
|
||||
|
@ -2494,6 +2494,24 @@
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="showall">
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Show all</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="focus_on_click">True</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
|
Loading…
Reference in New Issue
Block a user