[gnome-tweak-tool] AppChooser: Add a default response
- From: Phillip Wood <pwood src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-tweak-tool] AppChooser: Add a default response
- Date: Wed, 29 Apr 2015 09:53:05 +0000 (UTC)
commit 82924af7342a712d64720a3097ba29c24987b260
Author: Phillip Wood <phillip wood dunelm org uk>
Date: Fri Mar 27 11:04:00 2015 +0000
AppChooser: Add a default response
Adding a default response improves the keyboard navigation as the user
can select an application by pressing ‘Enter’. It also changes the style
of the ‘Add Application’ button.
https://bugzilla.gnome.org/show_bug.cgi?id=747983
gtweak/tweaks/tweak_group_startup.py | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/gtweak/tweaks/tweak_group_startup.py b/gtweak/tweaks/tweak_group_startup.py
index e897374..2862ee3 100644
--- a/gtweak/tweaks/tweak_group_startup.py
+++ b/gtweak/tweaks/tweak_group_startup.py
@@ -40,6 +40,7 @@ class _AppChooser(Gtk.Dialog):
self.entry = Gtk.SearchEntry(
placeholder_text=_("Search Applications..."))
self.entry.set_width_chars(30)
+ self.entry.props.activates_default=True
self.searchbar = Gtk.SearchBar()
self.searchbar.add(self.entry)
@@ -72,6 +73,7 @@ class _AppChooser(Gtk.Dialog):
self.add_button(_("_Close"), Gtk.ResponseType.CLOSE)
self.add_button(_("Add Application"), Gtk.ResponseType.OK)
+ self.set_default_response(Gtk.ResponseType.OK)
self.get_content_area().pack_start(self.searchbar, False, False, 0)
self.get_content_area().pack_start(sw, True, True, 0)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]