text: Respect no-emoji hint fully
authorMatthias Clasen <mclasen@redhat.com>
Sun, 21 Aug 2022 20:29:41 +0000 (16:29 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Sun, 21 Aug 2022 20:31:14 +0000 (16:31 -0400)
We were disabling the insert-emoji action when the
no-emoji input hint is set, but the Ctrl-. shortcut
was bypassing the action and kept working. Make
the shortcut activate the action instead.

Fixes: #5123
gtk/gtktext.c

index 70b100fa55499862f08853daa1d5ef08cad77757..5eb216e14d30f26f4264158201b6b662c9c464ac 100644 (file)
@@ -1487,13 +1487,13 @@ gtk_text_class_init (GtkTextClass *class)
                                        NULL);
 
   /* Emoji */
-  gtk_widget_class_add_binding_signal (widget_class,
+  gtk_widget_class_add_binding_action (widget_class,
                                        GDK_KEY_period, GDK_CONTROL_MASK,
-                                       "insert-emoji",
+                                       "misc.insert-emoji",
                                        NULL);
-  gtk_widget_class_add_binding_signal (widget_class,
+  gtk_widget_class_add_binding_action (widget_class,
                                        GDK_KEY_semicolon, GDK_CONTROL_MASK,
-                                       "insert-emoji",
+                                       "misc.insert-emoji",
                                        NULL);
 
   /* Undo/Redo */