summaryrefslogtreecommitdiff
path: root/src/contacts-window.vala
diff options
context:
space:
mode:
authorAdrien Plazas <kekun.plazas@laposte.net>2019-12-10 13:09:39 +0100
committerAdrien Plazas <kekun.plazas@laposte.net>2019-12-13 12:36:12 +0100
commit88e741e74edda25e1cf9a3d7e960fec9a4f1fcb3 (patch)
tree4bf31a555ca32dadf7b26b2b97f56280d39dcc52 /src/contacts-window.vala
parent116213333d8011931ae61c9b5fa105271550f657 (diff)
downloadgnome-contacts-88e741e74edda25e1cf9a3d7e960fec9a4f1fcb3.tar.gz
window: Add a "back" gesture
This makes moving back to the contacts list more comfortable on a phone.
Diffstat (limited to 'src/contacts-window.vala')
-rw-r--r--src/contacts-window.vala5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/contacts-window.vala b/src/contacts-window.vala
index e427a32..2b648f0 100644
--- a/src/contacts-window.vala
+++ b/src/contacts-window.vala
@@ -232,6 +232,11 @@ public class Contacts.Window : Gtk.ApplicationWindow {
}
// When selecting or editing, we get special headerbars
this.titlebar.selection_mode = this.state == UiState.SELECTING || this.state.editing ();
+
+ // Allow the back gesture when not browsing
+ this.content_box.can_swipe_back = this.state == UiState.NORMAL ||
+ this.state == UiState.SHOWING ||
+ this.state == UiState.SELECTING;
}
[GtkCallback]