[gnome-applets/wip/segeiger/in-process: 4/6] timer: switch to in-process applet
- From: Sebastian Geiger <segeiger src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-applets/wip/segeiger/in-process: 4/6] timer: switch to in-process applet
- Date: Sun, 31 Jul 2016 19:09:17 +0000 (UTC)
commit 03ad6f4413817050e8479da39cb5741875afe112
Author: Sebastian Geiger <sbastig gmx net>
Date: Sun Jul 31 00:45:09 2016 +0200
timer: switch to in-process applet
timer/Makefile.am | 24 +++++++++----------
...rg.gnome.applets.TimerApplet.panel-applet.in.in | 3 +-
...nome.panel.applet.TimerAppletFactory.service.in | 3 --
timer/src/Makefile.am | 14 +++++++----
timer/src/timer-applet.c | 8 +++---
5 files changed, 26 insertions(+), 26 deletions(-)
---
diff --git a/timer/Makefile.am b/timer/Makefile.am
index c7f00d6..342ea53 100644
--- a/timer/Makefile.am
+++ b/timer/Makefile.am
@@ -6,23 +6,16 @@ appletdir = $(LIBPANEL_APPLET_DIR)
applet_in_files = org.gnome.applets.TimerApplet.panel-applet.in
applet_DATA = $(applet_in_files:.panel-applet.in=.panel-applet)
+APPLET_LOCATION=$(pkglibdir)/$(LIBPANEL_APPLET_API_VERSION)/libtimer-applet.so
+
$(applet_in_files): $(applet_in_files).in Makefile
$(AM_V_GEN)sed \
- -e "s|\@LIBEXECDIR\@|$(libexecdir)|" \
+ -e "s|\@APPLET_LOCATION\@|$(APPLET_LOCATION)|" \
-e "s|\@VERSION\@|$(PACKAGE_VERSION)|" \
$< > $@
%.panel-applet: %.panel-applet.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE)
$(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
-servicedir = $(datadir)/dbus-1/services
-service_in_files = org.gnome.panel.applet.TimerAppletFactory.service.in
-service_DATA = $(service_in_files:.service.in=.service)
-
-org.gnome.panel.applet.TimerAppletFactory.service: $(service_in_files)
- $(AM_V_GEN)sed \
- -e "s|\@LIBEXECDIR\@|$(libexecdir)|" \
- $< > $@
-
gsettings_schemas_in_in = \
org.gnome.gnome-applets.timer.gschema.xml.in.in
@@ -36,11 +29,16 @@ gsettings_SCHEMAS = $(gsettings_schemas_in:.xml.in=.xml)
@GSETTINGS_RULES@
-CLEANFILES = $(applet_DATA) $(applet_DATA).in $(service_DATA) $(gsettings_SCHEMAS) *.gschema.valid
-
EXTRA_DIST = \
$(gsettings_schemas_in_in) \
org.gnome.applets.TimerApplet.panel-applet.in.in \
- $(service_in_files)
+ $(NULL)
+
+CLEANFILES = \
+ $(applet_DATA) \
+ $(applet_DATA).in \
+ $(gsettings_SCHEMAS) \
+ *.gschema.valid \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/timer/org.gnome.applets.TimerApplet.panel-applet.in.in
b/timer/org.gnome.applets.TimerApplet.panel-applet.in.in
index 9f56c39..a4142cf 100644
--- a/timer/org.gnome.applets.TimerApplet.panel-applet.in.in
+++ b/timer/org.gnome.applets.TimerApplet.panel-applet.in.in
@@ -1,6 +1,7 @@
[Applet Factory]
Id=TimerAppletFactory
-Location=@LIBEXECDIR@/timer-applet
+InProcess=true
+Location=@APPLET_LOCATION@
_Name=Timer Factory
_Description=Timer Factory
diff --git a/timer/src/Makefile.am b/timer/src/Makefile.am
index 16e83d6..2235560 100644
--- a/timer/src/Makefile.am
+++ b/timer/src/Makefile.am
@@ -1,28 +1,32 @@
NULL =
-libexec_PROGRAMS = timer-applet
+timer_applet_libdir = $(pkglibdir)/$(LIBPANEL_APPLET_API_VERSION)
+timer_applet_lib_LTLIBRARIES = libtimer-applet.la
-timer_applet_CFLAGS = \
+libtimer_applet_la_CPPFLAGS = \
-I. \
-I$(srcdir) \
-DGNOMELOCALEDIR=\""$(localedir)"\" \
-DPKG_DATA_DIR=\""$(pkgdatadir)"\" \
+ $(NULL)
+
+libtimer_applet_la_CFLAGS = \
$(GNOME_APPLETS_CFLAGS) \
$(LIBNOTIFY_CFLAGS) \
$(WARN_CFLAGS) \
$(AM_CFLAGS) \
$(NULL)
-timer_applet_SOURCES = \
+libtimer_applet_la_SOURCES = \
timer-applet.c \
$(NULL)
-timer_applet_LDFLAGS = \
+libtimer_applet_la_LDFLAGS = \
$(WARN_LDFLAGS) \
$(AM_LDFLAGS) \
$(NULL)
-timer_applet_LDADD = \
+libtimer_applet_la_LIBADD = \
$(GNOME_APPLETS_LIBS) \
$(LIBNOTIFY_LIBS) \
$(NULL)
diff --git a/timer/src/timer-applet.c b/timer/src/timer-applet.c
index fc22e62..af85700 100644
--- a/timer/src/timer-applet.c
+++ b/timer/src/timer-applet.c
@@ -469,7 +469,7 @@ timer_factory (PanelApplet* applet, const char* iid, gpointer data)
}
/* needed by gnome-panel applet library */
-PANEL_APPLET_OUT_PROCESS_FACTORY("TimerAppletFactory",
- PANEL_TYPE_APPLET,
- timer_factory,
- NULL)
+PANEL_APPLET_IN_PROCESS_FACTORY("TimerAppletFactory",
+ PANEL_TYPE_APPLET,
+ timer_factory,
+ NULL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]