diff options
| author | Carl Hetherington <cth@carlh.net> | 2025-05-01 23:20:58 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-07-09 00:35:10 +0200 |
| commit | 81fea8d53c5e92be9b43d97005e88cd92fe9e85d (patch) | |
| tree | b08ff1aa88764385e0aeec19960ece6a01bc73d1 | |
| parent | debd1b7233cf56f5d79e1de0c993996e5b549a6d (diff) | |
Add SpinCtrl::{s,g}et().
| -rw-r--r-- | src/wx/dcpomatic_spin_ctrl.cc | 15 | ||||
| -rw-r--r-- | src/wx/dcpomatic_spin_ctrl.h | 3 |
2 files changed, 18 insertions, 0 deletions
diff --git a/src/wx/dcpomatic_spin_ctrl.cc b/src/wx/dcpomatic_spin_ctrl.cc index 70bd7e3f7..bb847043b 100644 --- a/src/wx/dcpomatic_spin_ctrl.cc +++ b/src/wx/dcpomatic_spin_ctrl.cc @@ -42,3 +42,18 @@ SpinCtrl::SpinCtrl (wxWindow* parent, int width) Bind (wxEVT_TEXT_ENTER, boost::bind<void>(enter, _1)); } + +void +SpinCtrl::set(int n) +{ + SetValue(n); +} + + +int +SpinCtrl::get() const +{ + return GetValue(); +} + + diff --git a/src/wx/dcpomatic_spin_ctrl.h b/src/wx/dcpomatic_spin_ctrl.h index 4a673ff93..4e371682e 100644 --- a/src/wx/dcpomatic_spin_ctrl.h +++ b/src/wx/dcpomatic_spin_ctrl.h @@ -34,6 +34,9 @@ class SpinCtrl : public wxSpinCtrl { public: SpinCtrl (wxWindow* parent, int width); + + void set(int n); + int get() const; }; |
