aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-09-14 09:55:16 -0500
committerTed Gould <ted@gould.cx>2010-09-14 09:55:16 -0500
commit69221d8f85a2e1b5f3638e7dfc988b772f74737e (patch)
treeb1835d4ff54e4f153d7b4e301de8c2ac03e41a40
parent06b508479f76b2d90425ad0e16c65c94c3c8eb49 (diff)
downloadlibayatana-indicator-69221d8f85a2e1b5f3638e7dfc988b772f74737e.tar.gz
libayatana-indicator-69221d8f85a2e1b5f3638e7dfc988b772f74737e.tar.bz2
libayatana-indicator-69221d8f85a2e1b5f3638e7dfc988b772f74737e.zip
Adding in the signal for the menu showing
-rw-r--r--libindicator/indicator-object-marshal.list1
-rw-r--r--libindicator/indicator-object.c53
2 files changed, 37 insertions, 17 deletions
diff --git a/libindicator/indicator-object-marshal.list b/libindicator/indicator-object-marshal.list
index d9dd126..bb447bb 100644
--- a/libindicator/indicator-object-marshal.list
+++ b/libindicator/indicator-object-marshal.list
@@ -1,2 +1,3 @@
VOID: POINTER, UINT, UINT
VOID: UINT,ENUM
+VOID: POINTER, UINT
diff --git a/libindicator/indicator-object.c b/libindicator/indicator-object.c
index 511a407..a5fd740 100644
--- a/libindicator/indicator-object.c
+++ b/libindicator/indicator-object.c
@@ -57,7 +57,8 @@ enum {
ENTRY_ADDED,
ENTRY_REMOVED,
ENTRY_MOVED,
- SCROLL,
+ SCROLL,
+ MENU_SHOW,
LAST_SIGNAL
};
@@ -145,22 +146,40 @@ indicator_object_class_init (IndicatorObjectClass *klass)
G_TYPE_NONE, 3, G_TYPE_POINTER, G_TYPE_UINT, G_TYPE_UINT, G_TYPE_NONE);
- /**
- IndicatorObject::scroll:
- @arg0: The #IndicatorObject object
- @arg1: The delta of the scroll event
- @arg2: The orientation of the scroll event.
-
- When the indicator receives a mouse scroll wheel event
- from the user, this signal is emitted.
- */
- signals[SCROLL] = g_signal_new (INDICATOR_OBJECT_SIGNAL_SCROLL,
- G_TYPE_FROM_CLASS(klass),
- G_SIGNAL_RUN_LAST,
- 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);
+ /**
+ IndicatorObject::scroll:
+ @arg0: The #IndicatorObject object
+ @arg1: The delta of the scroll event
+ @arg2: The orientation of the scroll event.
+
+ When the indicator receives a mouse scroll wheel event
+ from the user, this signal is emitted.
+ */
+ signals[SCROLL] = g_signal_new (INDICATOR_OBJECT_SIGNAL_SCROLL,
+ G_TYPE_FROM_CLASS(klass),
+ G_SIGNAL_RUN_LAST,
+ 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);
+
+ /**
+ IndicatorObject::menu-show:
+ @arg0: The #IndicatorObject object
+ @arg1: A pointer to the #IndicatorObjectEntry that
+ is being shown.
+ @arg2: The timestamp of the event
+
+ Used when the indicator wants to signal up the stack
+ that the menu should be shown.
+ */
+ signals[MENU_SHOW] = g_signal_new (INDICATOR_OBJECT_SIGNAL_MENU_SHOW,
+ G_TYPE_FROM_CLASS(klass),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (IndicatorObjectClass, menu_show),
+ NULL, NULL,
+ _indicator_object_marshal_VOID__POINTER_UINT,
+ G_TYPE_NONE, 2, G_TYPE_POINTER, G_TYPE_UINT);
return;