-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathNumericbutton.hpp
More file actions
62 lines (51 loc) · 1.56 KB
/
Numericbutton.hpp
File metadata and controls
62 lines (51 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//
// AmigaOS MUI C++ wrapper
//
// (c) 2022-2026 TDolphin
//
#pragma once
#include "Slider.hpp"
namespace MUI
{
/// @brief Numericbutton class wrapper.
/// Space-saving slider variant with no extra class-specific API. Use Numeric class
/// attributes and methods to configure and control its value behaviour.
class Numericbutton : public Slider
{
public:
explicit Numericbutton(Object *pMuiObject)
: Slider(pMuiObject)
{
}
Numericbutton(const Root &root)
: Slider(root.muiObject())
{
}
// instanceOf
const static std::string className;
static inline bool instanceOf(Object *pMuiObject)
{
return MUI::instanceOf(pMuiObject, className.c_str());
}
static inline bool instanceOf(const Root &object)
{
return MUI::instanceOf(object.muiObject(), className.c_str());
}
};
template <typename T, typename U> class NumericbuttonBuilderTemplate : public SliderBuilderTemplate<T, U>
{
public:
NumericbuttonBuilderTemplate(const std::string &uniqueId = MUI::EmptyUniqueId, const std::string &muiClassName = MUIC_Numericbutton)
: SliderBuilderTemplate<T, U>(uniqueId, muiClassName)
{
}
};
class NumericbuttonBuilder : public NumericbuttonBuilderTemplate<NumericbuttonBuilder, Numericbutton>
{
public:
NumericbuttonBuilder();
};
}
#define MUI_NUMERICBUTTON_TPP_INCLUDE
#include "Numericbutton.tpp"
#undef MUI_NUMERICBUTTON_TPP_INCLUDE