Main Page | Modules | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

CP_DragDrop Class Reference

A class to manage a drag and drop operation.

List of all members.

Public Member Functions

Constructor / Destructor
 CP_DragDrop ()
 Constructor.
 CP_DragDrop (const CP_DragDrop &inDragDrop)
 CP_DragDrop (DragRef inDragRef)
virtual ~CP_DragDrop () throw ()
 Destructor.
Flavors
void AddFlavor (FlavorType inFlavor, const void *inData, SInt32 inSize, FlavorFlags inFlags, ItemReference inItem)
Getters
UInt16 GetCount () const
CP_DataStream GetItem (UInt16 inItemIndex)
DragRef GetDragRef () const
ItemReference GetItemReference (UInt16 inIndex) const
Operators
CP_DragDropoperator= (const CP_DragDrop &inDragDrop)
Tracking
void TrackDrag (CP_Event_Base &inEvent)

Protected Attributes

DragRef fDragRef
CP_Event_Base fDragDropEvent


Constructor & Destructor Documentation

CPLAT_Begin_Namespace_CPLAT CP_DragDrop::CP_DragDrop  ) 
 

Constructor.

Exceptions:
none 

CP_DragDrop::CP_DragDrop const CP_DragDrop inDragDrop  ) 
 

Copy constructor.

Parameters:
inDragDrop The CP_DragDrop object to copy fields from.
Exceptions:
none 

CP_DragDrop::CP_DragDrop DragRef  inDragRef  ) 
 

Constructor.

Parameters:
inDragRef MacOS DragRef for this drag and drop.
Exceptions:
none 

CP_DragDrop::~CP_DragDrop  )  throw () [virtual]
 

Desstructor.

Exceptions:
none 


Member Function Documentation

void CP_DragDrop::AddFlavor FlavorType  inFlavor,
const void *  inData,
SInt32  inSize,
FlavorFlags  inFlags,
ItemReference  inItem
 

Add a data flavor to our drag. Use this for adding an item to a single item drag only.

Parameters:
inFlavor The FlavorType of the data.
inData Pointer to the data to add.
inSize The size of the data.
inFlags Any FlavorFlags to add to this drag.
inItem An ItemReference for this item, used to locate it on the receiving end.
Exceptions:
none 
Returns:
void

UInt16 CP_DragDrop::GetCount  )  const
 

Returns the number of items contained in this drag.

Exceptions:
none 
Returns:
UInt16 const The number of items in the drag operation.

CP_DataStream CP_DragDrop::GetItem UInt16  inItemIndex  ) 
 

Returns the nth item in the drag.

Parameters:
inItemIndex The index of the item to be returned.
Exceptions:
none 
Returns:
CP_DataStream A CP_DataStream item that contains the data for the requested item.

DragRef CP_DragDrop::GetDragRef  )  const
 

ItemReference CP_DragDrop::GetItemReference UInt16  inIndex  )  const
 

Returns a MacOS ItemReference for the specified item at the passed in index.

Parameters:
inIndex Index of the item to be returned.
Exceptions:
none 
Returns:
ItemReference The MacOS ItemReference for the desired item.

CP_DragDrop & CP_DragDrop::operator= const CP_DragDrop inDragDrop  ) 
 

Assignment operator.

Parameters:
CP_DragDrop CP_DragDrop object to copy the data from.
Exceptions:
none 
Returns:
CP_DragDrop& Returns a reference to ourselves.

void CP_DragDrop::TrackDrag CP_Event_Base inEvent  ) 
 

Handles the tracking of the drag.

Parameters:
inEvent Originating event to begin the drag and drop.
Exceptions:
none 
Returns:
void


Member Data Documentation

DragRef CP_DragDrop::fDragRef [protected]
 

CP_Event_Base CP_DragDrop::fDragDropEvent [protected]
 

MacOS drag reference for this drag.


The documentation for this class was generated from the following files:
Generated on Tue Sep 20 20:21:40 2005 for CPLAT_MacOS by  doxygen 1.4.0