[easytag] Fix return type of key-press-event handler



commit 11b2601d87de7bad50ff50ce0156d36ec7280102
Author: David King <amigadave amigadave com>
Date:   Fri May 10 14:08:40 2013 +0100

    Fix return type of key-press-event handler
    
    Return TRUE if the event was handled and FALSE if the event should
    propagate further.

 src/easytag.c |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)
---
diff --git a/src/easytag.c b/src/easytag.c
index e95d69f..fa39bd4 100644
--- a/src/easytag.c
+++ b/src/easytag.c
@@ -133,9 +133,9 @@ static void File_Area_Set_Sensitive (gboolean activate);
 static void Tag_Area_Set_Sensitive  (gboolean activate);
 
 static void et_tag_field_connect_signals (GtkEntry *entry);
-static void et_tag_field_on_key_press_event (GtkEntry *entry,
-                                             GdkEventKey *event,
-                                             gpointer user_data);
+static gboolean et_tag_field_on_key_press_event (GtkEntry *entry,
+                                                 GdkEventKey *event,
+                                                 gpointer user_data);
 
 #ifndef G_OS_WIN32
 static void
@@ -5023,8 +5023,11 @@ et_tag_field_connect_signals (GtkEntry *entry)
  *
  * Handle the Ctrl+Return combination being pressed in the tag field GtkEntrys
  * and apply the tag to selected files.
+ *
+ * Returns: %TRUE if the event was handled, %FALSE if the event should
+ * propagate further
  */
-static void
+static gboolean
 et_tag_field_on_key_press_event (GtkEntry *entry, GdkEventKey *event,
                                  gpointer user_data)
 {
@@ -5037,7 +5040,8 @@ et_tag_field_on_key_press_event (GtkEntry *entry, GdkEventKey *event,
             {
                 Mini_Button_Clicked (G_OBJECT (entry));
             }
+            return TRUE;
         default:
-            break;
+            return FALSE;
     }
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]