Inheritance diagram for CP_View_Imp:
Setters | |
void | SetCommandID (UInt32 inCommandID) |
virtual void | SetLocation (const CP_Point &inLocation) |
virtual void | SetSize (const CP_Size &inSize) |
virtual void | SetPortBounds (const CP_Rect &inBounds) |
Superview | |
virtual void | AddSubview (CP_View *inView) |
void | AdjustToSuperview (CP_View *inView) |
Testers | |
virtual bool | IsVisible () const |
virtual bool | IsActive () const |
virtual bool | IsEnabled () const |
bool | ContainsPoint (const CP_Point &inPortPoint) |
Frame | |
virtual void | HandleBoundsChanged (const CP_Rect &, const CP_Rect &) |
virtual void | OnBoundsChanged (const CP_Rect &inPreviousBounds, const CP_Rect &inNewBounds) |
Initialization | |
virtual void | OnInitPersist (CP_View *inSuperview, CP_DataValueList &inDataValueList) |
virtual void | OnFinishPersist () |
Drag Target | |
virtual void | OnDragEnter (CP_DragDrop &inDragDrop, bool inDragHasLeftSender) |
virtual void | OnDragLeave (CP_DragDrop &inDragDrop) |
virtual void | OnDragTrack (CP_DragDrop &inDragDrop) |
static CP_M_DragTarget * | FindDragTarget (OSWindow inOSWindow, CP_Point &inMouseLocation, CP_DragDrop &inDragDrop) |
Public Member Functions | |
CP_ViewBackground * | GetViewBackground () |
void | SetViewBackground (CP_ViewBackground *inViewBackground) |
void | SetID (FourCharCode inIdentifier) |
FourCharCode | GetID () |
void | RegisterSignal (const CP_SignalHolder &inSignal) |
CP_DataValueSignal * | FindSignal (const CP_String &inSignalName) |
UInt32 | GetNumberSignals () |
CP_String | GetNthSignalName (UInt32 inSignalIndex) |
void | RegisterSlot (const CP_SlotHolder &inSlot) |
CP_DataValueSlot | FindSlot (const CP_String &inSlotName) |
UInt32 | GetNumberSlots () |
CP_String | GetNthSlotName (UInt32 inSlotIndex) |
template<class R, class P1, class P2> | |
CP_CommandHandlerSignal * | Connect (CPLAT::CP_CommandNo cmd, void(R::*handler)(P1, P2), SInt32 mode) |
template<class R, class P1, class P2> | |
void | Connect (CP_Object *control, const CPLAT::CP_String &signalName, void(R::*handler)(P1, P2)) |
void | disconnect_all () |
void | signal_connect (CP_Signal *inSender) |
void | signal_disconnect (CP_Signal *inSender) |
Constructor / Destructor | |
virtual | ~CP_View_Imp () throw () |
Destructor. | |
Appearance | |
virtual void | Show () |
virtual void | Hide () |
virtual void | Activate () |
virtual void | Deactivate () |
virtual void | Enable () |
virtual void | Disable () |
Static Public Member Functions | |
static void | Connect (CP_Object *sender, const CP_String &signalName, CP_Object *receiver, const CP_String &slotName, const bool reciprocal=false) |
static void | Connect (CP_Object *sender, CP_Object *receiver, const bool reciprocal=false, const CP_String &signalName=kCP_Signal_ValueChanged, const CP_String &slotName=kCP_Slot_SetValue) |
Protected Member Functions | |
virtual bool | OnCanAcceptDrag (UInt32 inItem, CP_DragDrop &inDragDrop)=0 |
virtual bool | PtInDropArea (CP_Point &inGlobalPoint) |
Constructor / Destructor | |
CP_View_Imp () | |
Constructor. | |
CP_View_Imp (CP_View *inSuperview, const CP_Point &inUpperLeft, const CP_Size &inContentSize, bool inCreateImp=false, UInt32 inFlags=CP_E_ViewFlags_None) | |
Protected Attributes | |
CP_View_Imp_Base * | fViewImpBase |
CP_EventHandler | fDummyEventHandler |
UInt32 | fCommandID |
CP_SmartPtr< CP_FrameAdapter > | fFrameAdapter |
UInt32 | fFlags |
CP_ViewBackground * | fViewBackground |
CP_DataValueSignal | fBoundsChangedSignal |
CP_DataValueSignal | fShowSignal |
CP_DataValueSignal | fHideSignal |
CP_DataValueSignal | fActivateSignal |
CP_DataValueSignal | fDeactivateSignal |
CP_DataValueSignal | fEnableSignal |
CP_DataValueSignal | fDisableSignal |
CP_DataValueSlot | fShowSlot |
CP_DataValueSlot | fHideSlot |
CP_DataValueSlot | fActivateSlot |
CP_DataValueSlot | fDeactivateSlot |
CP_DataValueSlot | fEnableSlot |
CP_DataValueSlot | fDisableSlot |
CP_Signals_Array * | fSignals |
CP_Slots_Array * | fSlots |
FourCharCode | fObjectID |
CP_Commands_Array * | fCommands |
CP_MenuSelectionSignal * | fMennuSelectionSignal |
sender_set | fSenders |
CP_Window * | fWindow |
bool | fDropAreaIsHilited |
bool | fCanAcceptCurrentDrag |
Static Protected Attributes | |
static FourCharCode | fObjectIDCount = 0 |
static CP_DragTarget_List * | fsDragTargetList = NULL |
static CP_M_DragTarget * | fsCurrentDragTarget = NULL |
static bool | fsDragHasLeftSender = false |
Under Windows all panes are implmented in this class as Windows child windows.
|
Destructor.
|
|
Constructor.
|
|
Constructor. Create a pane with the upper left corner at inLocation, and the content size of inSize.
|
|
Show this view.
Reimplemented in CP_Window_Imp, CP_DrawerWindow, CP_QT_MovieView, CP_SheetWindow, CP_TabView, CP_View, and CP_Window. |
|
Hide this view.
Reimplemented in CP_Window_Imp, CP_DrawerWindow, CP_QT_MovieView, CP_SheetWindow, CP_TabView, CP_View, and CP_Window. |
|
Activate this view.
Reimplemented in CP_QT_MovieView, CP_TextView, and CP_View. |
|
Deactivate this view.
Reimplemented in CP_QT_MovieView, CP_TextView, and CP_View. |
|
Enable this view.
Reimplemented in CP_QT_MovieView, and CP_View. |
|
Disable this view.
Reimplemented in CP_QT_MovieView, and CP_View. |
|
Converts the passed in point from global to port coordinates.
Reimplemented in CP_Window_Imp. |
|
Converts the passed in point from global to local coordinates.
|
|
Converts the passed in point from port to local coordinates.
|
|
Reimplemented in CP_Window_Imp. |
|
Reimplemented in CP_Window_Imp. |
|
|
|
|
|
Sets some user data for this view. This is used to allow users to attach some data to a CP_View object.
Reimplemented in CP_Window_Imp. |
|
Sets some user data for this view. This is used to allow users to attach some data to a CP_View object.
Reimplemented in CP_Window_Imp. |
|
Reimplemented from CP_M_DragTarget. |
|
Return the event handler for this view implementation. This will be the OS implentation event handler.
|
|
Return the CP_Window that contains this pane.
Reimplemented in CP_Window. |
|
Return the superview of this view.
|
|
Return the local bounds of this pane. This will always have the top left corner at location 0, 0.
Reimplemented in CP_Window_Imp. |
|
Return the local bounds of this pane. This is the bounds of the pane in port coordinates.
Reimplemented in CP_Window_Imp. |
|
Reimplemented in CP_Window_Imp, and CP_Scroller. |
|
Return the location of this pane. This is the panes location relative its superviews top left corner.
Reimplemented in CP_Window_Imp. |
|
Return the size of this pane.
Reimplemented in CP_Window_Imp. |
|
|
|
Used when the user needs to draw into a view at times other than the normal drawing times. This will setup the view for drawing into, and return a canvas object suitable for use.
Reimplemented in CP_QT_MovieView. |
|
Call after the drawing is complete to free up system resources.
|
|
CP_View_Imp method called from the user panes callback. This calls the virtual OnDraw function which users override to do the actual drawing in their panes.
|
|
Cause the passed in area of this pane to become invalid and force the OS to create an update event to redraw that portion.
|
|
Cause the passed in area of this pane to become invalid and force the OS to create an update event to redraw that portion.
|
|
Cause the view to redraw itself on the next chance it gets. This will mark the view as dirty, and redraw itself the next time the underlying OS updates dirty views. If used in a loop, the view will not be redrawn untill the underlying OS can process an event.
Reimplemented in CP_Window_Imp. |
|
MacOS - Returns the part code that the passed in point is over. The default implementation returns kControlIndicatorPart.
Reimplemented in CP_SelectColorButton, CP_Splitter, and CP_TableView. |
|
MacOS - Called when the user is holding the mouse down, and moving it in this view. This will track the mouse until the user has released the mouse button. The last part the mouse was over when the user has released the mouse button is returned.
Reimplemented in CP_SelectColorButton, CP_Splitter, CP_TableView, and CP_TV_DataBrowser. |
|
MacOS - Called when some action is causing this view to become focused. This default implementation returnns kControlNoPart.
Reimplemented in CP_TableView. |
|
|
|
Reimplemented in CP_TableView. |
|
|
|
|
|
Sets the frame adapter for this view. The frame adapter determines how a view will resize and reposition itself when the superview that contains it changes bounds.
|
|
|
|
|
|
|
|
Sets the command id associated with this view. This will be the command sent out when the control is clicked on.
|
|
Reimplemented in CP_Window_Imp, CP_View, and CP_Window. |
|
Reimplemented in CP_Window_Imp, CP_View, and CP_Window. |
|
Sets the bounds of this view in port coordinates.
Reimplemented in CP_Window_Imp. |
|
|
|
|
|
|
|
|
|
|
|
|
|
Reimplemented in CP_View. |
|
|
|
|
|
|
|
Returns true if this view is visible.
Reimplemented in CP_Window_Imp, and CP_View. |
|
Returns true if this view is active.
Reimplemented in CP_View. |
|
Returns true if this view is enabled.
Reimplemented in CP_View. |
|
Tests this view to see if it contains the passed in point, which is in port coordinates.
|
|
|
|
|
|
Creates the MacOS user pane control that performs all drawing and other interaction between this class and the MacOS ControlManager
|
|
MacOS - Returns the WindowRef of our containing window when the user has dragged an object over it.
|
|
MacOS - Returns the region of our target view that can accept the object that is currently over this view. The default implementation returns the the entire view bounds. Users can override if they want to only have a portion of the view act as a drop area.
Implements CP_M_DragTarget. |
|
|
|
Virtual method that users use to handle the actual drawing of their panes data. All platform implemntations eventually call this method to perform the actual drawing, and this is the only place that drawing should occur in. You can also assume that by the time this method is called, the clipping region and other necessary platform stuff has been setup for you to draw. The passed in canvas also contains a valid port for drawing into.
Reimplemented in CP_BackgroundView, CP_DisclosureButton, CP_FocusBorder, CP_OpenGLView, CP_QT_MovieView, CP_Relevance, CP_RoundButton, CP_Scroller, CP_SearchField, CP_SegmentView, CP_SelectColorButton, CP_Splitter, CP_TableHeaders, CP_TableView, CP_TV_DataBrowser, CP_TV_TextColumn, and CP_WindowListHeader. |
|
|
|
Initialize the event handler for events that this class will handle.
Reimplemented in CP_Window_Imp, CP_BevelButton, CP_ChasingArrows, CP_DisclosureButton, CP_DisclosureTriangle, CP_DocumentWindow, CP_DrawerWindow, CP_EditField, CP_FocusBorder, CP_LittleArrows, CP_LittleArrowsEditBuddy, CP_PlatformControl, CP_PopupButton, CP_PopupMenu, CP_ProgressBar, CP_PushButton, CP_QT_MovieView, CP_RadioGroup, CP_ScrollBar, CP_SearchField, CP_SegmentView, CP_SelectColorButton, CP_Slider, CP_Splitter, CP_TableHeaders, CP_TableView, CP_TabView, CP_TextGroupBox, CP_TextView, CP_Toolbar, and CP_WindowListHeader. |
|
Reimplemented in CP_Scroller, CP_Splitter, and CP_View. |
|
Called when the bounds of this view has changed.
Reimplemented in CP_OpenGLView, and CP_QT_MovieView. |
|
Finish initializing our object. Calls OnInitPersist to do the actual work.
|
|
Called when we have constructed our persist objects and are now giving each one a chance to finish up. Calls OnFinishPersist to do the actual work.
|
|
|
Override this do the actual finishing up of initializing the persist object. This is called after all of the other objects have been created.
Reimplemented in CP_TabView, and CP_View. |
|
Sets the identifier for this object. If a specific identifier is not set with this function, then a default id is used, which is simply a running count of the number of objects created.
|
|
Returns the objects identifier.
|
|
Registers the signal / signal name contained in the passed in inSignal object.
|
|
Finds the CP_DataValueSignal object that matches the passed in inSignalName.
|
|
Returns the number of signals for this object.
|
|
Returns the signal name of the passed in signal index.
|
|
Registers the slot / slot name contained in the passed in inSlot object.
|
|
Finds the CP_Slot1 object that matches the passed in inSlotName.
|
|
Returns the number of slots for this object.
|
|
Returns the slot name of the passed in signal index.
|
|
|
|
|
|
|
|
|
|
Updates the status of a command.
|
|
Updates the status of a command based on the current state of the application.
|
|
Handles the processing of a command. If the command has been registered with this class, then its signal will be called. If the command has not been registered, then this function does nothing with the passed in command.
|
|
Signal called when a menu item is selected with no associated command. |
|
Returns the signal called when a menu item is selected and has no command associated with it.
|
|
Registers the passed in command. This places the command in a list of commands we will handle updating the status for, and when called executing the signal registered for the command.
|
|
Registers the passed in command. This places the command in a list of commands we will handle updating the status for, and when called executing the signal registered for the command.
|
|
Registers the passed in command. This places the command in a list of commands we will handle updating the status for. You are returned the signal object that you need to connect your slot to.
|
|
Registers the passed in command, returning the command status signal. If the command already exists, we will return the existing command status signal if there is one, otherwise we create a new signal, and return that signal. If there is already a signal, then return the existing signal.
|
|
Registers the passed in command, returning the command handling signal. If the command already exists, we will return the existing command handler signal if there is one, otherwise we create a new signal, and return that signal. If there is already a signal, then return the existing signal.
|
|
Returns true if the passed in command is known to this class.
|
|
Replaces a CP_Command for the passed in command number.
|
|
Unregisters a command.
|
|
Returns the CP_Command object associated with the passed in command number.
|
|
MacOS - Handles the processing of the passed in HICommand. This will translate the HICommand into a CPLAT CP_CommandNo for processing and updating the status of the command.
|
|
|
|
|
|
|
|
|
|
Tracks the drag by calling on the OS to handle the drag.
|
|
Tracks the drag by calling on the OS to handle the drag.
|
|
Called when the user tries to drop an object on this drag target. For each item inn the drag and drop, OnAcceptDrag will be called, which is the method you should override to determine if the object can be dropped onto this target. If any of the items are not accepted by the object, then false is returned.
|
|
Called when the drag enters a new drop area. This is used to show the MacOS default drag hiliting.
|
|
Called when the drag leaves a drop area. This is used to remove the MacOS default drag hiliting.
|
|
Adds the passed in CP_M_DragTarget to the global list of drag targets that this object maintains. This is the list of objects that get checked during a drag and drop operation to see if the object can receive the dropped object when the mouse if over the target object.
|
|
Removes a previously added CP_M_DragTarget object. This is called for you automatically when aa CP_M_DragTarget object is destroyed. However you can call this at other times, if you want to remove an object as a postential drop target for drag and drops.
|
|
Callback to the MacOS Drag Manager that is called during a drag and drop tracking operation.
|
|
Callback to the MacOS Drag Manager when the user has dropped an object over a drag target.
|
|
Finds and returns the CP_M_DragTarget that is in the passed in OSWindow at the passed in mouse location. The mouse location is in global coordinates. If no target was found at the passed in location, then NULL is returned.
|
|
Called when the user has entered a registered drag target object.
|
|
Called when the user is has left the current drag target object.
|
|
Called when the user is tracking or moving the mouse during a drag and drop operationn.
|
|
|
|
Returns true if the passed in global point is over this drag target.
|
|
Called when the user is dragging an object around in a window. This is called from the MacOS Drag Manager callback.
|
|
|
|
Object that actually implements the pane. |
|
Dummy event handler if the view imp has not been created. |
|
The command associated with this view / control. |
|
|
|
|
|
|
|
Signal sent when the bounds of this view change. |
|
Signal sent when the view is becoming visible. |
|
Signal sent when the view is becoming hidden. |
|
Signal sent when the view is becoming active. |
|
Signal sent when the view is becoming inactive. |
|
Signal sent when the view is becoming enabled. |
|
Signal sent when the view is becoming disable. |
|
Slot to show a view. |
|
Slot to hide a view. |
|
Slot to activate a view. |
|
Slot to deactivate a view. |
|
Slot to enable a view. |
|
|
|
List of registered signals for this object. |
|
List of registered slots for this object. |
|
Object identifier. |
|
|
|
List of commands managed by this class. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|