diff options
Diffstat (limited to 'libindicator')
-rw-r--r-- | libindicator/Makefile.am | 21 | ||||
-rw-r--r-- | libindicator/indicator-0.4.pc.in.in (renamed from libindicator/indicator.pc.in) | 4 | ||||
-rw-r--r-- | libindicator/indicator-object.c | 5 | ||||
-rw-r--r-- | libindicator/indicator-object.h | 6 | ||||
-rw-r--r-- | libindicator/indicator3-0.4.pc.in.in (renamed from libindicator/indicator3.pc.in) | 4 |
5 files changed, 31 insertions, 9 deletions
diff --git a/libindicator/Makefile.am b/libindicator/Makefile.am index d63f841..4433655 100644 --- a/libindicator/Makefile.am +++ b/libindicator/Makefile.am @@ -10,12 +10,23 @@ BUILT_SOURCES = indicator-object-enum-types.h indicator-object-enum-types.c CLEANFILES = DISTCLEANFILES = EXTRA_DIST = \ - indicator3.pc.in \ - indicator.pc.in + indicator3-0.$(INDICATOR_API_VERSION).pc.in.in \ + indicator-0.$(INDICATOR_API_VERSION).pc.in.in + +INDICATOR_ABI_VERSION = 6 +INDICATOR_API_VERSION = 4 + +%.pc: %.pc.in + sed \ + -e "s|\@indicator_api_version\@|$(INDICATOR_API_VERSION)|" \ + -e "s|\@indicator_abi_version\@|$(INDICATOR_ABI_VERSION)|" \ + $< > $@ + +CLEANFILES = indicator$(VER)-0.$(INDICATOR_API_VERSION).pc include $(top_srcdir)/Makefile.am.marshal -libindicatorincludedir=$(includedir)/libindicator$(VER)-0.3/libindicator +libindicatorincludedir=$(includedir)/libindicator$(VER)-0.$(INDICATOR_API_VERSION)/libindicator indicator_headers = \ indicator.h \ @@ -51,7 +62,7 @@ libindicator_la_LIBADD = \ $(LIBINDICATOR_LIBS) libindicator_la_LDFLAGS = \ - -version-info 3:0:0 \ + -version-info $(INDICATOR_ABI_VERSION):0:0 \ -no-undefined \ -export-symbols-regex "^[^_].*" @@ -66,7 +77,7 @@ libindicator3_la_CFLAGS = $(libindicator_la_CFLAGS) libindicator3_la_LIBADD = $(libindicator_la_LIBADD) libindicator3_la_LDFLAGS = $(libindicator_la_LDFLAGS) -pkgconfig_DATA = indicator$(VER).pc +pkgconfig_DATA = indicator$(VER)-0.$(INDICATOR_API_VERSION).pc pkgconfigdir = $(libdir)/pkgconfig glib_marshal_list = indicator-object-marshal.list diff --git a/libindicator/indicator.pc.in b/libindicator/indicator-0.4.pc.in.in index 4e9b177..df4d6c8 100644 --- a/libindicator/indicator.pc.in +++ b/libindicator/indicator-0.4.pc.in.in @@ -4,10 +4,10 @@ libdir=@libdir@ bindir=@bindir@ includedir=@includedir@ -indicatordir=${libdir}/indicators/5/ +indicatordir=${libdir}/indicators/@indicator_abi_version@ iconsdir=@datarootdir@/@PACKAGE@/icons/ -Cflags: -I${includedir}/libindicator-0.3 +Cflags: -I${includedir}/libindicator-0.@indicator_api_version@ Requires: gtk+-2.0 Libs: -lindicator diff --git a/libindicator/indicator-object.c b/libindicator/indicator-object.c index a91251c..2fe8dd1 100644 --- a/libindicator/indicator-object.c +++ b/libindicator/indicator-object.c @@ -240,6 +240,7 @@ indicator_object_init (IndicatorObject *self) self->priv->entry.label = NULL; self->priv->entry.image = NULL; self->priv->entry.accessible_desc = NULL; + self->priv->entry.name_hint = NULL; self->priv->gotten_entries = FALSE; @@ -435,6 +436,10 @@ get_entries_default (IndicatorObject * io) g_warning("IndicatorObject class does not have an accessible description."); } + if (class->get_name_hint) { + priv->entry.name_hint = class->get_name_hint(io); + } + priv->gotten_entries = TRUE; } diff --git a/libindicator/indicator-object.h b/libindicator/indicator-object.h index 5faeff5..a285949 100644 --- a/libindicator/indicator-object.h +++ b/libindicator/indicator-object.h @@ -77,6 +77,8 @@ typedef struct _IndicatorObjectEntry IndicatorObjectEntry; object. @get_accessible_desc: Gets the accessible descriptionfor this object. + @get_name_hint: Gets the hint of the type of indicator that this + is for the caller. @get_entries: Gets all of the entires for this object returning a #GList of #IndicatorObjectEntries. The list should be under the ownership of the caller but the entires will @@ -106,6 +108,7 @@ struct _IndicatorObjectClass { GtkImage * (*get_image) (IndicatorObject * io); GtkMenu * (*get_menu) (IndicatorObject * io); const gchar * (*get_accessible_desc) (IndicatorObject * io); + const gchar * (*get_name_hint) (IndicatorObject * io); GList * (*get_entries) (IndicatorObject * io); guint (*get_location) (IndicatorObject * io, IndicatorObjectEntry * entry); @@ -150,6 +153,8 @@ struct _IndicatorObject { @menu: The menu to be added to the menubar @accessible_desc: The accessible description of the indicator + @name_hint: A name to describe the indicator being placed to allow + the caller to be more aware of the individual entries. @reserved1: Reserved for future use @reserved2: Reserved for future use @@ -161,6 +166,7 @@ struct _IndicatorObjectEntry { GtkImage * image; GtkMenu * menu; const gchar * accessible_desc; + const gchar * name_hint; void (*reserved1) (void); void (*reserved2) (void); diff --git a/libindicator/indicator3.pc.in b/libindicator/indicator3-0.4.pc.in.in index 9fa0eac..1f34567 100644 --- a/libindicator/indicator3.pc.in +++ b/libindicator/indicator3-0.4.pc.in.in @@ -4,10 +4,10 @@ libdir=@libdir@ bindir=@bindir@ includedir=@includedir@ -indicatordir=${libdir}/indicators3/2/ +indicatordir=${libdir}/indicators3/@indicator_abi_version@/ iconsdir=@datarootdir@/@PACKAGE@/icons/ -Cflags: -I${includedir}/libindicator-0.3 +Cflags: -I${includedir}/libindicator-0.@indicator_api_version@ Requires: gtk+-3.0 Libs: -lindicator3 |