summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2019-07-31 17:49:44 +0200
committerCedric BAIL <cedric.bail@free.fr>2019-08-01 14:36:48 -0700
commit45b763a2dc2a3ba773353d5be17722aad86fea7c (patch)
treeeec1fe162108fffb7b25101736849cfc96f107b8
parent010f81357297e5473244c5ef42cb56a5f2f0fa16 (diff)
efl_ui_spin_button: use the newly emitted event from range_interactive
this event is not also in range_interactive, so better use this. ref T8097 Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es> Differential Revision: https://phab.enlightenment.org/D9459
-rw-r--r--src/bin/elementary/test_ui_spin_button.c2
-rw-r--r--src/lib/elementary/efl_ui_spin_button.c2
-rw-r--r--src/lib/elementary/efl_ui_spin_button.eo3
-rw-r--r--src/tests/elementary/efl_ui_test_spin_button.c6
4 files changed, 5 insertions, 8 deletions
diff --git a/src/bin/elementary/test_ui_spin_button.c b/src/bin/elementary/test_ui_spin_button.c
index 511c1d4..2bfb7b2 100644
--- a/src/bin/elementary/test_ui_spin_button.c
+++ b/src/bin/elementary/test_ui_spin_button.c
@@ -43,7 +43,7 @@ test_ui_spin_button(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *
43 efl_ui_range_step_set(efl_added, 2), 43 efl_ui_range_step_set(efl_added, 2),
44 efl_ui_spin_button_circulate_set(efl_added, EINA_TRUE), 44 efl_ui_spin_button_circulate_set(efl_added, EINA_TRUE),
45 efl_ui_spin_button_editable_set(efl_added, EINA_TRUE), 45 efl_ui_spin_button_editable_set(efl_added, EINA_TRUE),
46 efl_event_callback_add(efl_added, EFL_UI_SPIN_BUTTON_EVENT_DELAY_CHANGED,_spin_delay_changed_cb, NULL), 46 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_STEADY,_spin_delay_changed_cb, NULL),
47 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, _spin_changed_cb, NULL), 47 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, _spin_changed_cb, NULL),
48 efl_pack(bx, efl_added)); 48 efl_pack(bx, efl_added));
49 49
diff --git a/src/lib/elementary/efl_ui_spin_button.c b/src/lib/elementary/efl_ui_spin_button.c
index 1c64acf..553c363 100644
--- a/src/lib/elementary/efl_ui_spin_button.c
+++ b/src/lib/elementary/efl_ui_spin_button.c
@@ -116,7 +116,7 @@ _label_write(Evas_Object *obj)
116static Eina_Value 116static Eina_Value
117_delay_change_timer_cb(Eo *o, void *data EINA_UNUSED, const Eina_Value v) 117_delay_change_timer_cb(Eo *o, void *data EINA_UNUSED, const Eina_Value v)
118{ 118{
119 efl_event_callback_call(o, EFL_UI_SPIN_BUTTON_EVENT_DELAY_CHANGED, NULL); 119 efl_event_callback_call(o, EFL_UI_RANGE_EVENT_STEADY, NULL);
120 120
121 return v; 121 return v;
122} 122}
diff --git a/src/lib/elementary/efl_ui_spin_button.eo b/src/lib/elementary/efl_ui_spin_button.eo
index bf68be8..2affb77 100644
--- a/src/lib/elementary/efl_ui_spin_button.eo
+++ b/src/lib/elementary/efl_ui_spin_button.eo
@@ -73,7 +73,4 @@ class @beta Efl.Ui.Spin_Button extends Efl.Ui.Spin implements Efl.Ui.Focus.Compo
73 Efl.Access.Value.increment { get; } 73 Efl.Access.Value.increment { get; }
74 Efl.Access.Widget.Action.elm_actions { get; } 74 Efl.Access.Widget.Action.elm_actions { get; }
75 } 75 }
76 events {
77 delay,changed: void; [[Called when spin delay is changed.]]
78 }
79} 76}
diff --git a/src/tests/elementary/efl_ui_test_spin_button.c b/src/tests/elementary/efl_ui_test_spin_button.c
index e3a5ed6..d44f817 100644
--- a/src/tests/elementary/efl_ui_test_spin_button.c
+++ b/src/tests/elementary/efl_ui_test_spin_button.c
@@ -89,7 +89,7 @@ EFL_START_TEST (spin_value_inc)
89 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed); 89 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed);
90 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached); 90 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached);
91 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached); 91 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached);
92 efl_event_callback_add(spin, EFL_UI_SPIN_BUTTON_EVENT_DELAY_CHANGED, _set_flag_quit, &delay_changed); 92 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_STEADY, _set_flag_quit, &delay_changed);
93 93
94 click_spin_part(spin, "efl.inc_button"); 94 click_spin_part(spin, "efl.inc_button");
95 95
@@ -114,7 +114,7 @@ EFL_START_TEST (spin_value_inc_max)
114 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed); 114 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed);
115 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached); 115 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached);
116 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached); 116 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached);
117 efl_event_callback_add(spin, EFL_UI_SPIN_BUTTON_EVENT_DELAY_CHANGED, _set_flag_quit, &delay_changed); 117 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_STEADY, _set_flag_quit, &delay_changed);
118 118
119 click_spin_part(spin, "efl.inc_button"); 119 click_spin_part(spin, "efl.inc_button");
120 120
@@ -139,7 +139,7 @@ EFL_START_TEST (spin_value_dec_min)
139 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed); 139 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_CHANGED, _set_flag, &changed);
140 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached); 140 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MIN_REACHED, _set_flag, &min_reached);
141 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached); 141 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_MAX_REACHED, _set_flag, &max_reached);
142 efl_event_callback_add(spin, EFL_UI_SPIN_BUTTON_EVENT_DELAY_CHANGED, _set_flag_quit, &delay_changed); 142 efl_event_callback_add(spin, EFL_UI_RANGE_EVENT_STEADY, _set_flag_quit, &delay_changed);
143 143
144 click_spin_part(spin, "efl.dec_button"); 144 click_spin_part(spin, "efl.dec_button");
145 145