Photon microGUI widgets library 0.6.0
NumericInteger.h
1#ifndef PHWIDGETS_NUMERIC_INTEGER_H
2#define PHWIDGETS_NUMERIC_INTEGER_H
3
4#include <photon/PtNumericInteger.h>
5
6#include "./Numeric.h"
7
8
9namespace PhWidgets
10{
17
20 class NumericInteger: //TODO::implement all properties
21 public Numeric
22 {
23 public:
24
26 struct ThisArgs
27 {
29 struct ArgInt
30 {
32
42 {
43 numeric_increment = Pt_ARG_NUMERIC_INCREMENT,
44 numeric_max = Pt_ARG_NUMERIC_MAX,
45 numeric_min = Pt_ARG_NUMERIC_MIN,
46 numeric_value = Pt_ARG_NUMERIC_VALUE
47 };
48 };
49
50 };
51
54 {
56 struct Callback
57 {
59
68 {
69 numeric_changed = Pt_CB_NUMERIC_CHANGED
70 };
71 };
72 };
73
75 struct ArgInt:
76 public ThisArgs::ArgInt
77 { };
78
80 struct Callback:
81 public ArgumentsEx<ThisCallbacks::Callback>,
83 {
85 };
86
88 struct Arguments:
89 public ArgInt,
91 { };
92
94 struct Callbacks:
95 public Callback,
97 { };
98
99
100 protected:
101 typedef ResourceFrom<Numeric::WidgetResourcesSingleton>::
102 Define::Scalar<ThisArgs::ArgInt::eArgInt, int>::
103
104 Define::Link<ThisCallbacks::Callback::eCallback, PtCallback_t*>::
105
106 resource_type WidgetResourcesSingleton;
107
108 virtual void check();
109
110
111 public:
113
117 WidgetResourcesSingleton resource;
118
120
124 explicit NumericInteger(int abn);
125
127
132
134
139
141
146
149
150 phproperty<int>::bind<NumericInteger, ArgInt::eArgInt, Arguments::numeric_value> Value;
151 phproperty<int>::bind<NumericInteger, ArgInt::eArgInt, Arguments::numeric_max> MaxValue;
152 phproperty<int>::bind<NumericInteger, ArgInt::eArgInt, Arguments::numeric_min> MinValue;
154
156 };
157
158
159} // namespace PhWidgets
160
161
162#endif // PHWIDGETS_NUMERIC_INTEGER_H
A superclass for numeric widgets.
Definition: Numeric.h:28
Integer numeric widget.
Definition: NumericInteger.h:22
NumericInteger(const NumericInteger &other)
(copy constructor)
NumericInteger & operator=(const NumericInteger &other)
Assigns value in NumericInteger widget.
NumericInteger(PtWidget_t *wdg)
(constructor)
NumericInteger(int abn)
(constructor)
WidgetResourcesSingleton resource
Resources of the NumericInteger.
Definition: NumericInteger.h:117
An event, which raise a notification to registered subscribers (event handlers) that something of int...
Definition: Widget.h:132
The main namespace for all widgets.
Definition: Basic.h:11
Contains resource IDs for Basic callbacks.
Definition: Basic.h:217
Contains resource IDs for callbacks of type PtCallback_t.
Definition: Container.h:288
eCallback
Resource IDs for Container arguments of type PtCallback_t.
Definition: Container.h:223
Contains resource IDs for all Numeric arguments.
Definition: Numeric.h:133
Contains resource IDs for arguments of type int.
Definition: NumericInteger.h:77
Contains resource IDs for all NumericInteger arguments.
Definition: NumericInteger.h:91
Contains resource IDs for callbacks of type PtCallback_t.
Definition: NumericInteger.h:83
Contains resource IDs for all NumericInteger callbacks.
Definition: NumericInteger.h:97
Contains resource IDs for NumericInteger arguments of type int.
Definition: NumericInteger.h:30
eArgInt
Resource IDs for NumericInteger arguments of type long.
Definition: NumericInteger.h:42
Contains resource IDs for NumericInteger arguments.
Definition: NumericInteger.h:27
Contains resource IDs for NumericInteger callbacks of type PtCallback_t.
Definition: NumericInteger.h:57
eCallback
Resource IDs for NumericInteger arguments of type PtCallback_t.
Definition: NumericInteger.h:68
Contains resource IDs for NumericInteger callbacks.
Definition: NumericInteger.h:54