aboutsummaryrefslogtreecommitdiff
path: root/libindicator/indicator-object.c
diff options
context:
space:
mode:
authorMarco Trevisan (Treviño) <mail@3v1n0.net>2011-01-27 00:12:42 +0100
committerMarco Trevisan (Treviño) <mail@3v1n0.net>2011-01-27 00:12:42 +0100
commit5873fe77cd5961991c4f1d86001cf41f3414a2d7 (patch)
tree31620baeaa24395557f11ac5dda656f206bec384 /libindicator/indicator-object.c
parentab0f0abc3571f801ffff8c42ad87d1e53d6a8ccf (diff)
downloadlibayatana-indicator-5873fe77cd5961991c4f1d86001cf41f3414a2d7.tar.gz
libayatana-indicator-5873fe77cd5961991c4f1d86001cf41f3414a2d7.tar.bz2
libayatana-indicator-5873fe77cd5961991c4f1d86001cf41f3414a2d7.zip
Added support for "signal-entry" signal
libindicator support the new "scroll-entry" signal (which get called using the target entry as parameter too) I think that maybe we could simply rewrite the "scroll" signal, but I kept it there for compatibility reasons; however, actually just the indicator-sound should be fixed in case of switch...
Diffstat (limited to 'libindicator/indicator-object.c')
-rw-r--r--libindicator/indicator-object.c25
1 files changed, 23 insertions, 2 deletions
diff --git a/libindicator/indicator-object.c b/libindicator/indicator-object.c
index 988a8ae..95ab08a 100644
--- a/libindicator/indicator-object.c
+++ b/libindicator/indicator-object.c
@@ -58,6 +58,7 @@ enum {
ENTRY_REMOVED,
ENTRY_MOVED,
SCROLL,
+ SCROLL_ENTRY,
MENU_SHOW,
SHOW_NOW_CHANGED,
LAST_SIGNAL
@@ -146,7 +147,6 @@ indicator_object_class_init (IndicatorObjectClass *klass)
_indicator_object_marshal_VOID__POINTER_UINT_UINT,
G_TYPE_NONE, 3, G_TYPE_POINTER, G_TYPE_UINT, G_TYPE_UINT, G_TYPE_NONE);
-
/**
IndicatorObject::scroll:
@arg0: The #IndicatorObject object
@@ -162,7 +162,28 @@ indicator_object_class_init (IndicatorObjectClass *klass)
G_STRUCT_OFFSET (IndicatorObjectClass, scroll),
NULL, NULL,
_indicator_object_marshal_VOID__UINT_ENUM,
- G_TYPE_NONE, 2, G_TYPE_UINT, INDICATOR_OBJECT_TYPE_SCROLL_DIRECTION);
+ G_TYPE_NONE, 2, G_TYPE_UINT,
+ INDICATOR_OBJECT_TYPE_SCROLL_DIRECTION);
+
+/**
+ IndicatorObject::scroll-entry:
+ @arg0: The #IndicatorObject object
+ @arg1: A pointer to the #IndicatorObjectEntry that
+ receives the scroll event.
+ @arg2: The delta of the scroll event
+ @arg3: The orientation of the scroll event.
+
+ When the indicator receives a mouse scroll wheel event
+ from the user, this signal is emitted.
+ */
+ signals[SCROLL_ENTRY] = g_signal_new (INDICATOR_OBJECT_SIGNAL_SCROLL_ENTRY,
+ G_TYPE_FROM_CLASS(klass),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (IndicatorObjectClass, scroll_entry),
+ NULL, NULL,
+ _indicator_object_marshal_VOID__POINTER_UINT_ENUM,
+ G_TYPE_NONE, 3, G_TYPE_POINTER, G_TYPE_UINT,
+ INDICATOR_OBJECT_TYPE_SCROLL_DIRECTION);
/**
IndicatorObject::menu-show: