PHP-GTK Manual
This manual is provided as a courtesy. It is not an official source. Please check gtk.php.net for updated information.
Sets the calling widgets as a drag-and-drop source, so that data can be dragged from the widget to a drop target.
Example 58. Using drag_source_set()
$targets = array( array( 'text/uri-list', 0, 0)); $list->drag_source_set(GDK_BUTTON1_MASK|GDK_BUTTON3_MASK, $targets, GDK_ACTION_COPY);
The first parameter, start_button_mask, is a bitmask with all mouse buttons allowed to start the drag.
The targets is an array of data types provided as drag/drop data. See drag_dest_set() for a detailed explanation of this topic.
actions determine which actions will take place if the drop event occurs; a copy/move/delete. See GdkDragAction for all possible options.