The IDMHandler class is the base class for the source handler class, IDMSourceHandler, and the target handler class, IDMTargetHandler.
This base class provides static functions to enable you to add source and target direct manipulation support to your application's windows and controls.
You are required to use the enabling functions for direct manipulation support to your
application's windows and controls. These enablers initialize the Windows specific direct
manipulation support.
Note:
You can construct and destruct objects of this class. This class can only be used as the base class for concrete-derived classes, such as IDMSourceHandler and IDMTargetHandler.
![]() |
protected:
virtual ~IDMHandler()
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
protected:
IDMHandler()
Provides the default constructor, which takes no arguments.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Use these static members to get and set the default source and target handlers used by the various enabling functions.
![]() |
public:
static IDMDragHandler& defaultDragHandler()
Returns the default drag handler.
Windows | OS/2 | AIX |
Yes | No | No |
![]() |
public:
static IDMDropTargetHandler& defaultDropTargetHandler()
Returns the default drop target handler.
Windows | OS/2 | AIX |
Yes | No | No |
![]() |
public:
static IDMSourceHandler& defaultSourceHandler()
Returns the default source handler.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
static IDMTargetHandler& defaultTargetHandler()
Returns the default target handler.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
static void setDefaultSourceHandler( IDMSourceHandler& source )
Sets the default source handler to the specified handler. This handler is attached to windows on subsequent calls to IDMHandler::enableDragFrom or IDMHandler::enableDragDropFor.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
static void setDefaultTargetHandler( IDMTargetHandler& target )
Sets the default target handler to the specified handler. This handler is attached to windows on subsequent calls to IDMHandler::enableDragFrom or IDMHandler::enableDragDropFor.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Use these static members to provide a simple means of enabling direct manipulation for application windows and controls.
![]() |
Attaches the default source and target handlers to the specified window and the default source and target renderers to their respective handlers.
public:
static void enableDragDropFor(IMultiLineEdit* mle)
This overload of the function is used for multiline edit source and target enablement. A drag item provider is attached to the multiline edit (MLE) by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the MLE, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag and drop target handlers to the specified window.
public:
static void enableDragDropFor( IToolBarButton* toolBarButton )
This overload of the function is used for tool bar button source and target enablement. A drag item provider is attached to the tool bar button by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the tool bar button, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag and drop target handlers to the specified window.
public:
static void enableDragDropFor(IWindow* window)
This overload of the function is used for the source and target enablement
of controls that are not supported by the default Open Class Library support for
direct manipulation. These controls can be system-defined controls
or custom controls.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag and drop target handlers to the specified window.
public:
static void enableDragDropFor(IEntryField* entryField)
This overload of the function is used for entry field source and target enablement. A drag item provider is attached to the entry field by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the entry field, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag and drop target handlers to the specified window.
public:
static void enableDragDropFor(IContainerControl* container)
This overload of the function is used for container source and target enablement. A drag item provider is attached to the container by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the container, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag and drop target handlers to the specified window.
![]() |
Attaches the default source handler to the specified window and the default source renderer to the handler.
public:
static void enableDragFrom(IContainerControl* container)
This overload of the function is used for container source enablement. A drag item provider is attached to the container by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the container, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag handler to the specified window.
public:
static void enableDragFrom(IWindow* window)
This overload of the function is used for the source enablement
of controls that are not supported by the default Open Class Library support for
direct manipulation. These controls can be system-defined controls
or custom controls.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag handler to the specified window.
public:
static void enableDragFrom(IEntryField* entryField)
This overload of the function is used for entry field source enablement. A drag item provider is attached to the entry field by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the entry field, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag handler to the specified window.
public:
static void enableDragFrom(IMultiLineEdit* mle)
This overload of the function is used for multiline edit source enablement. A drag item provider is attached to the multiline edit (MLE) by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the MLE, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drag handler to the specified window.
![]() |
Attaches the default target handler to the specified window and the default target renderer to the handler.
public:
static void enableDropOn(IToolBar* toolBar)
This overload of the function is used for tool bar target enablement. A drag item provider is attached to the tool bar by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the tool bar, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drop target handler to the specified window.
public:
static void enableDropOn(IContainerControl* container)
This overload of the function is used for container target enablement. A drag item provider is attached to the container by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the container, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drop target handler to the specified window.
public:
static void enableDropOn(IMultiLineEdit* mle)
This overload of the function is used for multiline edit target enablement. A drag item provider is attached to the multiline edit (MLE) by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the MLE, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drop target handler to the specified window.
public:
static void enableDropOn(IEntryField* entryField)
This overload of the function is used for entry field target enablement. A drag item provider is attached to the entry field by default, which provides default direct manipulation support for it. If you want specialized direct manipulation support for the entry field, you must attach your own drag item providers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
public:
static void enableDropOn(IWindow* window)
This overload of the function is used for the target enablement
of controls that are not supported by the default Open Class Library support for
direct manipulation. These controls can be system-defined controls
or custom controls.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Attaches the default drop target handler to the specified window.
Handler-processing members query information about the windows that the handler is attached to.
![]() |
protected:
bool isContainerControl(const IWindow* window) const
Returns true if the window is a container control.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
These static members set a default item provider for the argument
window.
Note:
![]() |
Sets the default item provider for the argument window.
protected:
static void setItemProvider(IMultiLineEdit* mle)
Sets the default item provider for the multiline edit object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
protected:
static void setItemProvider(IToolBarButton* toolBar)
Sets the default item provider for the tool bar button object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
protected:
static void setItemProvider(IContainerControl* container)
Sets the default item provider for the container object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
protected:
static void setItemProvider(IEntryField* entryField)
Sets the default item provider for the entry field object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
protected:
static void setItemProvider(IToolBar* toolBar)
Sets the default item provider for the tool bar object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
These members provide a means of accessing the base IDMRenderer objects involved in the direct manipulation described by objects of this class. These objects are used to handle the rendering of drag item objects that are compatible with the supported rendering mechanisms and formats (RMFs).
![]() |
protected:
virtual IDMHandler& addRenderer( const IDMRenderer& newRenderer )
Adds a specified renderer to this handler. The renderer is added to the end
of the renderer collection.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
protected:
virtual unsigned numberOfRenderers()
Returns the number of renderers currently in the renderer collection.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
Removes the specified renderer from this handler.
Note:
protected:
virtual IDMHandler& removeRenderer(unsigned position)
Windows | OS/2 | AIX |
Yes | Yes | Yes |
protected:
virtual IDMHandler& removeRenderer( const IDMRenderer& rendererToRemove )
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
protected:
virtual IDMRenderer* renderer(unsigned position)
Returns the renderer at the given position.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
protected:
virtual IDMHandler& replaceRenderer( unsigned position, const IDMRenderer& replacement )
Replaces a renderer with another specified renderer.
Note:
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
protected:
virtual IDMHandler& setRenderer( const IDMRenderer& newRenderer )
Sets the renderer for this handler. Removes any pre-existing renderers.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
virtual ~IHandler()
virtual IString asDebugInfo() const
virtual IString asString() const
virtual IHandler& disable()
virtual IHandler& enable(bool enable = true)
virtual IHandler& handleEventsFor(IWindow* window)
IHandler()
bool isEnabled() const
virtual IHandler& stopHandlingEventsFor(IWindow* window)
virtual IEventResult defaultProcedure(IEvent& event)
virtual bool dispatchHandlerEvent(IEvent& event) = 0