![]() | InDesign SDK 20.5 |
#include <ICursorMgr.h>

Public Types | |
| enum | { kDefaultIID = IID_ICURSORMGR } |
| enum | eCursorModifierState { kNoModifiers = 0x00, kCmdKey = 0x01, kShiftKey = 0x02, kCapsLockKey = 0x04, kOptionAltKey = 0x08, kAltKey = kOptionAltKey, kOptionKey = kOptionAltKey, kControlKey = 0x10, kSpaceKey = 0x20 } |
| enum | { kNoModalCursor = -1, kModalCursor = 0, kWaitCursor = 1, kModalDialogCursor = 2, kDelayedBusyCursor = 3 } |
| enum | { kDontRestorePreviousCursor = 0, kRestorePreviousCursor = 1, kRecomputeNewCursor = 3 } |
| enum | { kSpinningBeachBall = 200, kSpinningWatch = 210, kCyclingArrow = 220 } |
Public Member Functions | |
| virtual CursorID | GetCursorID ()=0 |
| virtual CursorSpec | GetCursorSpec ()=0 |
| virtual ICursorProvider * | SetToolCursorProvider (ICursorProvider *)=0 |
| virtual void | LockToolCursor (bool16 lockit=kTrue)=0 |
| virtual CursorSpec | GetSnapToCursorSpec (CursorSpec ¤tSpec, SnapType snapType)=0 |
| virtual void | SetNewCursor (ICursorProvider *, IControlView *, GSysPoint, eCursorModifierState)=0 |
| virtual void | SetNewCursor ()=0 |
| virtual ICursorProvider * | TheToolCursorProvider () const =0 |
| virtual void | Hide ()=0 |
| virtual void | Show ()=0 |
| virtual bool16 | IsHidden () const =0 |
| virtual void | Suspend ()=0 |
| virtual bool16 | IsSuspended () const =0 |
| virtual void | Resume ()=0 |
| virtual void | StopTrackingCursor ()=0 |
| virtual void | Init ()=0 |
| virtual void | Shutdown ()=0 |
| virtual void | ClearCache ()=0 |
| virtual void | ObscureCursor ()=0 |
| virtual void | UnobscureCursor ()=0 |
| virtual void | AnimateWaitCursor ()=0 |
INTERNAL USE ONLY | |
These methods should not be called directly. Please use the AcquireModalCursor and AcquireWaitCursor helper classes instead. | |
| virtual void | BeginModalCursor (const ModalCursorTicket &callerID)=0 |
| virtual void | BeginModalCursor (const ModalCursorTicket &callerID, const CursorSpec &newspec)=0 |
| virtual void | ChangeModalCursor (const ModalCursorTicket &callerID, const CursorSpec &newspec)=0 |
| virtual void | EndModalCursor (const ModalCursorTicket &callerID)=0 |
| virtual void | BeginWaitCursor (const ModalCursorTicket &callerID)=0 |
| virtual void | AnimateWaitCursor (const ModalCursorTicket &callerID)=0 |
| virtual void | EndWaitCursor (const ModalCursorTicket &callerID)=0 |
Public Member Functions inherited from IPMUnknown | |
| virtual IPMUnknown * | QueryInterface (PMIID interfaceID) const =0 |
| virtual void | AddRef () const =0 |
| virtual void | Release () const =0 |
Protected Member Functions | |
| virtual bool16 | ModifiersAffectProvider (IControlView *view) const =0 |
| virtual bool16 | LocationAffectsProvider (IControlView *view) const =0 |
| virtual bool16 | HaveModifiersChanged (eCursorModifierState &oldModifiers, eCursorModifierState &newModifiers)=0 |
Provides the interface required for maintaining the region associated with each cursor. Used by the application, to figure out how to set the mouse cursor, and used by the windows, to define what cursor should be used for which area of the screen.
| anonymous enum |
| anonymous enum |
A set of "cross platform" definitions for what effect the modifiers have. For instance, is the Alt key equivalent to the Command key or the Option key? Luckily this "equivalence" is limited to the scope of cursor management, where Alt is usually equivalent to Option.
| pure virtual |
Call this periodically to ensure that the cursor keeps spinning.
| pure virtual |
Defaults to the arrow cursor
| pure virtual |
Get the current cursor by it's CursorID.
| pure virtual |
Get the current cursor by it's CursorSpec.
| pure virtual |
Used to compute a new cursor spec from an existing one given the snap type. Looks for a new cursor at kSnapToCrsrOffset from the currentSpec. The new CursorSpec is for a cursor that gives feedback to the user that the mouse is "snapped". If a cursor does not exist with this offset, the original cursor spec is returned.
| currentSpec | IN the current cursor |
| snapType | IN type of snapping: kSnapX, kSnapY, kSnapXandY, kSnapNone |
| protectedpure virtual |
Utility functions to compare modifiers to the cached ones. NOTE: For now, HaveModifiersChanged should really only be called in one place in all of the program. That's because HaveModifiersChanged resets the cached modifiers. If HaveModifiersChanged is called in more than one place, you'll get unpredictable results.
| pure virtual |
Hide the cursor
| pure virtual |
Is the cursor hidden
| pure virtual |
Is the cursor manager suspended
| protectedpure virtual |
Utility function that returns whether location information affects the current cursor provider
| pure virtual |
Used to lock/unlock the tool cursor provider so that the locked cursor is shown instead of the usual tool cursor
| protectedpure virtual |
Utility function that returns whether keyboard modifiers affect the current cursor provider
| pure virtual |
Hide the cursor until the user moves the mouse (this is most useful when the user begins to edit text).
| pure virtual |
Resume the cursor manager. Called when the application has become frontmost again.
| pure virtual |
Obtains the cursor appropriate for the given cursor provider, widgetUnderMouse, global coordinate, and modifier key combination, and makes it the current cursor.
| pure virtual |
Call this function when you need to reevaluate the cursor with it's default parameters
| pure virtual |
Sets the cursor provider to use for the tool area. Returns the old tool cursor provider. Called by the toolbox when the tool is selected.
| pure virtual |
Show the cursor
| pure virtual |
Stop all cursor tracking and reset the cursor to the arrow. Called during application shutdown.
| pure virtual |
Suspend the cursor manager. Called when the application has been suspended (no longer frontmost).
| pure virtual |
Utility function that returns the constant that represents the tool cursor provider. So, for example: UseToolCursorProvider(r); is simply a shortcut for UseCursorProvider(TheToolCursorProvider(), r);
| pure virtual |
To cancel effect of ObscureCursor without waiting for mouse to move