|
Photon microGUI widgets library 0.6.0
|
A widget that invokes a callback after a given length of time. More...
#include <Timer.h>
Classes | |
| struct | ArgPVoid |
| Contains resource IDs for arguments of type void*. More... | |
| struct | Arguments |
| Contains resource IDs for all Timer arguments. More... | |
| struct | ArgUnsignedLong |
| Contains resource IDs for arguments of type unsigned long. More... | |
| struct | Callback |
Contains resource IDs for callbacks of type PtCallback_t. More... | |
| struct | Callbacks |
| Contains resource IDs for all Timer callbacks. More... | |
| struct | ThisArgs |
| Contains resource IDs for Timer arguments. More... | |
| struct | ThisCallbacks |
| Contains resource IDs for Timer callbacks. More... | |
Public Member Functions | |
| Timer (int abn) | |
| (constructor) | |
| Timer (PtWidget_t *wdg) | |
| (constructor) | |
| Timer (const Timer &other) | |
| (copy constructor) | |
| Timer & | operator= (const Timer &other) |
| Assigns value in Timer widget. | |
| Widget & | operator= (const Widget &other) |
| Assigns value in Widget. | |
| Widget & | operator= (PtWidget_t *wdg) |
| Assigns value in Widget. | |
| bool | operator== (const Widget &other) const |
| Compares Widgets. | |
| bool | operator< (const Widget &other) const |
| Compares Widgets. | |
Event raisers | |
Public Attributes | |
| WidgetResourcesSingleton | resource |
| Resources of the Timer. | |
Properties | |
Properties are used to simplify use of widget resources. | |
| phproperty< unsigned long >::bind< Timer, ArgUnsignedLong::eArgUnsignedLong, Arguments::timer_initial > | Initial |
| The time, in milliseconds, before the first timer callback is activated. | |
| phproperty< unsigned long >::bind< Timer, ArgUnsignedLong::eArgUnsignedLong, Arguments::timer_repeat > | Interval |
| The time, in milliseconds, for the repeat rate of the timer once the initial time period has expired. | |
Events | |
Additional Inherited Members | |
| typedef phevent::ph_callback_t | callback_t |
| An event handler that is raised when an event occur. | |
| Widget (int abn) | |
| (constructor) | |
| Widget (PtWidget_t *wdg) | |
| (constructor) | |
| Widget (const Widget &other) | |
| (copy constructor) | |
| void | swap (Widget &other) |
| Exchanges the contents of *this and other. | |
| Widget & | operator= (const Widget &other) |
| Assigns value in Widget. | |
| Widget & | operator= (PtWidget_t *wdg) |
| Assigns value in Widget. | |
| bool | operator== (const Widget &other) const |
| Compares Widgets. | |
| bool | operator!= (const Widget &other) const |
| Compares Widgets. | |
| bool | operator< (const Widget &other) const |
| Compares Widgets. | |
| bool | operator<= (const Widget &other) const |
| Compares Widgets. | |
| bool | operator> (const Widget &other) const |
| Compares Widgets. | |
| bool | operator>= (const Widget &other) const |
| Compares Widgets. | |
| PtWidget_t * | get () const |
| Returns the stored pointer. | |
| operator PtWidget_t * () | |
| Converts Widget to Photon widget pointer. | |
| operator const PtWidget_t * () const | |
| Converts Widget to constant Photon widget pointer. | |
| void | BringToFront () |
| Brings the widget to the front of the z-order. | |
| bool | Contains (const Widget &widget) |
| Retrieves a value indicating whether the specified widget is a child of the widget. | |
| bool | Focus () |
| Sets input focus to the widget. | |
| Widget | GetNextWidget (const Widget &widget, bool forward=true) const |
| Retrieves the next widget forward or back in the tab order of child widgets. | |
| void | Hide () |
| Conceals the widget from the user. | |
| void | Invalidate (PhRect_t rc, bool invalidateChildren=false) |
| Invalidates a specific region of the widget and causes a paint message to be sent to the widget. | |
| void | Invalidate (bool invalidateChildren=false) |
| Invalidates a specific region of the widget and causes a paint message to be sent to the widget. | |
| bool | Realize () |
| Make the widget and its children visible and possibly interactive. | |
| void | Refresh () |
| Forces the widget to invalidate its client area and immediately redraw itself and any child widgets. | |
| void | SendToBack () |
| Sends the widget to the back of the z-order. | |
| void | SetBounds (short x, short y, unsigned short width, unsigned short height) |
| Sets the bounds of the widget to the specified location and size. | |
| void | SetBounds (short x, short y) |
| Sets the bounds of the widget to the specified location. | |
| void | Select () |
| Activates the widget. | |
| void | Show () |
| Displays the widget to the user. | |
| bool | Unrealize () |
| Unrealizes the widget and all its children. | |
| void | OnDestroyed (PtCallbackInfo_t *info) |
| Raises the Widget::Destroyed event. | |
| void | OnBlocked (PtCallbackInfo_t *info) |
| Raises the Widget::Blocked event. | |
| void | OnDragDrop (PtCallbackInfo_t *info) |
| Raises the Widget::DragDrop event. | |
| void | OnOutbound (PtCallbackInfo_t *info) |
| Raises the Widget::Outbound event. | |
| void | OnRealized (PtCallbackInfo_t *info) |
| Raises the Widget::Realized event. | |
| void | OnUnrealized (PtCallbackInfo_t *info) |
| Raises the Widget::Unrealized event. | |
Static Protected Member Functions inherited from PhWidgets::Widget | |
| static void | Update () |
| Causes the Photon microGUI to redraw the all invalidated regions. | |
Protected Attributes inherited from PhWidgets::Widget | |
| WidgetResourcesSingleton | resource |
| Resources of the Widget. | |
| property< bool >::bind< Widget, &Widget::getAllowDrop, &Widget::setAllowDrop > | AllowDrop |
| Gets or sets a value indicating whether the widget can accept data that the user drags onto it. | |
| phbitmask< unsigned, Flags::Anchor::type, Flags::Anchor::All >::bind< Widget, Arguments< unsigned >::Flag, Arguments< unsigned >::AnchorFlags > | Anchor |
| Gets or sets flags specifying how the widget is anchored to its parent. | |
| phproperty< unsigned short >::bind< Widget, Arguments< unsigned short >::Scalar, Arguments< unsigned short >::BevelWidth > | BevelWidth |
| Gets or sets the bevel width of the widget. | |
| property< short, property<>::ro >::bind< Widget, &Widget::getBottom > | Bottom |
| Gets the distance, in pixels, between the bottom edge of the widget and the top edge of its container's client area. | |
| property< PhArea_t >::bind< Widget, &Widget::getBounds, &Widget::setBounds > | Bounds |
| Gets or sets the size and location of the widget including its nonclient elements, in pixels, relative to the parent widget. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::getCanFocus > | CanFocus |
| Gets a value indicating whether the widget can receive focus. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::getCanSelect > | CanSelect |
| Gets a value indicating whether the widget can be selected. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::getContainsFocus > | ContainsFocus |
| Gets a value indicating whether the widget, or one of its child widgets, currently has the input focus. | |
| property< PhWidgets::Cursor >::bind< Widget, &Widget::getCursor, &Widget::setCursor > | Cursor |
| Gets or sets the cursor that is displayed when the mouse pointer is over the widget. | |
| phproperty< Drawing::Color >::bind< Widget, Arguments< PgColor_t >::Color, Arguments< PgColor_t >::CursorColor > | CursorColor |
| Gets or sets the color of the cursor pointer when it's inside the widget. | |
| property< bool >::bind< Widget, &Widget::getEnabled, &Widget::setEnabled > | Enabled |
| Gets or sets a value indicating whether the widget can respond to user interaction. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::getFocused > | Focused |
| Gets a value indicating whether the widget has input focus. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::hasChildren > | HasChildren |
| Gets a value indicating whether the widget contains one or more child widgets. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::hasParent > | HasParent |
| Gets a value indicating whether the widget has parent. | |
| phproperty< unsigned short >::bind< Widget, Arguments< unsigned short >::Scalar, Arguments< unsigned short >::Height > | Height |
| Gets or sets the height of the widget. | |
| property< std::string >::bind< Widget, &Widget::getHelpTopic, &Widget::setHelpTopic > | HelpTopic |
| Gets or sets the help topic of the widget. | |
| property< bool, property<>::ro >::bind< Widget, &Widget::getIsRealized > | IsRealized |
| Gets or sets a value indicating whether the widget is realized. | |
| property< short >::bind< Widget, &Widget::getLeft, &Widget::setLeft > | Left |
| Gets or sets the distance, in pixels, between the left edge of the widget and the left edge of its container's client area. | |
| property< PhPoint_t >::bind< Widget, &Widget::getLocation, &Widget::setLocation > | Location |
| Gets or sets the coordinates of the upper-left corner of the widget relative to the upper-left corner of its container. | |
| property< PtWidget_t * >::bind< Widget, &Widget::getParent, &Widget::setParent > | Parent |
| Gets or sets the parent container of the widget. | |
| phproperty< PhPoint_t >::bind< Widget, Arguments< PhPoint_t >::Struct, Arguments< PhPoint_t >::Position > | Position |
| Gets or sets the absolute coordinates of the upper-left corner of the widget. | |
| property< short, property<>::ro >::bind< Widget, &Widget::getRight > | Right |
| Gets the distance, in pixels, between the right edge of the widget and the left edge of its container's client area. | |
| phproperty< PhDim_t >::bind< Widget, Arguments< PhDim_t >::Struct, Arguments< PhDim_t >::Dimension > | Size |
| Gets or sets the size of the widget. | |
| tag_property< Widget, &Widget::getTag, &Widget::setTag > | Tag |
| Gets or sets the resource that contains data about the widget. | |
| property< short >::bind< Widget, &Widget::getTop, &Widget::setTop > | Top |
| Gets or sets the distance, in pixels, between the top edge of the widget and the top edge of its container's client area. | |
| property< bool >::bind< Widget, &Widget::getVisible, &Widget::setVisible > | Visible |
| Gets or sets a value indicating whether the widget and all its child widgets are displayed. | |
| property< std::set< PhWidgets::Widget >, property<>::ro >::bind< Widget, &Widget::getWidgets > | Widgets |
| Gets the list of widgets contained within the widget. | |
| phproperty< unsigned short >::bind< Widget, Arguments< unsigned short >::Scalar, Arguments< unsigned short >::Width > | Width |
| Gets or sets the width of the widget. | |
| phbitmask< unsigned long, Flags::Extended::type >::bind< Widget, Arguments< unsigned long >::Flag, Arguments< unsigned long >::ExtendedFlags > | ExtendedFlags |
| Gets or sets extended flags inherited by all widgets. See Flags::Extended::type. | |
| phbitmask< long, Flags::type >::bind< Widget, Arguments< long >::Flag, Arguments< long >::Flags > | WidgetFlags |
| Gets or sets flags inherited by all widgets. | |
| phbitmask< long, Flags::Resize::type >::bind< Widget, Arguments< long >::Flag, Arguments< long >::Resiztype > | Resiztype |
| Gets or sets flags to control a widget's resize policy. See Flags::Resize::type. | |
| phwidgets_event< Widget, Widget::Callbacks<>::Destroyed > | Destroyed |
| Occurs when the widget is destroyed. | |
| phwidgets_event< Widget, Widget::Callbacks<>::Blocked > | Blocked |
| Occurs when the widget is blocked. | |
| phwidgets_event< Widget, Widget::Callbacks<>::DragAndDrop > | DragDrop |
| Occurs when a drag-and-drop operation is completed. | |
| phwidgets_event< Widget, Widget::Callbacks<>::IsDestroyed > | IsDestroyed |
| Occurs when the widget's resources are being released. | |
| phwidgets_event< Widget, Widget::Callbacks<>::Outbound > | Outbound |
| Occurs when you press the pointer button on the widget and then move out of the "hot spot" with the button still depressed. | |
| phwidgets_event< Widget, Widget::Callbacks<>::Realized > | Realized |
| Occurs when the widget is realized. | |
| phwidgets_event< Widget, Widget::Callbacks<>::Unrealized > | Unrealized |
| Occurs when the widget is unrealized. | |
A widget that invokes a callback after a given length of time.
A Timer widget invokes a callback after an initial and repeated time period, given in milliseconds. This widget is intended to provide a non-accurate, resourceless time base for your application. To disable the timer, set Timer::Interval to 0 or unrealize the widget.
|
explicit |
(constructor)
Constructs a Timer widget by ID.
| [in] | abn | ID given by PhAB to widget (like 'ABN_WIDGET_NAME'). |
|
explicit |
(constructor)
Constructs a Timer widget by pointer to widget.
| [in] | wdg | pointer to Photon widget. |
| PhWidgets::Timer::Timer | ( | const Timer & | other | ) |
| bool PhWidgets::Widget::operator< | ( | const Widget & | other | ) | const |
Compares Widgets.
Compares the Widgets by their Photon widget pointers.
| [in] | other | Widget whose contents to compare. |
| Widget & PhWidgets::Widget::operator= | ( | PtWidget_t * | wdg | ) |
| bool PhWidgets::Widget::operator== | ( | const Widget & | other | ) | const |
Compares Widgets.
Compares the Widgets by their Photon widget pointers.
| [in] | other | Widget whose contents to compare. |
| WidgetResourcesSingleton PhWidgets::Timer::resource |
Resources of the Timer.