Blob Blame History Raw
From 7dbfdfa03d173d2e969880db4271d624992c2d75 Mon Sep 17 00:00:00 2001
From: fujiwarat <takao.fujiwara1@gmail.com>
Date: Fri, 17 Mar 2023 22:29:56 +0900
Subject: [PATCH] ui/gtk3: Add workaround Emojier can be launched

gnome-shell 44 prevents ibus from launching Emojier GUI.
This workaround can launch the Emojier but still cannot output
the selected emoji character to the focused application.

So another workaround is needed with this patch.
I.e. Type Ctrl-Shift-c keys to copy the seleted emoji instead of
Enter key.

BUG=https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6518
---
 ui/gtk3/emojier.vala | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/ui/gtk3/emojier.vala b/ui/gtk3/emojier.vala
index 69fb8abe..c9cf4469 100644
--- a/ui/gtk3/emojier.vala
+++ b/ui/gtk3/emojier.vala
@@ -2,7 +2,7 @@
  *
  * ibus - The Input Bus
  *
- * Copyright (c) 2017-2021 Takao Fujiwara <takao.fujiwara1@gmail.com>
+ * Copyright (c) 2017-2023 Takao Fujiwara <takao.fujiwara1@gmail.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -1799,12 +1799,12 @@ public class IBusEmojier : Gtk.ApplicationWindow {
 
         m_rebuilding_gui = true;
         m_rebuilding_gui_timeout_id =
-                GLib.Timeout.add_seconds(10, () => {
+                GLib.Timeout.add_seconds(5, () => {
                     if (!m_rebuilding_gui) {
                         m_rebuilding_gui_timeout_id = 0;
                         return false;
                     }
-                    warning("Rebuilding GUI is time out.");
+                    debug("Rebuilding GUI is time out.");
                     m_rebuilding_gui = false;
                     m_rebuilding_gui_timeout_id = 0;
                     return false;
@@ -2459,7 +2459,6 @@ public class IBusEmojier : Gtk.ApplicationWindow {
 
 
     public override bool focus_in_event(Gdk.EventFocus event) {
-        m_rebuilding_gui = false;
         return base.focus_in_event(event);
     }
 
-- 
2.39.2