Hide emoji chooser unless explicitly requested
Resolves: RHEL-65308
This commit is contained in:
parent
4935cfde1c
commit
cc1597e0ed
24
gtk4-no-emoji-context-menu.patch
Normal file
24
gtk4-no-emoji-context-menu.patch
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
diff -up gtk-4.16.7/gtk/gtktext.c.no-emoji-context-menu gtk-4.16.7/gtk/gtktext.c
|
||||||
|
--- gtk-4.16.7/gtk/gtktext.c.no-emoji-context-menu 2025-03-10 14:20:33.230216455 -0400
|
||||||
|
+++ gtk-4.16.7/gtk/gtktext.c 2025-03-10 14:20:46.104333590 -0400
|
||||||
|
@@ -6304,7 +6304,7 @@ gtk_text_update_emoji_action (GtkText *s
|
||||||
|
|
||||||
|
gtk_widget_action_set_enabled (GTK_WIDGET (self), "misc.insert-emoji",
|
||||||
|
priv->editable &&
|
||||||
|
- (gtk_text_get_input_hints (self) & GTK_INPUT_HINT_NO_EMOJI) == 0);
|
||||||
|
+ (gtk_text_get_input_hints (self) & GTK_INPUT_HINT_EMOJI) != 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
static GMenuModel *
|
||||||
|
diff -up gtk-4.16.7/gtk/gtktextview.c.no-emoji-context-menu gtk-4.16.7/gtk/gtktextview.c
|
||||||
|
--- gtk-4.16.7/gtk/gtktextview.c.no-emoji-context-menu 2025-03-10 14:19:58.237898072 -0400
|
||||||
|
+++ gtk-4.16.7/gtk/gtktextview.c 2025-03-10 14:20:19.298344903 -0400
|
||||||
|
@@ -9205,7 +9205,7 @@ static void
|
||||||
|
gtk_text_view_update_emoji_action (GtkTextView *text_view)
|
||||||
|
{
|
||||||
|
gtk_widget_action_set_enabled (GTK_WIDGET (text_view), "misc.insert-emoji",
|
||||||
|
- (gtk_text_view_get_input_hints (text_view) & GTK_INPUT_HINT_NO_EMOJI) == 0 &&
|
||||||
|
+ (gtk_text_view_get_input_hints (text_view) & GTK_INPUT_HINT_EMOJI) != 0 &&
|
||||||
|
text_view->priv->editable);
|
||||||
|
}
|
||||||
|
|
@ -34,6 +34,7 @@ Source0: https://download.gnome.org/sources/gtk/4.15/gtk-%{version}.tar.x
|
|||||||
|
|
||||||
# Using objcopy for resources interferes with hardening
|
# Using objcopy for resources interferes with hardening
|
||||||
Patch0: gtk4-no-objcopy.patch
|
Patch0: gtk4-no-objcopy.patch
|
||||||
|
Patch1: gtk4-no-emoji-context-menu.patch
|
||||||
|
|
||||||
BuildRequires: cups-devel
|
BuildRequires: cups-devel
|
||||||
BuildRequires: desktop-file-utils
|
BuildRequires: desktop-file-utils
|
||||||
|
Loading…
Reference in New Issue
Block a user