Revision: 6966
Author: nogu.dev
Date: Fri Feb 18 15:07:51 2011
Log: * gtk3/toolbar/Makefile.am
- Remove uim-toolbar-applet-gnome3 because this applet depends on GTK+2.
* helper/Makefile.am
- Add uim-toolbar-applet-gnome3.
* gtk3/toolbar/UimApplet.panel-applet.in.in
- Move to helper/UimApplet.panel-applet.in.in.
* gtk3/toolbar/org.gnome.panel.applet.UimAppletFactory.service.in
- Move to helper/org.gnome.panel.applet.UimAppletFactory.service.in.
* gtk3/toolbar/toolbar-applet-gnome3.c
- Move to helper/toolbar-applet-gnome3.c
http://code.google.com/p/uim/source/detail?r=6966
Added:
/trunk/helper/UimApplet.panel-applet.in.in
/trunk/helper/org.gnome.panel.applet.UimAppletFactory.service.in
/trunk/helper/toolbar-applet-gnome3.c
Deleted:
/trunk/gtk3/toolbar/UimApplet.panel-applet.in.in
/trunk/gtk3/toolbar/org.gnome.panel.applet.UimAppletFactory.service.in
/trunk/gtk3/toolbar/toolbar-applet-gnome3.c
Modified:
/trunk/gtk3/toolbar/Makefile.am
/trunk/helper/Makefile.am
=======================================
--- /dev/null
+++ /trunk/helper/UimApplet.panel-applet.in.in Fri Feb 18 15:07:51 2011
@@ -0,0 +1,10 @@
+[Applet Factory]
+Id=UimAppletFactory
+Location=@LIBEXECDIR@/uim-toolbar-applet-gnome3
+_Name=uim Applet Factory
+_Description=uim applet factory
+
+[UimApplet]
+_Name=Input Method Indicator
+_Description=Indicates and controls the state of input method (for uim)
+Icon=@UIM_PIXMAPSDIR@/uim-icon.png
=======================================
--- /dev/null
+++ /trunk/helper/org.gnome.panel.applet.UimAppletFactory.service.in Fri
Feb 18 15:07:51 2011
@@ -0,0 +1,3 @@
+[D-BUS Service]
+Name=org.gnome.panel.applet.UimAppletFactory
+Exec=@LIBEXECDIR@/uim-toolbar-applet-gnome3
=======================================
--- /dev/null
+++ /trunk/helper/toolbar-applet-gnome3.c Fri Feb 18 15:07:51 2011
@@ -0,0 +1,220 @@
+/*
+
+ Copyright (c) 2003-2011 uim Project http://code.google.com/p/uim/
+
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions
+ are met:
+
+ 1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ 3. Neither the name of authors nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS
IS'' AND
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS
BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT
+ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ SUCH DAMAGE.
+
+*/
+
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#include <stdlib.h>
+#include <string.h>
+#include <locale.h>
+#include <panel-applet.h>
+#include <uim/uim.h>
+#include <uim/gettext.h>
+
+PanelApplet *uimapplet;
+
+static void exec_switcher(GtkAction *action, gpointer data);
+static void exec_pref(GtkAction *action, gpointer data);
+static void exec_dic(GtkAction *action, gpointer data);
+static void exec_pad(GtkAction *action, gpointer data);
+static void exec_hand(GtkAction *action, gpointer data);
+static void exec_help(GtkAction *action, gpointer data);
+static void display_about_dialog(GtkAction *action, gpointer data);
+static void register_icons(void);
+
+extern GtkWidget *uim_toolbar_applet_new(void);
+extern void uim_launch_helper_application(const char *command);
+
+
+static const GtkActionEntry uim_menu_actions[] = {
+ {"Switcher", "uim-im-switcher",
+ N_("Switch input method"), NULL, NULL, G_CALLBACK(exec_switcher)},
+ {"Pref", GTK_STOCK_PREFERENCES,
+ N_("Preference"), NULL, NULL, G_CALLBACK(exec_pref)},
+ {"Dic", "uim-dict",
+ N_("Japanese dictionary editor"), NULL, NULL, G_CALLBACK(exec_dic)},
+ {"Pad", GTK_STOCK_BOLD,
+ N_("Input pad"), NULL, NULL, G_CALLBACK(exec_pad)},
+ {"Hand", GTK_STOCK_EDIT,
+ N_("Handwriting input pad"), NULL, NULL, G_CALLBACK(exec_hand)},
+ {"Help", GTK_STOCK_HELP,
+ N_("Help"), NULL, NULL, G_CALLBACK(exec_help)},
+ {"About", GTK_STOCK_ABOUT,
+ N_("About"), NULL, NULL, G_CALLBACK(display_about_dialog)}
+};
+
+static const char uim_menu_xml[] =
+ "<menuitem action=\"Switcher\"/>"
+ "<menuitem action=\"Pref\"/>"
+ "<menuitem action=\"Dic\"/>"
+ "<menuitem action=\"Pad\"/>"
+ "<menuitem action=\"Hand\"/>"
+ "<menuitem action=\"Help\"/>"
+ "<menuitem action=\"About\"/>";
+
+static void
+exec_switcher(GtkAction *action, gpointer data)
+{
+ uim_launch_helper_application("uim-im-switcher-gtk3");
+}
+
+static void
+exec_pref(GtkAction *action, gpointer data)
+{
+ uim_launch_helper_application("uim-pref-gtk3");
+}
+
+static void
+exec_dic(GtkAction *action, gpointer data)
+{
+ uim_launch_helper_application("uim-dict-gtk3");
+}
+
+static void
+exec_pad(GtkAction *action, gpointer data)
+{
+ uim_launch_helper_application("uim-input-pad-ja-gtk3");
+}
+
+static void
+exec_hand(GtkAction *action, gpointer data)
+{
+ uim_launch_helper_application("uim-tomoe-gtk");
+}
+
+static void
+exec_help(GtkAction *uic, gpointer data)
+{
+ uim_launch_helper_application("uim-help");
+}
+
+/* Just the about window... If it's already open, just focus it */
+static void
+display_about_dialog(GtkAction *action, gpointer data)
+{
+ GdkPixbuf *icon = NULL;
+ const gchar *authors[] = {"uim Project", NULL};
+ /* Feel free to put your names here translators */
+ gchar *translators = _("TRANSLATORS");
+ icon = gdk_pixbuf_new_from_file(UIM_PIXMAPSDIR "/uim-icon.png", NULL);
+
+ gtk_show_about_dialog(NULL,
+ "program-name", _("uim Applet"),
+ "version", VERSION,
+ "copyright", "Copyright \xc2\xa9 2003-2011 uim
Project.",
+ "comments", _("Applet for indicating uim's status"),
+ "authors", authors,
+ "translator-credits",
+ strcmp("TRANSLATORS", translators) ? translators
+ : NULL,
+ "icon", icon,
+ "logo", icon, NULL);
+
+ if (icon) {
+ g_object_unref(icon);
+ }
+}
+
+static void
+register_icons(void)
+{
+ struct {
+ gchar *filename;
+ gchar *stock_id;
+ } stock_icons[] = {
+ {UIM_PIXMAPSDIR"/im_switcher.png", "uim-im-switcher"},
+ {UIM_PIXMAPSDIR"/uim-dict.png", "uim-dict"}
+ };
+ GtkIconFactory *icon_factory = gtk_icon_factory_new();
+ GtkIconSet *icon_set;
+ GtkIconSource *icon_source;
+ gint n_stock_icons = G_N_ELEMENTS(stock_icons);
+ gint i;
+
+ for (i = 0; i < n_stock_icons; i++) {
+ icon_set = gtk_icon_set_new();
+ icon_source = gtk_icon_source_new();
+ gtk_icon_source_set_filename(icon_source, stock_icons[i].filename);
+ gtk_icon_set_add_source(icon_set, icon_source);
+ gtk_icon_source_free(icon_source);
+ gtk_icon_factory_add(icon_factory, stock_icons[i].stock_id, icon_set);
+ gtk_icon_set_unref(icon_set);
+ }
+
+ gtk_icon_factory_add_default(icon_factory);
+
+ g_object_unref(icon_factory);
+}
+
+static gboolean
+uim_applet_new(PanelApplet *applet, const gchar *iid, gpointer data)
+{
+ GtkWidget *toolbar;
+ GtkActionGroup *action_group;
+
+ uimapplet = applet;
+
+ if (strcmp(iid, "UimApplet") != 0)
+ return FALSE;
+
+ uim_init();
+
+ toolbar = (GtkWidget*)uim_toolbar_applet_new();
+
+ gtk_container_add(GTK_CONTAINER(applet), toolbar);
+
+ gtk_widget_show_all(GTK_WIDGET(applet));
+
+ register_icons();
+
+ action_group = gtk_action_group_new("uim Applet Actions");
+ gtk_action_group_set_translation_domain(action_group, GETTEXT_PACKAGE);
+ gtk_action_group_add_actions(action_group, uim_menu_actions,
+ G_N_ELEMENTS(uim_menu_actions), toolbar);
+ panel_applet_setup_menu(applet, uim_menu_xml, action_group);
+#if LIBPANEL_APPLET_HAVE_SET_BACKGROUND_WIDGET
+ panel_applet_set_background_widget(applet, GTK_WIDGET(applet));
+#endif
+ g_object_unref(action_group);
+
+ return TRUE;
+}
+
+
+
+PANEL_APPLET_OUT_PROCESS_FACTORY("UimAppletFactory",
+ PANEL_TYPE_APPLET,
+ "uim Applet for GNOME",
+ (PanelAppletFactoryCallback)uim_applet_new,
+ NULL)
=======================================
--- /trunk/gtk3/toolbar/UimApplet.panel-applet.in.in Sun Feb 13 03:01:22
2011
+++ /dev/null
@@ -1,10 +0,0 @@
-[Applet Factory]
-Id=UimAppletFactory
-Location=@LIBEXECDIR@/uim-toolbar-applet-gnome3
-_Name=uim Applet Factory
-_Description=uim applet factory
-
-[UimApplet]
-_Name=Input Method Indicator
-_Description=Indicates and controls the state of input method (for uim)
-Icon=@UIM_PIXMAPSDIR@/uim-icon.png
=======================================
--- /trunk/gtk3/toolbar/org.gnome.panel.applet.UimAppletFactory.service.in
Sat Feb 12 19:58:37 2011
+++ /dev/null
@@ -1,3 +0,0 @@
-[D-BUS Service]
-Name=org.gnome.panel.applet.UimAppletFactory
-Exec=@LIBEXECDIR@/uim-toolbar-applet-gnome3
=======================================
--- /trunk/gtk3/toolbar/toolbar-applet-gnome3.c Mon Feb 14 06:26:14 2011
+++ /dev/null
@@ -1,220 +0,0 @@
-/*
-
- Copyright (c) 2003-2011 uim Project http://code.google.com/p/uim/
-
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions
- are met:
-
- 1. Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- 2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- 3. Neither the name of authors nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS
IS'' AND
- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE
- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS
BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT
- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- SUCH DAMAGE.
-
-*/
-
-#ifdef HAVE_CONFIG_H
-# include <config.h>
-#endif
-
-#include <stdlib.h>
-#include <string.h>
-#include <locale.h>
-#include <panel-applet.h>
-#include <uim/uim.h>
-#include <uim/gettext.h>
-
-PanelApplet *uimapplet;
-
-static void exec_switcher(GtkAction *action, gpointer data);
-static void exec_pref(GtkAction *action, gpointer data);
-static void exec_dic(GtkAction *action, gpointer data);
-static void exec_pad(GtkAction *action, gpointer data);
-static void exec_hand(GtkAction *action, gpointer data);
-static void exec_help(GtkAction *action, gpointer data);
-static void display_about_dialog(GtkAction *action, gpointer data);
-static void register_icons(void);
-
-extern GtkWidget *uim_toolbar_applet_new(void);
-extern void uim_launch_helper_application(const char *command);
-
-
-static const GtkActionEntry uim_menu_actions[] = {
- {"Switcher", "uim-im-switcher",
- N_("Switch input method"), NULL, NULL, G_CALLBACK(exec_switcher)},
- {"Pref", GTK_STOCK_PREFERENCES,
- N_("Preference"), NULL, NULL, G_CALLBACK(exec_pref)},
- {"Dic", "uim-dict",
- N_("Japanese dictionary editor"), NULL, NULL, G_CALLBACK(exec_dic)},
- {"Pad", GTK_STOCK_BOLD,
- N_("Input pad"), NULL, NULL, G_CALLBACK(exec_pad)},
- {"Hand", GTK_STOCK_EDIT,
- N_("Handwriting input pad"), NULL, NULL, G_CALLBACK(exec_hand)},
- {"Help", GTK_STOCK_HELP,
- N_("Help"), NULL, NULL, G_CALLBACK(exec_help)},
- {"About", GTK_STOCK_ABOUT,
- N_("About"), NULL, NULL, G_CALLBACK(display_about_dialog)}
-};
-
-static const char uim_menu_xml[] =
- "<menuitem action=\"Switcher\"/>"
- "<menuitem action=\"Pref\"/>"
- "<menuitem action=\"Dic\"/>"
- "<menuitem action=\"Pad\"/>"
- "<menuitem action=\"Hand\"/>"
- "<menuitem action=\"Help\"/>"
- "<menuitem action=\"About\"/>";
-
-static void
-exec_switcher(GtkAction *action, gpointer data)
-{
- uim_launch_helper_application("uim-im-switcher-gtk3");
-}
-
-static void
-exec_pref(GtkAction *action, gpointer data)
-{
- uim_launch_helper_application("uim-pref-gtk3");
-}
-
-static void
-exec_dic(GtkAction *action, gpointer data)
-{
- uim_launch_helper_application("uim-dict-gtk3");
-}
-
-static void
-exec_pad(GtkAction *action, gpointer data)
-{
- uim_launch_helper_application("uim-input-pad-ja-gtk3");
-}
-
-static void
-exec_hand(GtkAction *action, gpointer data)
-{
- uim_launch_helper_application("uim-tomoe-gtk");
-}
-
-static void
-exec_help(GtkAction *uic, gpointer data)
-{
- uim_launch_helper_application("uim-help");
-}
-
-/* Just the about window... If it's already open, just focus it */
-static void
-display_about_dialog(GtkAction *action, gpointer data)
-{
- GdkPixbuf *icon = NULL;
- const gchar *authors[] = {"uim Project", NULL};
- /* Feel free to put your names here translators */
- gchar *translators = _("TRANSLATORS");
- icon = gdk_pixbuf_new_from_file(UIM_PIXMAPSDIR "/uim-icon.png", NULL);
-
- gtk_show_about_dialog(NULL,
- "program-name", _("uim Applet"),
- "version", VERSION,
- "copyright", "Copyright \xc2\xa9 2003-2011 uim
Project.",
- "comments", _("Applet for indicating uim's status"),
- "authors", authors,
- "translator-credits",
- strcmp("TRANSLATORS", translators) ? translators
- : NULL,
- "icon", icon,
- "logo", icon, NULL);
-
- if (icon) {
- g_object_unref(icon);
- }
-}
-
-static void
-register_icons(void)
-{
- struct {
- gchar *filename;
- gchar *stock_id;
- } stock_icons[] = {
- {UIM_PIXMAPSDIR"/im_switcher.png", "uim-im-switcher"},
- {UIM_PIXMAPSDIR"/uim-dict.png", "uim-dict"}
- };
- GtkIconFactory *icon_factory = gtk_icon_factory_new();
- GtkIconSet *icon_set;
- GtkIconSource *icon_source;
- gint n_stock_icons = G_N_ELEMENTS(stock_icons);
- gint i;
-
- for (i = 0; i < n_stock_icons; i++) {
- icon_set = gtk_icon_set_new();
- icon_source = gtk_icon_source_new();
- gtk_icon_source_set_filename(icon_source, stock_icons[i].filename);
- gtk_icon_set_add_source(icon_set, icon_source);
- gtk_icon_source_free(icon_source);
- gtk_icon_factory_add(icon_factory, stock_icons[i].stock_id, icon_set);
- gtk_icon_set_unref(icon_set);
- }
-
- gtk_icon_factory_add_default(icon_factory);
-
- g_object_unref(icon_factory);
-}
-
-static gboolean
-uim_applet_new(PanelApplet *applet, const gchar *iid, gpointer data)
-{
- GtkWidget *toolbar;
- GtkActionGroup *action_group;
-
- uimapplet = applet;
-
- if (strcmp(iid, "UimApplet") != 0)
- return FALSE;
-
- uim_init();
-
- toolbar = (GtkWidget*)uim_toolbar_applet_new();
-
- gtk_container_add(GTK_CONTAINER(applet), toolbar);
-
- gtk_widget_show_all(GTK_WIDGET(applet));
-
- register_icons();
-
- action_group = gtk_action_group_new("uim Applet Actions");
- gtk_action_group_set_translation_domain(action_group, GETTEXT_PACKAGE);
- gtk_action_group_add_actions(action_group, uim_menu_actions,
- G_N_ELEMENTS(uim_menu_actions), toolbar);
- panel_applet_setup_menu(applet, uim_menu_xml, action_group);
-#if LIBPANEL_APPLET_HAVE_SET_BACKGROUND_WIDGET
- panel_applet_set_background_widget(applet, GTK_WIDGET(applet));
-#endif
- g_object_unref(action_group);
-
- return TRUE;
-}
-
-
-
-PANEL_APPLET_OUT_PROCESS_FACTORY("UimAppletFactory",
- PANEL_TYPE_APPLET,
- "uim Applet for GNOME",
- (PanelAppletFactoryCallback)uim_applet_new,
- NULL)
=======================================
--- /trunk/gtk3/toolbar/Makefile.am Sun Feb 13 03:01:22 2011
+++ /trunk/gtk3/toolbar/Makefile.am Fri Feb 18 15:07:51 2011
@@ -1,48 +1,3 @@
-if APPLET_GNOME3
-
-helper_defs = -DUIM_DATADIR=\""$(datadir)/@PACKAGE@"\"
-
-libexec_PROGRAMS = uim-toolbar-applet-gnome3
-
-uim_toolbar_applet_gnome3_LDADD = @GTK2_LIBS@ @APPLET_GNOME3_LIBS@ \
- $(top_builddir)/uim/libuim-scm.la \
- $(top_builddir)/uim/libuim.la \
- $(top_builddir)/uim/libuim-custom.la
-uim_toolbar_applet_gnome3_CPPFLAGS = \
- $(helper_defs) -I$(top_srcdir) -I$(top_builddir)
-
-uim_toolbar_applet_gnome3_CFLAGS = @GTK2_CFLAGS@ @APPLET_GNOME3_CFLAGS@
-
-uim_toolbar_applet_gnome3_SOURCES = toolbar-applet-gnome3.c \
- ../../helper/toolbar-common-gtk.c
-
-appletdir = $(datadir)/gnome-panel/applets
-applet_DATA = UimApplet.panel-applet
-applet_in_files = $(applet_DATA:=.in)
-applet_in_in_files = $(applet_in_files:=.in)
-
-$(applet_in_files): $(applet_in_in_files) Makefile
- sed s,@LIBEXECDIR@,$(libexecdir),g <$< >[email protected]
- sed s,@UIM_PIXMAPSDIR@,$(uim_pixmapsdir),g <[email protected] >$@
-
-po_files = $(wildcard $(top_srcdir)/po/*.po)
-$(applet_DATA): $(applet_in_files) $(INTLTOOL_MERGE) $(po_files)
- LC_ALL=C $(INTLTOOL_MERGE) -d -u -c
$(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< $@
-
-servicedir = $(datadir)/dbus-1/services
-service_DATA = org.gnome.panel.applet.UimAppletFactory.service
-service_in_files = $(service_DATA:=.in)
-
-$(service_DATA): $(service_in_files) Makefile
- sed s,@LIBEXECDIR@,$(libexecdir),g <$< >$@
-
-DISTCLEANFILES = UimApplet.panel-applet.in UimApplet.panel-applet \
- UimApplet.panel-applet.in.tmp \
- org.gnome.panel.applet.UimAppletFactory.service.in \
- org.gnome.panel.applet.UimAppletFactory.service
-
-endif
-
if GTK3
bin_PROGRAMS = uim-toolbar-gtk3 uim-toolbar-gtk3-systray
uim_toolbar_gtk3_SOURCES = ../../helper/toolbar-standalone-gtk.c \
=======================================
--- /trunk/helper/Makefile.am Thu Jul 15 00:21:23 2010
+++ /trunk/helper/Makefile.am Fri Feb 18 15:07:51 2011
@@ -36,6 +36,53 @@
GNOME_UimApplet.server.in.tmp
endif
+if APPLET_GNOME3
+libexec_PROGRAMS = uim-toolbar-applet-gnome3
+
+uim_toolbar_applet_gnome3_LDADD = @GTK2_LIBS@ @APPLET_GNOME3_LIBS@ \
+ $(top_builddir)/uim/libuim-scm.la \
+ $(top_builddir)/uim/libuim.la \
+ $(top_builddir)/uim/libuim-custom.la
+uim_toolbar_applet_gnome3_CPPFLAGS = \
+ $(helper_defs) -I$(top_srcdir) -I$(top_builddir)
+
+uim_toolbar_applet_gnome3_CFLAGS = @GTK2_CFLAGS@ @APPLET_GNOME3_CFLAGS@
+
+uim_toolbar_applet_gnome3_SOURCES = toolbar-applet-gnome3.c \
+ toolbar-common-gtk.c
+
+appletdir = $(datadir)/gnome-panel/applets
+applet_DATA = UimApplet.panel-applet
+applet_in_files = $(applet_DATA:=.in)
+applet_in_in_files = $(applet_in_files:=.in)
+
+$(applet_in_files): $(applet_in_in_files) Makefile
+ sed s,@LIBEXECDIR@,$(libexecdir),g <$< >[email protected]
+ sed s,@UIM_PIXMAPSDIR@,$(uim_pixmapsdir),g <[email protected] >$@
+
+po_files = $(wildcard $(top_srcdir)/po/*.po)
+$(applet_DATA): $(applet_in_files) $(INTLTOOL_MERGE) $(po_files)
+ LC_ALL=C $(INTLTOOL_MERGE) -d -u -c
$(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< $@
+
+servicedir = $(datadir)/dbus-1/services
+service_DATA = org.gnome.panel.applet.UimAppletFactory.service
+service_in_files = $(service_DATA:=.in)
+
+$(service_DATA): $(service_in_files) Makefile
+ sed s,@LIBEXECDIR@,$(libexecdir),g <$< >$@
+
+if APPLET_GNOME
+DISTCLEANFILES += UimApplet.panel-applet.in UimApplet.panel-applet \
+ UimApplet.panel-applet.in.tmp \
+ org.gnome.panel.applet.UimAppletFactory.service.in \
+ org.gnome.panel.applet.UimAppletFactory.service
+else
+DISTCLEANFILES = UimApplet.panel-applet.in UimApplet.panel-applet \
+ UimApplet.panel-applet.in.tmp \
+ org.gnome.panel.applet.UimAppletFactory.service.in \
+ org.gnome.panel.applet.UimAppletFactory.service
+endif
+endif
if GTK2
bin_PROGRAMS = uim-toolbar-gtk uim-toolbar-gtk-systray uim-im-switcher-gtk
\
@@ -43,6 +90,9 @@
if APPLET_GNOME
libexec_PROGRAMS += uim-candwin-gtk uim-candwin-tbl-gtk
else
+if APPLET_GNOME3
+libexec_PROGRAMS += uim-candwin-gtk uim-candwin-tbl-gtk
+endif
libexec_PROGRAMS = uim-candwin-gtk uim-candwin-tbl-gtk
endif