InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IDragDropTextSignalData Class Referenceabstract

#include <IDragDropTextSignalData.h>

Inheritance diagram for IDragDropTextSignalData:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IDRAGDROPTEXTSIGNALDATA }
 

Public Member Functions

virtual void Set (IControlView *sourceView, IControlView *destinationView, const UIDRef &sourceStoryRef, RangeData &sourceRange, const UIDRef &destinationStoryRef, RangeData &destinationRange, RangeData &droppedRange, DragDrop::eCommandType type, IDataExchangeHandler *handler)=0
 
virtual IControlViewGetSourceView ()=0
 
virtual IControlViewGetDestinationView ()=0
 
virtual const UIDRefGetSourceStoryRef ()=0
 
virtual RangeDataGetSourceRange ()=0
 
virtual void SetSourceRange (RangeData &range)=0
 
virtual const UIDRefGetDestinationStoryRef ()=0
 
virtual RangeDataGetDestinationRange ()=0
 
virtual void SetDestinationRange (RangeData &range)=0
 
virtual RangeDataGetDroppedRange ()=0
 
virtual void SetDroppedRange (RangeData &range)=0
 
virtual DragDrop::eCommandType GetDragType ()=0
 
virtual IDataExchangeHandlerGetDataExchangeHandler ()=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Signal data used during kBeforeDragTextSignalResponderService, kBeforeDropTextSignalResponderService, and kAfterDropTextSignalResponderService.

Member Function Documentation

virtual IDataExchangeHandler* IDragDropTextSignalData::GetDataExchangeHandler ()
pure virtual

Description: Get data exchange handler used for the text drag drop operation.

Returns
the data exchange handler.
virtual RangeData& IDragDropTextSignalData::GetDestinationRange ()
pure virtual

Description: Return the destination range within the destination story ref for the drop/drop operation.

Returns
the destination range data (will have length of zero)
virtual const UIDRef& IDragDropTextSignalData::GetDestinationStoryRef ()
pure virtual

Description: Return the detination story reference for the drop/drop operation.

Returns
the destination story uid ref (may be kInvalidUIDRef).
virtual IControlView* IDragDropTextSignalData::GetDestinationView ()
pure virtual

Description: Return the destination control view for the drop/drop operation.

Returns
IControlView the destination control view. May be nil.
virtual DragDrop::eCommandType IDragDropTextSignalData::GetDragType ()
pure virtual

Description: Return what kind of drag we are doing.

Returns
an enum of type DragDrop::eCommandType. kDragMove for moving text, otherwise use kDrop to copy.
virtual RangeData& IDragDropTextSignalData::GetDroppedRange ()
pure virtual

Description: Return the dropped range within the destination story ref for the drop/drop operation.

Returns
the dropped range data (will have length of source range)
virtual RangeData& IDragDropTextSignalData::GetSourceRange ()
pure virtual

Description: Return the source range within the source story ref for the drop/drop operation.

Returns
the source range data.
virtual const UIDRef& IDragDropTextSignalData::GetSourceStoryRef ()
pure virtual

Description: Return the source story reference for the drop/drop operation.

Returns
the source story uid ref.
virtual IControlView* IDragDropTextSignalData::GetSourceView ()
pure virtual

Description: Return the source control view for the drop/drop operation.

Returns
IControlView the source control view.
virtual void IDragDropTextSignalData::Set (IControlViewsourceView,
IControlViewdestinationView,
const UIDRefsourceStoryRef,
RangeDatasourceRange,
const UIDRefdestinationStoryRef,
RangeDatadestinationRange,
RangeDatadroppedRange,
DragDrop::eCommandType type,
IDataExchangeHandlerhandler 
)
pure virtual

Description: Set method that must be called before one of these signals: kBeforeDragTextSignalResponderService - Just before we add text drag content to drag controller. Responder may want to adjust source range (e.g. a partially selected hyperlink). Responder may set global error code to display an alert. kBeforeDropTextSignalResponderService - Just before we create a command to do the drag/drop operation. Responder may set global error code (e.g. some kind of illegal drop that will display an error alert). kAfterDropTextSignalResponderService - Just after the drag/drop command has executed. Responder may want to do extra adjustment (e.g. smart cut/paste to insert/delete extra spaces)

Parameters
sourceViewIN pointer to the control view for the source for drag/drop operation.
destinationViewIN pointer to the control view for the destination for drag/drop operation. May be same as source. May be nil for kBeforeDropTextSignalResponderService signal.
sourceStoryRefIN the source story that is being dragged.
sourceRangeIN/OUT the source text range that is being dragged. May be modified by responder.
destinationStoryRefIN the destination story that is being dropped. Will be kInvalidUIDRef for kBeforeDragTextSignalResponderService signal.
destinationRangeIN/OUT the destination range for the caret drop location (length of zero) that is being dropped. Will be RangeData(0,0,RangeData::kLeanForward)) for kBeforeDragTextSignalResponderService signal. May be modified by responder.
droppedRangeIN/OUT the dropped range for the drag and drop operation. Will be the length of the sourceRange. This range is used to select the text after the drop. May be modified by responder.
typeIN what kind of drag we are doing. kDragMove for moving text, otherwise use kDrop to copy.
handlerIN the data exchange handler used for the text drag drop operation. Gives responders a place to access stored data.
virtual void IDragDropTextSignalData::SetDestinationRange (RangeDatarange)
pure virtual

Description: Sets the destination range for the drop/drop operation.

Parameters
thenew destination range data.
virtual void IDragDropTextSignalData::SetDroppedRange (RangeDatarange)
pure virtual

Description: Sets the dropped range for the drop/drop operation.

Parameters
thenew dropped range data.
virtual void IDragDropTextSignalData::SetSourceRange (RangeDatarange)
pure virtual

Description: Sets the source range for the drop/drop operation.

Parameters
thenew source range data.