The IDMItemProviderFor class is a template class that generates an IDMItemProvider-derived class for your derived IDMItem classes.
This class overrides the key functions of the IDMItemProvider class and dispatches static functions of your IDMItem-derived class specified as the template argument. IDMItemProviderFor::provideSourceItems calls the static IDMItem::generateSourceItems member function of your derived IDMItem class.
IDMItemProvider::provideTargetItemFor creates a new object of your
IDMItem-derived class. This requires that your IDMItem-derived class
provide a constructor that accepts an argument of the type
const IDMItem::Handle&. This argument is a reference to
the handle of the generic IDMItem object.
Note:
You can construct and destruct objects of this class.
![]() |
public:
virtual ~IDMItemProviderFor()
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
IDMItemProviderFor()
Provides the default constructor to construct objects of this class.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
Use these members to provide event-specific support during a direct manipulation. These members are called when a direct manipulation starts on a source window and during the processing of the initial target enter event.
![]() |
public:
virtual bool provideSourceItems( const IDMSourceOperation::Handle& sourceOperation )
Adds IDMItem or IDMItem-derived class objects to the specified sourceOperation. This function is called when a direct manipulation starts on a source window.
This function delegates requests to the static member function IDMItem::generateSourceItems of the template's argument class, <T>, where T represents the derived IDMItem class. <T>::generateSourceItems creates appropriate source drag items and adds them to the specified source operation object
If source drag items are provided, true is returned.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
public:
virtual IDMItem::Handle provideTargetItemFor( const IDMItem::Handle& dragItem )
Replaces generic IDMItem objects with an IDMItem-derived class during the processing of the initial target enter event.
This function creates a new object of the template's argument class, <T>, where T represents the derived IDMItem class, and replaces the specified generic IDMItem object, dragItem, in the target operation with the new object. The template argument class must provide a constructor that accepts an argument of the type const IDMItem::Handle&. This argument is a reference to the handle of the generic IDMItem object.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
virtual ~IDMItemProvider()
IDMItemProvider()
virtual bool provideEnterSupport( IDMTargetEnterEvent& event )
virtual bool provideHelpFor(IDMTargetHelpEvent& event)
virtual bool provideLeaveSupport( IDMTargetLeaveEvent& event )