The IDMTargetEnterEvent class encapsulates direct manipulation target enter events when a user drags drag items over a target. Objects of this class are constructed by the target handler, IDMTargetHandler. Objects of this class are constructed for each target enter event.
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 target enter event for a target.
The event result field is of particular importance for these event objects. The result indicates whether the drag item objects can be dropped on the target, and, if so, what the default drag operation is. This class provides specialized functions to set the components of the event result.
You can construct and destruct objects of this class.
![]() |
public:
virtual ~IDMTargetEnterEvent()
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
IDMTargetEnterEvent(const IEvent& event)
Constructs objects of this class from a generic IEvent object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Use these members to query information for the container target enter event.
![]() |
public:
virtual IContainerControl* container() const
Returns a pointer to the container within which the target enter event occurred.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual unsigned long containerId() const
Returns the target container's identifier (ID).
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual bool isAboveFirst() const
Returns true if the target enter event was generated above the first list item in one of the list views of a container. An example of a container list view is details view.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual bool isDragAfter() const
Returns true if the target enter event was generated above the first list item, between list items, or after the last list item in one of the list views of a container. An example of a container list view is details view.
False is returned if the event was generated over a list item.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual IContainerObject* object() const
Returns a pointer to the object over which the target enter event occurred.
If the event occurred over the container's white space or
the window is not a container, 0 is returned.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Use these members to set and query event information for this class.
![]() |
public:
virtual unsigned long defaultOperation() const
Returns the default drag operation for the target. IDMOperation::operation provides a list of the drag operations.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual DropIndicator dropIndicator() const
Returns the drop indicator, which is one of the following:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual IPoint position() const
Returns the position of the hot spot of the pointing device.
IAccessError | The pointing device's position was not returned. The drag information is not accessible. |
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
IDMTargetEnterEvent& setDefaultOperation( unsigned long operation )
Sets the default drag operation for the target.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
IDMTargetEnterEvent& setDropIndicator( DropIndicator indicator )
Sets the drop indicator, which is one of the following:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
virtual ~IDMEvent()
IDMEvent(const IEvent& event)
virtual ~IDMTargetEvent()
IDMTargetEvent(const IEvent& event)
virtual IPresSpaceHandle presSpace()
virtual void releasePresSpace()
virtual ~IEvent()
IWindowHandle controlHandle() const
virtual IWindow* controlWindow() const
IEvent& decrementOwnerLevels()
virtual IWindow* dispatchingWindow() const
unsigned long eventId() const
IWindowHandle handle() const
IEvent( const IWindowHandle& handle, unsigned long eventId, const IEventParameter1& parameter1, const IEventParameter2& parameter2 )
IEvent(const IEvent& event)
IEvent( IWindow* window, unsigned long eventId, const IEventParameter1& parameter1, const IEventParameter2& parameter2 )
IEvent& operator =(const IEvent& event)
IEventParameter1 parameter1() const
IEventParameter2 parameter2() const
bool passToOwner() const
IEventResult result() const
IEvent& setControlHandle(const IWindowHandle& handle)
IEvent& setDispatchingHandle(const IWindowHandle& handle)
IEvent& setDispatchingWindow(IWindow* window)
IEvent& setHandle(const IWindowHandle& handle)
IEvent& setNumberOfLevels(int levels = - 1)
IEvent& setPassToOwner(bool passOn = true)
IEvent& setResult(bool eventResult)
IEvent& setResult(const IEventResult& eventResult)
virtual IWindow* window() const