Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src/jarabe/journal/objectchooser.py
diff options
context:
space:
mode:
authorGonzalo Odiard <gonzalo@laptop.org>2012-09-10 17:01:35 (GMT)
committer Simon Schampijer <simon@laptop.org>2012-09-10 17:05:13 (GMT)
commite54c3b4ebee7064be29955a85ebb9f9a1dfc9d54 (patch)
treec6f2cd1a07658778a4d1e026db5cf0013d58204f /src/jarabe/journal/objectchooser.py
parent39ca0e61d4ed66efa15a44deae0251869bc5d923 (diff)
ObjectChooser: connect the clear-clicked signal, SL #3848
When there is no match in the search result and you click on the "Clear Search" button this is handled now correctly. Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org> Acked-by: Simon Schampijer <simon@laptop.org>
Diffstat (limited to 'src/jarabe/journal/objectchooser.py')
-rw-r--r--src/jarabe/journal/objectchooser.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/jarabe/journal/objectchooser.py b/src/jarabe/journal/objectchooser.py
index 662a282..d860b0d 100644
--- a/src/jarabe/journal/objectchooser.py
+++ b/src/jarabe/journal/objectchooser.py
@@ -86,6 +86,7 @@ class ObjectChooser(Gtk.Window):
self._list_view = ChooserListView()
self._list_view.connect('entry-activated', self.__entry_activated_cb)
+ self._list_view.connect('clear-clicked', self.__clear_clicked_cb)
vbox.pack_start(self._list_view, True, True, 0)
self._list_view.show()
@@ -136,6 +137,9 @@ class ObjectChooser(Gtk.Window):
visible = event.get_state() == Gdk.VisibilityState.FULLY_OBSCURED
self._list_view.set_is_visible(visible)
+ def __clear_clicked_cb(self, list_view):
+ self._toolbar.clear_query()
+
class TitleBox(VolumesToolbar):
__gtype_name__ = 'TitleBox'