IDMTargetDropEvent

The IDMTargetDropEvent class encapsulates a direct manipulation drop event when a user drops drag items onto a target. Objects of this class are constructed by the target handler, IDMTargetHandler. An object of this class is constructed once when the drop occurs.

Objects of this class provide information about the drag items from the static IDMTargetOperation object. The target operation object is created during the processing of the initial IDMTargetEnterEvent for a target.


IDMTargetDropEvent - Member Functions and Data by Group

Constructors & Destructor

You can construct and destruct objects of this class.


[view class]
~IDMTargetDropEvent
public:
virtual ~IDMTargetDropEvent()

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
IDMTargetDropEvent
public:
IDMTargetDropEvent(const IEvent& event)

Constructs objects of this class from a generic IEvent object.

Exception

IAccessError The object for the target drop event was not created. The drag information is not accessible.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Container Support

Use these members to provide drop support for the container drop event.


[view class]
container
public:
virtual IContainerControl* container() const

Returns a pointer to the container where the drop occurred.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
containerId
public:
virtual unsigned long containerId() const

Returns the target container's identifier (ID).

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
object
public:
virtual IContainerObject* object() const

Returns a pointer to the object over which the drop occurred. If the drop occurred over the container's white space or the window is not a container, 0 is returned.
Note: The white space of a container is an area that no container objects occupy.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Target Drop Information

Use these members to set and query drop and target information.


[view class]
dropPosition
public:
virtual IPoint dropPosition() const

Returns the position where the drop occurred. This position is given in desktop coordinates (i.e., the origin (0,0) is the top left corner of the screen).

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes

OS/2 Considerations

in OS/2, the origin is the bottom left corner of the screen.


[view class]
setDropPosition
public:
virtual IDMTargetDropEvent& setDropPosition( const IPoint& position )

Sets the position where the drop occurred. This position is given in desktop coordinates (i.e., the origin (0,0) is the top left corner of the screen).

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes

OS/2 Considerations

in OS/2, the origin is the bottom left corner of the screen.


[view class]
setTargetInfo
public:
virtual IDMTargetDropEvent& setTargetInfo( unsigned long info )

Sets information that is passed to the source renderer.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
targetInfo
public:
virtual unsigned long targetInfo() const

Returns the target-defined information.
Note: This is an extra member the source and target can use to pass additional information to each other. You can use it to implement the specialized behavior for user-defined rendering mechanisms and formats.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


IDMTargetDropEvent - Inherited Member Functions and Data

Inherited Public Functions

IDMEvent
IDMTargetEvent
IEvent

Inherited Public Data

Inherited Protected Functions

Inherited Protected Data