[gtk/better-naming: 7/10] Rename internal object for the Quartz input method context



commit df73bf38c289e7a00c99352d250309a9c125327b
Author: Emmanuele Bassi <ebassi gnome org>
Date:   Thu Jun 18 17:33:30 2020 +0100

    Rename internal object for the Quartz input method context
    
    Like GtkIMMultiContext, the Quartz input method object uses a delegate
    object internally. Let's not use loaded terms like "slave".

 gtk/gtkimcontextquartz.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/gtk/gtkimcontextquartz.c b/gtk/gtkimcontextquartz.c
index d98ce88ead..c56c998ea7 100644
--- a/gtk/gtkimcontextquartz.c
+++ b/gtk/gtkimcontextquartz.c
@@ -36,7 +36,7 @@
 typedef struct _GtkIMContextQuartz
 {
   GtkIMContext parent;
-  GtkIMContext *slave;
+  GtkIMContext *helper;
   GdkSurface *client_surface;
   gchar *preedit_str;
   unsigned int cursor_index;
@@ -188,7 +188,7 @@ quartz_filter_keypress (GtkIMContext *context,
         /* update text input changes by mouse events */
         return output_result (context, surface);
       else
-        return gtk_im_context_filter_keypress (qc->slave, event);
+        return gtk_im_context_filter_keypress (qc->helper, event);
     }
 
   if (event->type == GDK_KEY_RELEASE)
@@ -341,8 +341,8 @@ imquartz_finalize (GObject *obj)
   g_free (qc->cursor_rect);
   qc->cursor_rect = NULL;
 
-  g_signal_handlers_disconnect_by_func (qc->slave, (gpointer)commit_cb, qc);
-  g_object_unref (qc->slave);
+  g_signal_handlers_disconnect_by_func (qc->helper, (gpointer)commit_cb, qc);
+  g_object_unref (qc->helper);
 
   gtk_im_context_quartz_parent_class->finalize (obj);
 }
@@ -378,6 +378,6 @@ gtk_im_context_quartz_init (GtkIMContextQuartz *qc)
   qc->cursor_rect = g_malloc (sizeof (GdkRectangle));
   qc->focused = FALSE;
 
-  qc->slave = g_object_new (GTK_TYPE_IM_CONTEXT_SIMPLE, NULL);
-  g_signal_connect (G_OBJECT (qc->slave), "commit", G_CALLBACK (commit_cb), qc);
+  qc->helper = g_object_new (GTK_TYPE_IM_CONTEXT_SIMPLE, NULL);
+  g_signal_connect (G_OBJECT (qc->helper), "commit", G_CALLBACK (commit_cb), qc);
 }


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