[caribou/imcontext: 2/9] it compiles
- From: Eitan Isaacson <eitani src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [caribou/imcontext: 2/9] it compiles
- Date: Sat, 4 Jun 2011 21:09:35 +0000 (UTC)
commit 7916d7c46af2ee681c2faa9c6759320cdefe66a2
Author: Eitan Isaacson <eitan monotonous org>
Date: Thu Jun 2 18:22:53 2011 -0700
it compiles
configure.ac | 6 +++++-
im/gtk3/Makefile.am | 8 +++-----
im/gtk3/caribou-imcontext.c | 10 ++++++----
im/gtk3/caribou-imcontext.h | 2 +-
4 files changed, 15 insertions(+), 11 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index ec26491..8babf66 100644
--- a/configure.ac
+++ b/configure.ac
@@ -70,11 +70,16 @@ if test x"$enable_im_modules" = x"yes"; then
PKG_CHECK_MODULES(GTK2, [
gtk+-2.0
])
+ PKG_CHECK_MODULES(GTK3, [
+ gtk+-3.0
+ ])
gtk2_binary_version=`$PKG_CONFIG --variable=gtk_binary_version gtk+-2.0`
GTK2_IM_MODULEDIR="$libdir"/gtk-2.0/$gtk2_binary_version/immodules
+ AC_SUBST(GTK2_IM_MODULEDIR)
gtk3_binary_version=`$PKG_CONFIG --variable=gtk_binary_version gtk+-3.0`
GTK3_IM_MODULEDIR="$libdir"/gtk-3.0/$gtk3_binary_version/immodules
+ AC_SUBST(GTK3_IM_MODULEDIR)
fi
dnl == GSettings ==
@@ -109,6 +114,5 @@ data/layouts/touch/Makefile
data/layouts/scan/Makefile
libcaribou/Makefile
im/Makefile
-im/gtk2/Makefile
im/gtk3/Makefile
])
diff --git a/im/gtk3/Makefile.am b/im/gtk3/Makefile.am
index 377e50c..9e69b24 100644
--- a/im/gtk3/Makefile.am
+++ b/im/gtk3/Makefile.am
@@ -1,4 +1,4 @@
-immoduledir = @GTK2_IM_MODULEDIR@
+immoduledir = @GTK3_IM_MODULEDIR@
immodule_LTLIBRARIES = im-caribou.la
im_caribou_la_SOURCES = \
@@ -8,14 +8,12 @@ im_caribou_la_SOURCES = \
$(NULL)
im_caribou_la_CFLAGS = \
- @GTK2_CFLAGS@ \
- @DBUS_CFLAGS@ \
+ @GTK3_CFLAGS@ \
-DG_LOG_DOMAIN=\"CARIBOU\" \
$(NULL)
im_caribou_la_LIBADD = \
- @GTK2_LIBS@ \
- @DBUS_LIBS@ \
+ @GTK3_LIBS@ \
$(NULL)
im_caribou_la_LDFLAGS = \
diff --git a/im/gtk3/caribou-imcontext.c b/im/gtk3/caribou-imcontext.c
index 68d1607..d2ab897 100644
--- a/im/gtk3/caribou-imcontext.c
+++ b/im/gtk3/caribou-imcontext.c
@@ -1,4 +1,4 @@
-#include <X11/keysym.h>
+#include "caribou-imcontext.h"
static GType _caribou_imcontext_type = 0;
static GtkIMContextClass *parent_class = NULL;
@@ -6,6 +6,9 @@ static GtkIMContextClass *parent_class = NULL;
static CaribouIMContext *focused_imcontext = NULL;
static GtkWidget *focused_widget = NULL;
+static void caribou_imcontext_class_init (CaribouIMContextClass *klass);
+static void caribou_imcontext_init (CaribouIMContext *self);
+
GType caribou_imcontext_get_type ()
{
if (_caribou_imcontext_type == 0)
@@ -50,11 +53,10 @@ caribou_imcontext_register_type (GTypeModule *type_module)
}
}
-GtkIMContext *
+CaribouIMContext *
caribou_imcontext_new (void)
{
- CaribouIMContext *ic = CARIBOU_IMCONTEXT(g_object_new(CARIBOU_TYPE_IMCONTEXT, NULL));
- return GTK_IM_CONTEXT(ic);
+ return CARIBOU_IMCONTEXT(g_object_new(CARIBOU_TYPE_IMCONTEXT, NULL));
}
diff --git a/im/gtk3/caribou-imcontext.h b/im/gtk3/caribou-imcontext.h
index 717a7dc..e22b69a 100644
--- a/im/gtk3/caribou-imcontext.h
+++ b/im/gtk3/caribou-imcontext.h
@@ -27,7 +27,7 @@ struct _CaribouIMContextClass {
GType caribou_imcontext_get_type (void);
void caribou_imcontext_register_type (GTypeModule *type_module);
-GtkIMContext *caribou_imcontext_new (void);
+CaribouIMContext *caribou_imcontext_new (void);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]