SGListDragInfo Class Reference

Describes a generic supergallery item drag. More...

#include <sgdrag.h>

Inheritance diagram for SGListDragInfo:

DragInformation CCObject SimpleCCObject List of all members.

Public Member Functions

 SGListDragInfo ()
 Default constructor. DO NOT CALL THIS CONSTRUCTOR.
 SGListDragInfo (SuperGallery *ParentGal, SGDisplayNode *DraggedNode, SGMouseInfo *TheMouseInfo, BOOL IsAdjust=FALSE)
 Constructor.
void OnClick (INT32 Flags, POINT Point)
 This is called if a drag was attempted but never started because it was a click all along. It passes the original Click information back to the SGDisplayNode which started the drag by calling its DragWasReallyAClick method.
virtual UINT32 GetCursorID (void)
 To provide the resource ID of the cursor to use during this drag. For scrollbar drags, the cursor should remain the normal arrow shape.
virtual BOOL GetStatusLineText (String_256 *TheText)
 Provide status line text for this drag - While dragging scrollbars no help is required/given, so this always returns FALSE.
SuperGalleryGetParentGallery (void)
SGDisplayNodeGetDraggedNode (void)
SGMouseInfoGetMouseInfo (void)

Private Attributes

SuperGalleryParentGallery
SGDisplayNodeDragNode
SGMouseInfo MouseInfo

Detailed Description

Describes a generic supergallery item drag.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95
Documentation: Docs.doc; Docs.doc

See also:
SGListDragTarget; SuperGallery; SGDisplayNode::HandleEvent

Definition at line 328 of file sgdrag.h.


Constructor & Destructor Documentation

SGListDragInfo::SGListDragInfo  ) 
 

Default constructor. DO NOT CALL THIS CONSTRUCTOR.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95

Definition at line 1194 of file sgdrag.cpp.

01195 {
01196     ERROR3("Default SGListDragInfo constructor called");    
01197 }

SGListDragInfo::SGListDragInfo SuperGallery ParentGal,
SGDisplayNode DraggedNode,
SGMouseInfo TheMouseInfo,
BOOL  IsAdjust = FALSE
 

Constructor.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95
Parameters:
ParentGal - The gallery from which the drag originated [INPUTS]
DraggedNode - the SGDisplayNode that is being dragged

TheMouseInfo -The MouseInfo which was passed into your HandleEvent method for the click which started this drag. (Passed back into the SGDisplayNode::DragWasReallyAClick handler if the drag becomes a click)

IsAdjust - TRUE if it is an "adjust" drag [NOTE - Adjust drags are legal when dragging scrollbars, and are not turned into clicks like normal drags]

Definition at line 1224 of file sgdrag.cpp.

01226                  : DragInformation(IsAdjust)
01227 {
01228     ParentGallery = ParentGal;
01229     DragNode = DraggedNode;
01230     MouseInfo = *TheMouseInfo;  // COPY the MouseInfo structure
01231 
01232     // Set up a few things about this drag - it does not do solid drag
01233     DoesSolidDrag = FALSE;
01234     SolidDragOffset.x = SolidDragOffset.y = 0;  // Set up defaults just in case
01235     SolidDragSize.Set(1,1);
01236 }


Member Function Documentation

UINT32 SGListDragInfo::GetCursorID void   )  [virtual]
 

To provide the resource ID of the cursor to use during this drag. For scrollbar drags, the cursor should remain the normal arrow shape.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95
Returns:
a cursor ID to set during this drag

Reimplemented from DragInformation.

Definition at line 1254 of file sgdrag.cpp.

01255 {
01256      return(_R(IDC_DRAGGING_COLOUR));       // No-can-drop cursor shape
01257 }

SGDisplayNode* SGListDragInfo::GetDraggedNode void   )  [inline]
 

Definition at line 343 of file sgdrag.h.

00343 { return(DragNode); }

SGMouseInfo* SGListDragInfo::GetMouseInfo void   )  [inline]
 

Definition at line 344 of file sgdrag.h.

00344 { return(&MouseInfo); }

SuperGallery* SGListDragInfo::GetParentGallery void   )  [inline]
 

Definition at line 342 of file sgdrag.h.

00342 { return(ParentGallery); }

BOOL SGListDragInfo::GetStatusLineText String_256 TheText  )  [virtual]
 

Provide status line text for this drag - While dragging scrollbars no help is required/given, so this always returns FALSE.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95
Returns:
FALSE - The string has not been filled in

Reimplemented from DragInformation.

Definition at line 1274 of file sgdrag.cpp.

01275 {
01276     ERROR3IF(TheText == NULL, "Illegal NULL param");
01277     TheText->MakeMsg(_R(IDS_SGDRAG_LISTITEM));
01278 
01279     return(TRUE);
01280 }

void SGListDragInfo::OnClick INT32  Flags,
POINT  Point
 

This is called if a drag was attempted but never started because it was a click all along. It passes the original Click information back to the SGDisplayNode which started the drag by calling its DragWasReallyAClick method.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
14/3/95
Parameters:
Flags - Some flags [INPUTS] Point - the point which was clicked
See also:
SGDisplayNode::DragWasReallyAClick

Definition at line 1302 of file sgdrag.cpp.

01303 {
01304     if (DragNode != NULL)
01305     {
01306         SGMiscInfo MiscInfo;
01307         ParentGallery->FillInMiscInfo(&MiscInfo);
01308 
01309         DragNode->DragWasReallyAClick(&MouseInfo, &MiscInfo);
01310     }
01311 }


Member Data Documentation

SGDisplayNode* SGListDragInfo::DragNode [private]
 

Definition at line 348 of file sgdrag.h.

SGMouseInfo SGListDragInfo::MouseInfo [private]
 

Definition at line 349 of file sgdrag.h.

SuperGallery* SGListDragInfo::ParentGallery [private]
 

Definition at line 347 of file sgdrag.h.


The documentation for this class was generated from the following files:
Generated on Sat Nov 10 04:01:09 2007 for Camelot by  doxygen 1.4.4