subscriber-view: adopt ::event-activated signal
This commit is contained in:
@@ -24,6 +24,14 @@
|
||||
#include "gcal-view.h"
|
||||
#include "gcal-event-widget.h"
|
||||
|
||||
enum
|
||||
{
|
||||
EVENT_ACTIVATED,
|
||||
NUM_SIGNALS
|
||||
};
|
||||
|
||||
static guint signals[NUM_SIGNALS] = { 0, };
|
||||
|
||||
static void gcal_data_model_subscriber_interface_init (ECalDataModelSubscriberInterface *iface);
|
||||
|
||||
static void gcal_subscriber_view_finalize (GObject *object);
|
||||
@@ -82,6 +90,11 @@ gcal_subscriber_view_class_init (GcalSubscriberViewClass *klass)
|
||||
container_class->add = gcal_subscriber_view_add;
|
||||
container_class->remove = gcal_subscriber_view_remove;
|
||||
container_class->forall = gcal_subscriber_view_forall;
|
||||
|
||||
signals[EVENT_ACTIVATED] = g_signal_new ("event-activated", GCAL_TYPE_VIEW, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GcalSubscriberViewClass, event_activated),
|
||||
NULL, NULL, NULL,
|
||||
G_TYPE_NONE, 1, GCAL_TYPE_EVENT_WIDGET);
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
@@ -49,6 +49,9 @@ struct _GcalSubscriberViewClass
|
||||
{
|
||||
GtkContainerClass parent_class;
|
||||
|
||||
/*< signals >*/
|
||||
void (*event_activated) (GcalSubscriberView *subscriber_view, GcalEventWidget *event_widget);
|
||||
|
||||
/*< public >*/
|
||||
gboolean (*is_child_multicell) (GcalSubscriberView *subscriber, GcalEventWidget *child);
|
||||
guint (*get_child_cell) (GcalSubscriberView *subscriber, GcalEventWidget *child);
|
||||
|
||||
@@ -65,16 +65,6 @@ gcal_view_base_init (gpointer g_iface)
|
||||
NULL, NULL, NULL,
|
||||
G_TYPE_NONE, 2, G_TYPE_POINTER, G_TYPE_POINTER);
|
||||
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,6 @@ struct _GcalViewIface
|
||||
/* signals */
|
||||
void (*create_event) (GcalView *view, icaltimetype *start_span, icaltimetype *end_span, gdouble x, gdouble y);
|
||||
void (*create_event_detailed) (GcalView *view, icaltimetype *start_span, icaltimetype *end_span);
|
||||
void (*event_activated) (GcalView *view, GcalEventWidget *event_widget);
|
||||
|
||||
/* Time handling related API */
|
||||
icaltimetype* (*get_initial_date) (GcalView *view);
|
||||
|
||||
Reference in New Issue
Block a user