From b59199e3c3cfb83e7e1faa5101a3d7f99d5d0539 Mon Sep 17 00:00:00 2001 From: Benny Malengier Date: Tue, 21 Jul 2009 13:27:41 +0000 Subject: [PATCH] 3108: Cannot iterate through/with popup menu on active person's individual events\n and missing embedlist method svn: r12829 --- src/DisplayTabs/_EmbeddedList.py | 9 +++++++++ src/DisplayTabs/_EventEmbedList.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/DisplayTabs/_EmbeddedList.py b/src/DisplayTabs/_EmbeddedList.py index d0e167fec..6bc03a720 100644 --- a/src/DisplayTabs/_EmbeddedList.py +++ b/src/DisplayTabs/_EmbeddedList.py @@ -477,3 +477,12 @@ class EmbeddedList(ButtonTab): def post_rebuild(self): pass + + def rebuild_callback(self): + """ + The view must be remade when data changes outside this tab. + Use this method to connect to after a db change. It makes sure the + data is obtained again from db and the view rebuild + """ + self.changed = True + self.rebuild() diff --git a/src/DisplayTabs/_EventEmbedList.py b/src/DisplayTabs/_EventEmbedList.py index e480ac459..0ea79c1d5 100644 --- a/src/DisplayTabs/_EventEmbedList.py +++ b/src/DisplayTabs/_EventEmbedList.py @@ -204,7 +204,7 @@ class EventEmbedList(GroupEmbeddedList): def get_popup_menu_items(self): if self._tmpgroup == self._WORKGROUP: - GroupEmbeddedList.get_popup_menu_items(self) + return GroupEmbeddedList.get_popup_menu_items(self) else: return [ (True, True, gtk.STOCK_ADD, self.add_button_clicked),