Signal

GtkPlacesSidebar::drag-action-requested

since: 3.10

Declaration

gint
drag_action_requested (
  GtkPlacesSidebar* self,
  GdkDragContext* context,
  GioFile* dest_file,
  gpointer source_file_list,
  gpointer user_data
)

Description [src]

When the user starts a drag-and-drop operation and the sidebar needs to ask the application for which drag action to perform, then the sidebar will emit this signal.

The application can evaluate the context for customary actions, or it can check the type of the files indicated by source_file_list against the possible actions for the destination dest_file.

The drag action to use must be the return value of the signal handler.

Default handler:

The default handler is called after the handlers added via g_signal_connect().

Available since: 3.10

Parameters

context

Type: GdkDragContext

GdkDragContext with information about the drag operation.

The data is owned by the caller of the function.
dest_file

Type: GFile

GFile with the tentative location that is being hovered for a drop.

The data is owned by the caller of the function.
source_file_list

Type: A list of None

List of GFile that are being dragged.

Return value

Type: gint

The drag action to use, for example, #GDK_ACTION_COPY or #GDK_ACTION_MOVE, or 0 if no action is allowed here (i.e. drops are not allowed in the specified dest_file).