* src/EditPerson.py (on_event_update_clicked): Pass callback.

* src/EventEdit.py (__init__): Typo.


svn: r4095
This commit is contained in:
Alex Roitman 2005-02-25 17:29:39 +00:00
parent 1d0989afbc
commit d1e4b324ba
3 changed files with 12 additions and 10 deletions

View File

@ -11,6 +11,9 @@
* src/NameEdit.py (__init__): Compare displayed name with empty string,
(update_group_as): Only query grouping for existing name.
* src/EditPerson.py (on_event_update_clicked): Pass callback.
* src/EventEdit.py (__init__): Typo.
2005-02-24 Alex Roitman <shura@alex.neuro.umn.edu>
* src/MediaView.py (on_select_row): Add garbage collection call.

View File

@ -1658,7 +1658,7 @@ class EditPerson:
event = self.etree.get_object(node)
EventEdit.EventEditor(self,pname,const.personalEvents,
const.personal_events,event,None,0,
noedit=self.db.readonly)
self.event_edit_callback,noedit=self.db.readonly)
def on_event_select_row(self,obj):
store,node = obj.get_selected()

View File

@ -1,7 +1,7 @@
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2000-2004 Donald N. Allingham
# Copyright (C) 2000-2005 Donald N. Allingham
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@ -25,7 +25,6 @@
# Python modules
#
#-------------------------------------------------------------------------
from string import strip
from gettext import gettext as _
#-------------------------------------------------------------------------
@ -153,7 +152,7 @@ class EventEditor:
self.witnesses_label = self.top.get_widget("witnessesEvent")
self.top.get_widget('ok').set_sensitive(not noedit)
if read_only or not noedit:
if read_only or noedit:
self.event_menu.set_sensitive(False)
self.date_field.grab_focus()
@ -203,11 +202,11 @@ class EventEditor:
self.note_field.get_buffer().set_text(event.get_note())
if event.get_note():
self.note_field.get_buffer().set_text(event.get_note())
self.note_field.get_buffer().set_text(event.get_note())
Utils.bold_label(self.notes_label)
if event.get_note_format() == 1:
if event.get_note_format() == 1:
self.preform.set_active(1)
else:
else:
self.flowed.set_active(1)
if event.get_media_list():
Utils.bold_label(self.gallery_label)
@ -218,8 +217,8 @@ class EventEditor:
self.place_field.set_text(def_placename)
self.date_check = DateEdit.DateEdit(self.date,
self.date_field,
self.top.get_widget("date_stat"),
self.window)
self.top.get_widget("date_stat"),
self.window)
if not event:
event = RelLib.Event()
@ -298,7 +297,7 @@ class EventEditor:
gnome.help_display('gramps-manual','gramps-edit-complete')
def get_place(self,field):
text = strip(unicode(field.get_text()))
text = unicode(field.get_text()).strip()
if text:
if self.pmap.has_key(text):
return self.parent.db.get_event_from_handle(self.pmap[text])