home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
draglb.zip
/
OPERFIX.HPP
< prev
next >
Wrap
Text File
|
1994-06-08
|
1KB
|
37 lines
#ifndef _OPERFIX_
#define _OPERFIX_
extern "C"
{
/* define what subsections of PM headers to include */
#define INCL_WINSTDDRAG // Standard drag stuff
#include <os2.h>
}
class OperFix : private IDMSourceOperation {
typedef IDMSourceOperation
Inherited;
/*******************************************************************************
* This class is defined to workaround a design bug which prevents the source *
* of a drag operation from determing what operation actually occurred at the *
* target (i.e. copy or move). The source requires this information, because *
* the IDMItem::sourceEnd function is overridden to remove the item from the *
* source list box if a move occurred. *
*******************************************************************************/
public:
/*-------------------------- Operation Determination ---------------------------
| dropOperation - Returns the operation that occurred during the drop. |
------------------------------------------------------------------------------*/
static unsigned long
dropOperation( IDMSourceEndEvent &event )
{
OperFix *p = (OperFix *)event.dragItem()->sourceOperation();
return( p->dragInfo()->usOperation );
}
private:
OperFix ( );
};
#endif // _OPERFIX_