summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/examples/elementary/slider_cxx_example.cc4
-rw-r--r--src/lib/efl/interfaces/efl_ui_range_interactive.eo7
-rw-r--r--src/lib/elementary/efl_ui_slider.c2
-rw-r--r--src/lib/elementary/efl_ui_slider.eo5
-rw-r--r--src/lib/elementary/efl_ui_slider_interval.c2
-rw-r--r--src/tests/elementary/efl_ui_test_slider.c4
6 files changed, 13 insertions, 11 deletions
diff --git a/src/examples/elementary/slider_cxx_example.cc b/src/examples/elementary/slider_cxx_example.cc
index d42f765..941ecc5 100644
--- a/src/examples/elementary/slider_cxx_example.cc
+++ b/src/examples/elementary/slider_cxx_example.cc
@@ -72,11 +72,11 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
72 { std::cout << "Changed to " << obj.range_value_get() << std::endl; } 72 { std::cout << "Changed to " << obj.range_value_get() << std::endl; }
73 , std::placeholders::_1); 73 , std::placeholders::_1);
74 74
75 auto steady = std::bind ( [] (efl::ui::Slider obj) 75 auto steady = std::bind ( [] (efl::ui::Range_Interactive obj)
76 { std::cout << "Steady to " << obj.range_value_get() << std::endl; } 76 { std::cout << "Steady to " << obj.range_value_get() << std::endl; }
77 , std::placeholders::_1); 77 , std::placeholders::_1);
78 78
79 efl::eo::downcast<efl::ui::Range_Display>(sl7).changed_event_cb_add(changed); 79 efl::eo::downcast<efl::ui::Range_Display>(sl7).changed_event_cb_add(changed);
80 sl7.steady_event_cb_add(steady); 80 efl::eo::downcast<efl::ui::Range_Interactive>(sl7).steady_event_cb_add(steady);
81} 81}
82EFL_MAIN() 82EFL_MAIN()
diff --git a/src/lib/efl/interfaces/efl_ui_range_interactive.eo b/src/lib/efl/interfaces/efl_ui_range_interactive.eo
index 817178c..3bea8ab 100644
--- a/src/lib/efl/interfaces/efl_ui_range_interactive.eo
+++ b/src/lib/efl/interfaces/efl_ui_range_interactive.eo
@@ -23,4 +23,11 @@ interface @beta Efl.Ui.Range_Interactive extends Efl.Ui.Range_Display
23 } 23 }
24 } 24 }
25 } 25 }
26 events {
27 steady: void; [[Called when the widget's value has changed and has remained unchanged for 0.2s.
28 This allows filtering out unwanted "noise" from the widget if you are only
29 interested in its final position.
30 Use this event instead of @[Efl.Ui.Range_Display.changed] if you are going to perform a costly operation
31 on its handler. ]]
32 }
26} 33}
diff --git a/src/lib/elementary/efl_ui_slider.c b/src/lib/elementary/efl_ui_slider.c
index 50a9fab..8a98e9b 100644
--- a/src/lib/elementary/efl_ui_slider.c
+++ b/src/lib/elementary/efl_ui_slider.c
@@ -34,7 +34,7 @@ _delay_change(void *data)
34 EFL_UI_SLIDER_DATA_GET(data, sd); 34 EFL_UI_SLIDER_DATA_GET(data, sd);
35 35
36 sd->delay = NULL; 36 sd->delay = NULL;
37 efl_event_callback_call(data, EFL_UI_SLIDER_EVENT_STEADY, NULL); 37 efl_event_callback_call(data, EFL_UI_RANGE_EVENT_STEADY, NULL);
38 38
39 if (_elm_config->atspi_mode) 39 if (_elm_config->atspi_mode)
40 efl_access_value_changed_signal_emit(data); 40 efl_access_value_changed_signal_emit(data);
diff --git a/src/lib/elementary/efl_ui_slider.eo b/src/lib/elementary/efl_ui_slider.eo
index 480c707..0a9c980 100644
--- a/src/lib/elementary/efl_ui_slider.eo
+++ b/src/lib/elementary/efl_ui_slider.eo
@@ -20,11 +20,6 @@ class @beta Efl.Ui.Slider extends Efl.Ui.Layout_Base implements Efl.Ui.Range_Int
20 Efl.Access.Widget.Action.elm_actions { get; } 20 Efl.Access.Widget.Action.elm_actions { get; }
21 } 21 }
22 events { 22 events {
23 steady: void; [[Called when the slider position has changed and has remained unchanged for 0.2s.
24 This allows filtering out unwanted "noise" from the slider signal if you are only
25 interested in the final position of the slider.
26 Use this signal instead of @[Efl.Ui.Range_Display.changed] if you are going to perform a costly operation
27 on its handler.]]
28 slider,drag,start: void; [[Called when a slider drag operation has started. This means a $press event 23 slider,drag,start: void; [[Called when a slider drag operation has started. This means a $press event
29 has been received on the slider thumb but not the $unpress.]] 24 has been received on the slider thumb but not the $unpress.]]
30 slider,drag,stop: void; [[Called when a slider drag operation has finished. This means an $unpress event 25 slider,drag,stop: void; [[Called when a slider drag operation has finished. This means an $unpress event
diff --git a/src/lib/elementary/efl_ui_slider_interval.c b/src/lib/elementary/efl_ui_slider_interval.c
index 77f543a..731bbe9 100644
--- a/src/lib/elementary/efl_ui_slider_interval.c
+++ b/src/lib/elementary/efl_ui_slider_interval.c
@@ -22,7 +22,7 @@ _delay_change(void *data)
22 EFL_UI_SLIDER_INTERVAL_DATA_GET(data, pd); 22 EFL_UI_SLIDER_INTERVAL_DATA_GET(data, pd);
23 23
24 pd->delay = NULL; 24 pd->delay = NULL;
25 efl_event_callback_call(data, EFL_UI_SLIDER_EVENT_STEADY, NULL); 25 efl_event_callback_call(data, EFL_UI_RANGE_EVENT_STEADY, NULL);
26 26
27 if (_elm_config->atspi_mode) 27 if (_elm_config->atspi_mode)
28 efl_access_value_changed_signal_emit(data); 28 efl_access_value_changed_signal_emit(data);
diff --git a/src/tests/elementary/efl_ui_test_slider.c b/src/tests/elementary/efl_ui_test_slider.c
index 39b11b5..a891841 100644
--- a/src/tests/elementary/efl_ui_test_slider.c
+++ b/src/tests/elementary/efl_ui_test_slider.c
@@ -27,7 +27,7 @@ EFL_START_TEST(efl_ui_test_slider_events)
27 efl_gfx_entity_size_set(win, EINA_SIZE2D(400, 100)); 27 efl_gfx_entity_size_set(win, EINA_SIZE2D(400, 100));
28 slider = efl_add(EFL_UI_SLIDER_CLASS, win, 28 slider = efl_add(EFL_UI_SLIDER_CLASS, win,
29 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, slider_changed, NULL), 29 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, slider_changed, NULL),
30 efl_event_callback_add(efl_added, EFL_UI_SLIDER_EVENT_STEADY, slider_changed, NULL), 30 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_STEADY, slider_changed, NULL),
31 efl_gfx_entity_size_set(efl_added, EINA_SIZE2D(400, 100)) 31 efl_gfx_entity_size_set(efl_added, EINA_SIZE2D(400, 100))
32 ); 32 );
33 33
@@ -61,7 +61,7 @@ EFL_START_TEST(efl_ui_test_slider_step)
61 efl_gfx_entity_size_set(win, EINA_SIZE2D(400, 100)); 61 efl_gfx_entity_size_set(win, EINA_SIZE2D(400, 100));
62 slider = efl_add(EFL_UI_SLIDER_CLASS, win, 62 slider = efl_add(EFL_UI_SLIDER_CLASS, win,
63 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, slider_changed, NULL), 63 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_CHANGED, slider_changed, NULL),
64 efl_event_callback_add(efl_added, EFL_UI_SLIDER_EVENT_STEADY, slider_changed, NULL), 64 efl_event_callback_add(efl_added, EFL_UI_RANGE_EVENT_STEADY, slider_changed, NULL),
65 efl_gfx_entity_size_set(efl_added, EINA_SIZE2D(400, 100)) 65 efl_gfx_entity_size_set(efl_added, EINA_SIZE2D(400, 100))
66 ); 66 );
67 efl_ui_range_limits_set(slider, 0, 100); 67 efl_ui_range_limits_set(slider, 0, 100);