This class defines a user inteface entity that allows the user to control some attribute or data within the system.
![]() | controlID Unique menu ID for resource binding |
![]() | ~PControl () Destroy a control. |
![]() | OnBalloonHelp () This function is called whenever a balloon help function for the interactor is required |
![]() | IsTabStop () const Determine if the dialog tabbing will stop at this control. |
![]() | GetControlID () const Get the resource identifier of the control when it was loaded from a resource in a dialog. |
![]() | SetControlID ( PRESOURCE_ID theID ) Set the resource identifier of the control. |
![]() | GetNotifier () const Get the current call back function that is called whenever the control needs to notify the application of some change, eg. |
![]() | WillNotifyOnStateUpdate () const Get the flag for notification function called when a control requires its enable or value state updated. |
![]() | SetNotifier ( const PNotifier & func, BOOL notifyForStateUpdate = FALSE ) Set the call back function that is called whenever the control needs to notify the application of some change, eg when a pushbutton is pressed, or when the control needs to be updated by the application, eg when enable states are changed and the PInteractor::UpdateCommandSources() function is called. |
![]() | GetValuePointer () const Get the current value pointer associated with the control. |
![]() | SetValuePointer ( void * ptr ) Set the current value pointer associated with the control. |
![]() | TransferValue ( int option ) This function transfers the value of the control to or from the variable pointed to by the value pointer member variable. |
![]() | GetBalloonHelp () const Get the balloon help text. |
![]() | SetBalloonHelp ( const PString & text ) Set the balloon help text. |
![]() | DefaultDimensions () Set the default (minimum) dimensions for the control. |
![]() | UpdateMyCommandSources () Scan through all child interactors and if they are a command source, execute their notification function to enable or disable the item. |
![]() | PNotifier codes |
![]() | Codes passed to the notification function on changes of state. |
![]() | Overrides from class PInteractor |
![]() | New functions for class |
![]() | callback Notification function to call on menu selection. |
![]() | valuePointer Pointer to the value that is attached to the control. |
![]() | notifyForStateUpdate Flag for notification function called when a control requires its enable or value state updated |
![]() | balloonHelpText Help text for balloon help. |
![]() | PControl ( PInteractor * parent, const PNotifier & func, void * valuePtr ) Create a new control, storing all the information provided. |
![]() | PControl ( PInteractorLayout * parent, PRESOURCE_ID ctlID, const PNotifier & func, void * valuePtr ) Create control from interactor layout with the specified control ID. |
![]() | Overrides from class PInteractor |
![]() | Member variables |
Overrides from class PObject
System callback functions.
This class defines a user inteface entity that allows the user to control some attribute or data within the system. A control is most commonly placed on a PDialog or PInteractorLayout class of interactor.The PControl class is an abstract class. No instances of PControl should ever be created. Descendents of PControl will implement some particular user interface element, eg edit text, list box, radio button etc
A change to a scroll bar may proceed for some time, for example if the
mouse button is pressed in the down arrow and held down. An auto-repeat
would occur to continually change the scroll bar value until it is
released.
The default action is to do nothing.
The default action is to do nothing.
The behaviour here is to call the notification function with the code
NotifyEnable. This function is used internally by the library. It would normally not
be called directly.
PControl( PInteractorLayout * parent, PRESOURCE_ID ctlID, const PNotifier & func, void * valuePtr )
ctlID - Identifier for the control in the layout.
func - Function to call when control changes state.
valuePtr - Variable to change to the controls state.virtual ~PControl()
PNotifier codes
Codes passed to the notification function on changes of state.
NotifyEnable
NotifyUpdate
NotifyChange
Overrides from class PInteractor
virtual PBalloon* OnBalloonHelp()
New functions for class
virtual BOOL IsTabStop() const
PRESOURCE_ID GetControlID() const
void SetControlID( PRESOURCE_ID theID )
const PNotifier& GetNotifier() const
BOOL WillNotifyOnStateUpdate() const
void SetNotifier( const PNotifier & func, BOOL notifyForStateUpdate = FALSE )
notifyForStateUpdate - Notification function is to be called when a control requires its
enable or value state updated. If FALSE the notification function is
only called when the item is selected.
void* GetValuePointer() const
void SetValuePointer( void * ptr )
virtual void TransferValue( int option )
const PString& GetBalloonHelp() const
void SetBalloonHelp( const PString & text )
virtual void DefaultDimensions()
Overrides from class PInteractor
virtual void UpdateMyCommandSources()
Member variables
PRESOURCE_ID controlID
PNotifier callback
void* valuePointer
BOOL notifyForStateUpdate
Alphabetic index HTML hierarchy of classes or Java