Re: Drag and Drop Selection Content



Let me be more clear...

In my callback for "drag-data-get" I'm trying to pass on a GArray which I use in my callback for "drag-data-recieved". I'm currently doing so with this:

gtk_selection_data_set (data,
                                       data->target,
                                       8,
                                       (gpointer) tracks,
                                       sizeof (GArray));

Where 'tracks' is a GArray of uint32_t integers.

My question is, do I immediately free the tracks GArray there (but leave the data preserved) and then free the data later in the "drag-data-recieved" callback? Do I free the data at all?

- Micah Carrick

 Developer - http://www.micahcarrick.com
 GTK+ Forums - http://www.gtkforums.com



Micah Carrick wrote:
In my handler for "drag-data-get" I need to set the selection data to an array of uint23_t integers. How would I do that using gtk_selection_data_set ()?

I have a g_array() containing the uint32_t data...


Secondly, do I need to free the selection data in the handler for "drag-data-recieved" ?




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