[gnome-calendar/ui-rewrite] view: added :event-activated signal



commit 781cf7c38eee14a17d1fe443387543a23d7536a4
Author: Erick Pérez Castellanos <erick red gmail com>
Date:   Thu Oct 16 01:29:34 2014 -0400

    view: added :event-activated signal
    
    Since the events widget are handled entirely inside GcalView
    implementations (aka the views), we need a way to hook event-widget
    activation with GcalWindow which is handling the dialogs (as expected).
    This signal serve as a bridge between those two objects.

 src/gcal-view.c |   10 ++++++++++
 src/gcal-view.h |    1 +
 2 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/src/gcal-view.c b/src/gcal-view.c
index 321c297..7cc5840 100644
--- a/src/gcal-view.c
+++ b/src/gcal-view.c
@@ -52,6 +52,16 @@ gcal_view_base_init (gpointer g_iface)
                     G_TYPE_DOUBLE,
                     G_TYPE_DOUBLE);
 
+      g_signal_new ("event-activated",
+                    GCAL_TYPE_VIEW,
+                    G_SIGNAL_RUN_LAST,
+                    G_STRUCT_OFFSET (GcalViewIface,
+                                     event_activated),
+                    NULL, NULL, NULL,
+                    G_TYPE_NONE,
+                    1,
+                    GCAL_TYPE_EVENT_WIDGET);
+
       initialized = TRUE;
     }
 }
diff --git a/src/gcal-view.h b/src/gcal-view.h
index aeb4b69..56bb6b0 100644
--- a/src/gcal-view.h
+++ b/src/gcal-view.h
@@ -46,6 +46,7 @@ struct _GcalViewIface
 
   /* signals */
   void            (*create_event)                       (GcalView *view, icaltimetype *start_span, 
icaltimetype *end_span, gdouble x, gdouble y);
+  void            (*event_activated)                    (GcalView *view, GcalEventWidget *event_widget);
 
 /* FIXME remove me in favor of the one below */
   void            (*clear_selection)                    (GcalView *view);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]