Make GtkIMContext derive from GObject, not GtkObject. (#62621)
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com> * gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c} modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c, imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from GObject, not GtkObject. (#62621)
This commit is contained in:
parent
fcc8790748
commit
effa390541
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
Fri Oct 19 15:08:30 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* gtk/{gtkimcontext.c,gtkimcontextsimple.c,gtkimmulticontext.c}
|
||||||
|
modules/input/{gtkimcontextxim.c,imcyrillic-translit.c,iminuktitut.c,
|
||||||
|
imipa.c,imthai-broken.c,imviqr.c}: Make GtkIMContext derive from
|
||||||
|
GObject, not GtkObject. (#62621)
|
||||||
|
|
||||||
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
Fri Oct 19 12:49:12 2001 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* tests/testsocket.c: Remove now useless include of unistd.h,
|
* tests/testsocket.c: Remove now useless include of unistd.h,
|
||||||
|
@ -47,19 +47,22 @@ gtk_im_context_get_type (void)
|
|||||||
|
|
||||||
if (!im_context_type)
|
if (!im_context_type)
|
||||||
{
|
{
|
||||||
static const GtkTypeInfo im_context_info =
|
static const GTypeInfo im_context_info =
|
||||||
{
|
{
|
||||||
"GtkIMContext",
|
|
||||||
sizeof (GtkIMContext),
|
|
||||||
sizeof (GtkIMContextClass),
|
sizeof (GtkIMContextClass),
|
||||||
(GtkClassInitFunc) gtk_im_context_class_init,
|
(GBaseInitFunc) NULL,
|
||||||
(GtkObjectInitFunc) gtk_im_context_init,
|
(GBaseFinalizeFunc) NULL,
|
||||||
/* reserved_1 */ NULL,
|
(GClassInitFunc) gtk_im_context_class_init,
|
||||||
/* reserved_2 */ NULL,
|
NULL, /* class_finalize */
|
||||||
(GtkClassInitFunc) NULL,
|
NULL, /* class_data */
|
||||||
|
sizeof (GtkIMContext),
|
||||||
|
0, /* n_preallocs */
|
||||||
|
(GInstanceInitFunc) gtk_im_context_init,
|
||||||
};
|
};
|
||||||
|
|
||||||
im_context_type = gtk_type_unique (GTK_TYPE_OBJECT, &im_context_info);
|
im_context_type = g_type_register_static (G_TYPE_OBJECT,
|
||||||
|
"GtkIMContext",
|
||||||
|
&im_context_info, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
return im_context_type;
|
return im_context_type;
|
||||||
|
@ -761,19 +761,22 @@ gtk_im_context_simple_get_type (void)
|
|||||||
|
|
||||||
if (!im_context_simple_type)
|
if (!im_context_simple_type)
|
||||||
{
|
{
|
||||||
static const GtkTypeInfo im_context_simple_info =
|
static const GTypeInfo im_context_simple_info =
|
||||||
{
|
{
|
||||||
"GtkIMContextSimple",
|
|
||||||
sizeof (GtkIMContextSimple),
|
|
||||||
sizeof (GtkIMContextSimpleClass),
|
sizeof (GtkIMContextSimpleClass),
|
||||||
(GtkClassInitFunc) gtk_im_context_simple_class_init,
|
(GBaseInitFunc) NULL,
|
||||||
(GtkObjectInitFunc) gtk_im_context_simple_init,
|
(GBaseFinalizeFunc) NULL,
|
||||||
/* reserved_1 */ NULL,
|
(GClassInitFunc) gtk_im_context_simple_class_init,
|
||||||
/* reserved_2 */ NULL,
|
NULL, /* class_finalize */
|
||||||
(GtkClassInitFunc) NULL,
|
NULL, /* class_data */
|
||||||
|
sizeof (GtkIMContextSimple),
|
||||||
|
0, /* n_preallocs */
|
||||||
|
(GInstanceInitFunc) gtk_im_context_simple_init,
|
||||||
};
|
};
|
||||||
|
|
||||||
im_context_simple_type = gtk_type_unique (GTK_TYPE_IM_CONTEXT, &im_context_simple_info);
|
im_context_simple_type = g_type_register_static (GTK_TYPE_IM_CONTEXT,
|
||||||
|
"GtkIMContextSimple",
|
||||||
|
&im_context_simple_info, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
return im_context_simple_type;
|
return im_context_simple_type;
|
||||||
@ -817,7 +820,7 @@ gtk_im_context_simple_finalize (GObject *obj)
|
|||||||
GtkIMContext *
|
GtkIMContext *
|
||||||
gtk_im_context_simple_new (void)
|
gtk_im_context_simple_new (void)
|
||||||
{
|
{
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (GTK_TYPE_IM_CONTEXT_SIMPLE));
|
return GTK_IM_CONTEXT (g_object_new (GTK_TYPE_IM_CONTEXT_SIMPLE, NULL));
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@ -840,11 +843,10 @@ gtk_im_context_simple_commit_char (GtkIMContext *context,
|
|||||||
{
|
{
|
||||||
context_simple->tentative_match = 0;
|
context_simple->tentative_match = 0;
|
||||||
context_simple->tentative_match_len = 0;
|
context_simple->tentative_match_len = 0;
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context_simple),
|
g_signal_emit_by_name (context_simple, "preedit_changed");
|
||||||
"preedit_changed");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "commit", &buf);
|
g_signal_emit_by_name (context, "commit", &buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
@ -912,8 +914,7 @@ check_table (GtkIMContextSimple *context_simple,
|
|||||||
context_simple->tentative_match = value;
|
context_simple->tentative_match = value;
|
||||||
context_simple->tentative_match_len = n_compose;
|
context_simple->tentative_match_len = n_compose;
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context_simple),
|
g_signal_emit_by_name (context_simple, "preedit_changed");
|
||||||
"preedit_changed");
|
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
@ -992,8 +993,7 @@ check_hex (GtkIMContextSimple *context_simple,
|
|||||||
context_simple->tentative_match = n;
|
context_simple->tentative_match = n;
|
||||||
context_simple->tentative_match_len = n_compose;
|
context_simple->tentative_match_len = n_compose;
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context_simple),
|
g_signal_emit_by_name (context_simple, "preedit-changed");
|
||||||
"preedit-changed");
|
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@ -67,19 +67,22 @@ gtk_im_multicontext_get_type (void)
|
|||||||
|
|
||||||
if (!im_multicontext_type)
|
if (!im_multicontext_type)
|
||||||
{
|
{
|
||||||
static const GtkTypeInfo im_multicontext_info =
|
static const GTypeInfo im_multicontext_info =
|
||||||
{
|
{
|
||||||
"GtkIMMulticontext",
|
|
||||||
sizeof (GtkIMMulticontext),
|
|
||||||
sizeof (GtkIMMulticontextClass),
|
sizeof (GtkIMMulticontextClass),
|
||||||
(GtkClassInitFunc) gtk_im_multicontext_class_init,
|
(GBaseInitFunc) NULL,
|
||||||
(GtkObjectInitFunc) gtk_im_multicontext_init,
|
(GBaseFinalizeFunc) NULL,
|
||||||
/* reserved_1 */ NULL,
|
(GClassInitFunc) gtk_im_multicontext_class_init,
|
||||||
/* reserved_2 */ NULL,
|
NULL, /* class_finalize */
|
||||||
(GtkClassInitFunc) NULL,
|
NULL, /* class_data */
|
||||||
|
sizeof (GtkIMMulticontext),
|
||||||
|
0, /* n_preallocs */
|
||||||
|
(GInstanceInitFunc) gtk_im_multicontext_init,
|
||||||
};
|
};
|
||||||
|
|
||||||
im_multicontext_type = gtk_type_unique (GTK_TYPE_IM_CONTEXT, &im_multicontext_info);
|
im_multicontext_type = g_type_register_static (GTK_TYPE_IM_CONTEXT,
|
||||||
|
"GtkIMMulticontext",
|
||||||
|
&im_multicontext_info, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
return im_multicontext_type;
|
return im_multicontext_type;
|
||||||
@ -113,7 +116,7 @@ gtk_im_multicontext_init (GtkIMMulticontext *multicontext)
|
|||||||
GtkIMContext *
|
GtkIMContext *
|
||||||
gtk_im_multicontext_new (void)
|
gtk_im_multicontext_new (void)
|
||||||
{
|
{
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (GTK_TYPE_IM_MULTICONTEXT));
|
return GTK_IM_CONTEXT (g_object_new (GTK_TYPE_IM_MULTICONTEXT, NULL));
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@ -130,28 +133,39 @@ gtk_im_multicontext_set_slave (GtkIMMulticontext *multicontext,
|
|||||||
{
|
{
|
||||||
if (multicontext->slave)
|
if (multicontext->slave)
|
||||||
{
|
{
|
||||||
gtk_signal_disconnect_by_data (GTK_OBJECT (multicontext->slave), multicontext);
|
g_signal_handlers_disconnect_by_func (multicontext->slave,
|
||||||
gtk_object_unref (GTK_OBJECT (multicontext->slave));
|
gtk_im_multicontext_preedit_start_cb,
|
||||||
|
multicontext);
|
||||||
|
g_signal_handlers_disconnect_by_func (multicontext->slave,
|
||||||
|
gtk_im_multicontext_preedit_end_cb,
|
||||||
|
multicontext);
|
||||||
|
g_signal_handlers_disconnect_by_func (multicontext->slave,
|
||||||
|
gtk_im_multicontext_preedit_changed_cb,
|
||||||
|
multicontext);
|
||||||
|
g_signal_handlers_disconnect_by_func (multicontext->slave,
|
||||||
|
gtk_im_multicontext_commit_cb,
|
||||||
|
multicontext);
|
||||||
|
|
||||||
|
g_object_unref (multicontext->slave);
|
||||||
}
|
}
|
||||||
|
|
||||||
multicontext->slave = slave;
|
multicontext->slave = slave;
|
||||||
|
|
||||||
if (multicontext->slave)
|
if (multicontext->slave)
|
||||||
{
|
{
|
||||||
gtk_object_ref (GTK_OBJECT (multicontext->slave));
|
g_object_ref (multicontext->slave);
|
||||||
gtk_object_sink (GTK_OBJECT (multicontext->slave));
|
|
||||||
|
|
||||||
gtk_signal_connect (GTK_OBJECT (multicontext->slave), "preedit_start",
|
g_signal_connect (multicontext->slave, "preedit_start",
|
||||||
GTK_SIGNAL_FUNC (gtk_im_multicontext_preedit_start_cb),
|
G_CALLBACK (gtk_im_multicontext_preedit_start_cb),
|
||||||
multicontext);
|
multicontext);
|
||||||
gtk_signal_connect (GTK_OBJECT (multicontext->slave), "preedit_end",
|
g_signal_connect (multicontext->slave, "preedit_end",
|
||||||
GTK_SIGNAL_FUNC (gtk_im_multicontext_preedit_end_cb),
|
G_CALLBACK (gtk_im_multicontext_preedit_end_cb),
|
||||||
multicontext);
|
multicontext);
|
||||||
gtk_signal_connect (GTK_OBJECT (multicontext->slave), "preedit_changed",
|
g_signal_connect (multicontext->slave, "preedit_changed",
|
||||||
GTK_SIGNAL_FUNC (gtk_im_multicontext_preedit_changed_cb),
|
G_CALLBACK (gtk_im_multicontext_preedit_changed_cb),
|
||||||
multicontext);
|
multicontext);
|
||||||
gtk_signal_connect (GTK_OBJECT (multicontext->slave), "commit",
|
g_signal_connect (multicontext->slave, "commit",
|
||||||
GTK_SIGNAL_FUNC (gtk_im_multicontext_commit_cb),
|
G_CALLBACK (gtk_im_multicontext_commit_cb),
|
||||||
multicontext);
|
multicontext);
|
||||||
|
|
||||||
if (multicontext->client_window)
|
if (multicontext->client_window)
|
||||||
@ -284,21 +298,21 @@ void
|
|||||||
gtk_im_multicontext_preedit_start_cb (GtkIMContext *slave,
|
gtk_im_multicontext_preedit_start_cb (GtkIMContext *slave,
|
||||||
GtkIMMulticontext *multicontext)
|
GtkIMMulticontext *multicontext)
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (multicontext), "preedit_start");
|
g_signal_emit_by_name (multicontext, "preedit_start");
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
gtk_im_multicontext_preedit_end_cb (GtkIMContext *slave,
|
gtk_im_multicontext_preedit_end_cb (GtkIMContext *slave,
|
||||||
GtkIMMulticontext *multicontext)
|
GtkIMMulticontext *multicontext)
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (multicontext), "preedit_end");
|
g_signal_emit_by_name (multicontext, "preedit_end");
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
gtk_im_multicontext_preedit_changed_cb (GtkIMContext *slave,
|
gtk_im_multicontext_preedit_changed_cb (GtkIMContext *slave,
|
||||||
GtkIMMulticontext *multicontext)
|
GtkIMMulticontext *multicontext)
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (multicontext), "preedit_changed");
|
g_signal_emit_by_name (multicontext, "preedit_changed");
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -306,7 +320,7 @@ gtk_im_multicontext_commit_cb (GtkIMContext *slave,
|
|||||||
const gchar *str,
|
const gchar *str,
|
||||||
GtkIMMulticontext *multicontext)
|
GtkIMMulticontext *multicontext)
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (multicontext), "commit", str);;
|
g_signal_emit_by_name (multicontext, "commit", str);;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@ -361,7 +375,7 @@ gtk_im_multicontext_append_menuitems (GtkIMMulticontext *context,
|
|||||||
gtk_object_set_data (GTK_OBJECT (menuitem), "gtk-context-id",
|
gtk_object_set_data (GTK_OBJECT (menuitem), "gtk-context-id",
|
||||||
(char *)contexts[i]->context_id);
|
(char *)contexts[i]->context_id);
|
||||||
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
||||||
GTK_SIGNAL_FUNC (activate_cb), context);
|
G_CALLBACK (activate_cb), context);
|
||||||
|
|
||||||
gtk_widget_show (menuitem);
|
gtk_widget_show (menuitem);
|
||||||
gtk_menu_shell_append (menushell, menuitem);
|
gtk_menu_shell_append (menushell, menuitem);
|
||||||
|
@ -264,7 +264,7 @@ gtk_im_context_xim_new (void)
|
|||||||
if (!info)
|
if (!info)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
result = GTK_IM_CONTEXT_XIM (gtk_type_new (GTK_TYPE_IM_CONTEXT_XIM));
|
result = GTK_IM_CONTEXT_XIM (g_object_new (GTK_TYPE_IM_CONTEXT_XIM, NULL));
|
||||||
|
|
||||||
result->im_info = info;
|
result->im_info = info;
|
||||||
|
|
||||||
@ -361,7 +361,7 @@ gtk_im_context_xim_filter_keypress (GtkIMContext *context,
|
|||||||
* control characters into strings
|
* control characters into strings
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "commit", result_utf8);
|
g_signal_emit_by_name (context, "commit", result_utf8);
|
||||||
result = TRUE;
|
result = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -468,7 +468,7 @@ gtk_im_context_xim_reset (GtkIMContext *context)
|
|||||||
char *result_utf8 = mb_to_utf8 (context_xim, result);
|
char *result_utf8 = mb_to_utf8 (context_xim, result);
|
||||||
if (result_utf8)
|
if (result_utf8)
|
||||||
{
|
{
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "commit", result_utf8);
|
g_signal_emit_by_name (context, "commit", result_utf8);
|
||||||
g_free (result_utf8);
|
g_free (result_utf8);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -476,7 +476,7 @@ gtk_im_context_xim_reset (GtkIMContext *context)
|
|||||||
if (context_xim->preedit_length)
|
if (context_xim->preedit_length)
|
||||||
{
|
{
|
||||||
context_xim->preedit_length = 0;
|
context_xim->preedit_length = 0;
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "preedit_changed");
|
g_signal_emit_by_name (context, "preedit_changed");
|
||||||
}
|
}
|
||||||
|
|
||||||
XFree (result);
|
XFree (result);
|
||||||
@ -576,7 +576,7 @@ preedit_start_callback (XIC xic,
|
|||||||
{
|
{
|
||||||
GtkIMContext *context = GTK_IM_CONTEXT (client_data);
|
GtkIMContext *context = GTK_IM_CONTEXT (client_data);
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "preedit_start");
|
g_signal_emit_by_name (context, "preedit_start");
|
||||||
g_print ("Starting preedit!\n");
|
g_print ("Starting preedit!\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -587,7 +587,7 @@ preedit_done_callback (XIC xic,
|
|||||||
{
|
{
|
||||||
GtkIMContext *context = GTK_IM_CONTEXT (client_data);
|
GtkIMContext *context = GTK_IM_CONTEXT (client_data);
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "preedit_end");
|
g_signal_emit_by_name (context, "preedit_end");
|
||||||
g_print ("Ending preedit!\n");
|
g_print ("Ending preedit!\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -713,7 +713,7 @@ preedit_draw_callback (XIC xic,
|
|||||||
if (new_text)
|
if (new_text)
|
||||||
g_free (new_text);
|
g_free (new_text);
|
||||||
|
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "preedit_changed");
|
g_signal_emit_by_name (context, "preedit_changed");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -727,7 +727,7 @@ preedit_caret_callback (XIC xic,
|
|||||||
if (call_data->direction == XIMAbsolutePosition)
|
if (call_data->direction == XIMAbsolutePosition)
|
||||||
{
|
{
|
||||||
context->preedit_cursor = call_data->position;
|
context->preedit_cursor = call_data->position;
|
||||||
gtk_signal_emit_by_name (GTK_OBJECT (context), "preedit_changed");
|
g_signal_emit_by_name (context, "preedit_changed");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -246,7 +246,7 @@ GtkIMContext *
|
|||||||
im_module_create (const gchar *context_id)
|
im_module_create (const gchar *context_id)
|
||||||
{
|
{
|
||||||
if (strcmp (context_id, "cyrillic_translit") == 0)
|
if (strcmp (context_id, "cyrillic_translit") == 0)
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (type_cyrillic_translit));
|
return GTK_IM_CONTEXT (g_object_new (type_cyrillic_translit, NULL));
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -156,7 +156,7 @@ GtkIMContext *
|
|||||||
im_module_create (const gchar *context_id)
|
im_module_create (const gchar *context_id)
|
||||||
{
|
{
|
||||||
if (strcmp (context_id, "inuktitut") == 0)
|
if (strcmp (context_id, "inuktitut") == 0)
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (type_inuktitut_translit));
|
return GTK_IM_CONTEXT (g_object_new (type_inuktitut_translit, NULL));
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -174,7 +174,7 @@ GtkIMContext *
|
|||||||
im_module_create (const gchar *context_id)
|
im_module_create (const gchar *context_id)
|
||||||
{
|
{
|
||||||
if (strcmp (context_id, "ipa") == 0)
|
if (strcmp (context_id, "ipa") == 0)
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (type_ipa));
|
return GTK_IM_CONTEXT (g_object_new (type_ipa, NULL));
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -207,7 +207,7 @@ GtkIMContext *
|
|||||||
im_module_create (const gchar *context_id)
|
im_module_create (const gchar *context_id)
|
||||||
{
|
{
|
||||||
if (strcmp (context_id, "thai_broken") == 0)
|
if (strcmp (context_id, "thai_broken") == 0)
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (type_thai_broken));
|
return GTK_IM_CONTEXT (g_object_new (type_thai_broken, NULL));
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -273,7 +273,7 @@ GtkIMContext *
|
|||||||
im_module_create (const gchar *context_id)
|
im_module_create (const gchar *context_id)
|
||||||
{
|
{
|
||||||
if (strcmp (context_id, "viqr") == 0)
|
if (strcmp (context_id, "viqr") == 0)
|
||||||
return GTK_IM_CONTEXT (gtk_type_new (type_viqr_translit));
|
return GTK_IM_CONTEXT (g_object_new (type_viqr_translit, NULL));
|
||||||
else
|
else
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user