* src/DisplayTabs/_EventEmbedList.py: bring up the event reference

editor on drag-n-drop onto the event reference list


svn: r7307
This commit is contained in:
Don Allingham 2006-09-09 22:46:14 +00:00
parent 093bbd3c01
commit bc6666199b
2 changed files with 17 additions and 0 deletions

View File

@ -1,4 +1,6 @@
2006-09-09 Don Allingham <don@gramps-project.org>
* src/DisplayTabs/_EventEmbedList.py: bring up the event reference
editor on drag-n-drop onto the event reference list
* src/GrampsDb/_ReadXML.py: remove commented out code
* src/Editors/_EditEvent.py: handle overwriting of date text
* src/RelLib/_DateBase.py: allow optional dropping of date text on

View File

@ -148,3 +148,18 @@ class EventEmbedList(EmbeddedList):
self.get_data().append(ref)
self.changed = True
self.rebuild()
def _handle_drag(self, row, obj):
"""
And event reference that is from a drag and drop has
an unknown event reference type
"""
from RelLib import EventRoleType
obj.set_role((EventRoleType.UNKNOWN,''))
EmbeddedList._handle_drag(self, row, obj)
event = self.dbstate.db.get_event_from_handle(obj.ref)
self.get_ref_editor()(
self.dbstate, self.uistate, self.track,
event, obj, self.event_updated)