5 public class Spinner : Layout
8 double _maximum = 100.0;
10 Interop.SmartEvent _changed;
11 Interop.SmartEvent _delayedChanged;
13 public Spinner(EvasObject parent) : base(parent)
15 _changed = new Interop.SmartEvent(this, Handle, "changed");
16 _changed.On += (s, e) => ValueChanged?.Invoke(this, EventArgs.Empty);
18 _delayedChanged = new Interop.SmartEvent(this, Handle, "delay,changed");
19 _delayedChanged.On += (s, e) => DelayedValueChanged?.Invoke(this, EventArgs.Empty);
22 public event EventHandler ValueChanged;
24 public event EventHandler DelayedValueChanged;
26 public string LabelFormat
30 return Interop.Elementary.elm_spinner_label_format_get(Handle);
34 Interop.Elementary.elm_spinner_label_format_set(Handle, value);
47 Interop.Elementary.elm_spinner_min_max_set(Handle, _minimum, _maximum);
60 Interop.Elementary.elm_spinner_min_max_set(Handle, _minimum, _maximum);
68 return Interop.Elementary.elm_spinner_step_get(Handle);
72 Interop.Elementary.elm_spinner_step_set(Handle, value);
80 return Interop.Elementary.elm_spinner_value_get(Handle);
84 Interop.Elementary.elm_spinner_value_set(Handle, value);
88 public double Interval
92 return Interop.Elementary.elm_spinner_interval_get(Handle);
96 Interop.Elementary.elm_spinner_interval_set(Handle, value);
100 public double RoundBase
104 return Interop.Elementary.elm_spinner_base_get(Handle);
108 Interop.Elementary.elm_spinner_base_set(Handle, value);
112 public int RoundValue
116 return Interop.Elementary.elm_spinner_round_get(Handle);
120 Interop.Elementary.elm_spinner_round_set(Handle, value);
124 public bool IsWrapEnabled
128 return Interop.Elementary.elm_spinner_wrap_get(Handle);
132 Interop.Elementary.elm_spinner_wrap_set(Handle, value);
136 public bool IsEditable
140 return Interop.Elementary.elm_spinner_editable_get(Handle);
144 Interop.Elementary.elm_spinner_editable_set(Handle, value);
149 public void AddSpecialValue(double value, string label)
151 Interop.Elementary.elm_spinner_special_value_add(Handle, value, label);
154 public void RemoveSpecialValue(double value)
156 Interop.Elementary.elm_spinner_special_value_del(Handle, value);
159 public string GetSpecialValue(double value)
161 return Interop.Elementary.elm_spinner_special_value_get(Handle, value);
164 protected override IntPtr CreateHandle(EvasObject parent)
166 return Interop.Elementary.elm_spinner_add(parent);