VirtualBox Main API
Public Member Functions | List of all members
IDnDTarget Interface Reference

Abstract interface for handling drag'n drop targets. More...

Inheritance diagram for IDnDTarget:
IDnDBase IGuestDnDTarget

Public Member Functions

void enter (in unsigned long screenId, in unsigned long y, in unsigned long x, in DnDAction defaultAction, in DnDAction[] allowedActions, in wstring[] formats, [retval] out DnDAction resultAction)
 Informs the target about a drag and drop enter event.
 
void move (in unsigned long screenId, in unsigned long x, in unsigned long y, in DnDAction defaultAction, in DnDAction[] allowedActions, in wstring[] formats, [retval] out DnDAction resultAction)
 Informs the target about a drag and drop move event.
 
void leave (in unsigned long screenId)
 Informs the target about a drag and drop leave event.
 
void drop (in unsigned long screenId, in unsigned long x, in unsigned long y, in DnDAction defaultAction, in DnDAction[] allowedActions, in wstring[] formats, out wstring format, [retval] out DnDAction resultAction)
 Informs the target about a drop event.
 
void sendData (in unsigned long screenId, in wstring format, in octet[] data, [retval] out IProgress progress)
 Initiates sending data to the target.
 
void cancel ([retval] out boolean veto)
 Requests cancelling the current operation.
 
- Public Member Functions inherited from IDnDBase
void isFormatSupported (in wstring format, [retval] out boolean supported)
 Checks if a specific drag'n drop MIME / Content-type format is supported.
 
void addFormats (in wstring[] formats)
 Adds MIME / Content-type formats to the supported formats.
 
void removeFormats (in wstring[] formats)
 Removes MIME / Content-type formats from the supported formats.
 

Additional Inherited Members

- Public Attributes inherited from IDnDBase
readonly attribute wstring[] formats
 Returns all supported drag'n drop formats.
 

Detailed Description

Abstract interface for handling drag'n drop targets.

Interface ID:
{FF5BEFC3-4BA3-7903-2AA4-43988BA11554}

Member Function Documentation

◆ enter()

void IDnDTarget::enter ( in unsigned long  screenId,
in unsigned long  y,
in unsigned long  x,
in DnDAction  defaultAction,
in DnDAction[]  allowedActions,
in wstring[]  formats,
[retval] out DnDAction  resultAction 
)

Informs the target about a drag and drop enter event.

Parameters
screenIdThe screen ID where the drag and drop event occurred.
yY-position of the event.
xX-position of the event.
defaultActionThe default action to use.
allowedActionsThe actions which are allowed.
formatsThe supported MIME types.
resultActionThe resulting action of this event.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.

◆ move()

void IDnDTarget::move ( in unsigned long  screenId,
in unsigned long  x,
in unsigned long  y,
in DnDAction  defaultAction,
in DnDAction[]  allowedActions,
in wstring[]  formats,
[retval] out DnDAction  resultAction 
)

Informs the target about a drag and drop move event.

Parameters
screenIdThe screen ID where the drag and drop event occurred.
xX-position of the event.
yY-position of the event.
defaultActionThe default action to use.
allowedActionsThe actions which are allowed.
formatsThe supported MIME types.
resultActionThe resulting action of this event.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.

◆ leave()

void IDnDTarget::leave ( in unsigned long  screenId)

Informs the target about a drag and drop leave event.

Parameters
screenIdThe screen ID where the drag and drop event occurred.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.

◆ drop()

void IDnDTarget::drop ( in unsigned long  screenId,
in unsigned long  x,
in unsigned long  y,
in DnDAction  defaultAction,
in DnDAction[]  allowedActions,
in wstring[]  formats,
out wstring  format,
[retval] out DnDAction  resultAction 
)

Informs the target about a drop event.

Parameters
screenIdThe screen ID where the Drag and Drop event occurred.
xX-position of the event.
yY-position of the event.
defaultActionThe default action to use.
allowedActionsThe actions which are allowed.
formatsThe supported MIME types.
formatThe resulting format of this event.
resultActionThe resulting action of this event.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.

◆ sendData()

void IDnDTarget::sendData ( in unsigned long  screenId,
in wstring  format,
in octet[]  data,
[retval] out IProgress  progress 
)

Initiates sending data to the target.

Parameters
screenIdThe screen ID where the drag and drop event occurred.
formatThe MIME type the data is in.
dataThe actual data.
progressProgress object to track the operation completion.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.

◆ cancel()

void IDnDTarget::cancel ( [retval] out boolean  veto)

Requests cancelling the current operation.

The target can veto the request in case the operation is not cancelable at the moment.

Parameters
vetoWhether the target has vetoed cancelling the operation.
Expected result codes:
VBOX_E_VM_ERRORVMM device is not available.