[gnome-calendar/wip/gbsneto/dnd: 11/14] year-view: make the year navigator a DnD dest



commit c7d92e9f373719cec6df29fb9272f65bf5654959
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Sat May 21 18:04:24 2016 -0300

    year-view: make the year navigator a DnD dest
    
    This way, we can drop events at the widget.

 src/gcal-year-view.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/gcal-year-view.c b/src/gcal-year-view.c
index 86772ec..0ffa553 100644
--- a/src/gcal-year-view.c
+++ b/src/gcal-year-view.c
@@ -1663,6 +1663,13 @@ gcal_year_view_init (GcalYearView *self)
 
   gtk_list_box_set_header_func (GTK_LIST_BOX (self->events_sidebar), update_sidebar_headers, self, NULL);
   gtk_list_box_set_sort_func (GTK_LIST_BOX (self->events_sidebar), sidebar_sort_func, NULL, NULL);
+
+  /* The year navigator is a DnD destination */
+  gtk_drag_dest_set (self->navigator,
+                     0,
+                     NULL,
+                     0,
+                     GDK_ACTION_COPY);
 }
 
 static void


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