[file-roller/wip/iainl/keypress-fixes: 309/312] fr-window: Use GDK_EVENT_PROPAGATE/GDK_EVENT_STOP
- From: Jan Tojnar <jtojnar src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [file-roller/wip/iainl/keypress-fixes: 309/312] fr-window: Use GDK_EVENT_PROPAGATE/GDK_EVENT_STOP
- Date: Wed, 30 Mar 2022 18:51:14 +0000 (UTC)
commit 9b328918a9d740b8915ce56af15b08ffa70d8f5d
Author: Iain Lane <iainl gnome org>
Date: Tue Apr 23 11:50:38 2019 +0100
fr-window: Use GDK_EVENT_PROPAGATE/GDK_EVENT_STOP
These are much clearer to understand than TRUE/FALSE.
src/fr-window.c | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
---
diff --git a/src/fr-window.c b/src/fr-window.c
index 787cc0ed..4aa5445d 100644
--- a/src/fr-window.c
+++ b/src/fr-window.c
@@ -4796,17 +4796,17 @@ key_press_cb (GtkWidget *widget,
gpointer data)
{
FrWindow *window = data;
- gboolean retval = FALSE;
+ gboolean retval = GDK_EVENT_PROPAGATE;
gboolean alt;
if (gtk_widget_has_focus (window->priv->location_entry))
- return FALSE;
+ return GDK_EVENT_PROPAGATE;
if (gtk_widget_has_focus (window->priv->filter_entry)) {
switch (event->keyval) {
case GDK_KEY_Escape:
fr_window_deactivate_filter (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
break;
default:
break;
@@ -4821,7 +4821,7 @@ key_press_cb (GtkWidget *widget,
fr_window_stop (window);
if (window->priv->filter_mode)
fr_window_deactivate_filter (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
break;
case GDK_KEY_F10:
@@ -4830,10 +4830,10 @@ key_press_cb (GtkWidget *widget,
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (window->priv->list_view));
if (selection == NULL)
- return FALSE;
+ return GDK_EVENT_PROPAGATE;
gtk_menu_popup_at_pointer (GTK_MENU (window->priv->file_popup_menu), (GdkEvent *)
event);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
@@ -4841,20 +4841,20 @@ key_press_cb (GtkWidget *widget,
case GDK_KEY_KP_Up:
if (alt) {
fr_window_go_up_one_level (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
case GDK_KEY_BackSpace:
fr_window_go_up_one_level (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
break;
case GDK_KEY_Right:
case GDK_KEY_KP_Right:
if (alt) {
fr_window_go_forward (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
@@ -4862,7 +4862,7 @@ key_press_cb (GtkWidget *widget,
case GDK_KEY_KP_Left:
if (alt) {
fr_window_go_back (window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
@@ -4870,14 +4870,14 @@ key_press_cb (GtkWidget *widget,
case GDK_KEY_KP_Home:
if (alt) {
fr_window_go_to_location (window, "/", FALSE);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
case GDK_KEY_Delete:
if (! gtk_widget_has_focus (window->priv->filter_entry)) {
fr_window_activate_delete (NULL, NULL, window);
- retval = TRUE;
+ retval = GDK_EVENT_STOP;
}
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]