summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavi Artigas <xavierartigas@yahoo.es>2019-06-14 12:03:32 -0400
committerMike Blumenkrantz <zmike@samsung.com>2019-06-14 12:03:32 -0400
commitbc98c94dc9b1f41406870eca709a97ec63daf96c (patch)
treee2f6f05c747f0d9f4f0a42a4593894cea5e5b4b6
parent3a5f506b0e87d42a78a420b5a89936ad0deb04ba (diff)
Efl.Ui.Slider: Rename event delay,changed to steady
Summary: And update the docs to explain its purpose. Related to T7893 Test Plan: Everything builds and tests pass Reviewers: zmike, bu5hm4n Reviewed By: zmike Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9090
-rw-r--r--src/examples/elementary/slider_cxx_example.cc6
-rw-r--r--src/lib/elementary/efl_ui_slider.c2
-rw-r--r--src/lib/elementary/efl_ui_slider.eo14
-rw-r--r--src/lib/elementary/efl_ui_slider_interval.c2
-rw-r--r--src/lib/elementary/elm_slider.c2
5 files changed, 16 insertions, 10 deletions
diff --git a/src/examples/elementary/slider_cxx_example.cc b/src/examples/elementary/slider_cxx_example.cc
index 38e4b91700..37121240e1 100644
--- a/src/examples/elementary/slider_cxx_example.cc
+++ b/src/examples/elementary/slider_cxx_example.cc
@@ -70,11 +70,11 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
70 { std::cout << "Changed to " << obj.range_value_get() << std::endl; } 70 { std::cout << "Changed to " << obj.range_value_get() << std::endl; }
71 , std::placeholders::_1); 71 , std::placeholders::_1);
72 72
73 auto delay = std::bind ( [] (efl::ui::Slider obj) 73 auto steady = std::bind ( [] (efl::ui::Slider obj)
74 { std::cout << "Delay changed to " << obj.range_value_get() << std::endl; } 74 { std::cout << "Steady to " << obj.range_value_get() << std::endl; }
75 , std::placeholders::_1); 75 , std::placeholders::_1);
76 76
77 sl7.changed_event_cb_add(changed); 77 sl7.changed_event_cb_add(changed);
78 sl7.delay_changed_event_cb_add(delay); 78 sl7.steady_event_cb_add(steady);
79} 79}
80EFL_MAIN() 80EFL_MAIN()
diff --git a/src/lib/elementary/efl_ui_slider.c b/src/lib/elementary/efl_ui_slider.c
index 3e5ff63cbf..4977adec5a 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_DELAY_CHANGED, NULL); 37 efl_event_callback_call(data, EFL_UI_SLIDER_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 4b703a3bf7..e8d04b3ddb 100644
--- a/src/lib/elementary/efl_ui_slider.eo
+++ b/src/lib/elementary/efl_ui_slider.eo
@@ -20,9 +20,15 @@ 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 changed: void; [[Called when slider changed]] 23 changed: void; [[Called when the slider position has changed.]]
24 delay,changed: void; [[Called when delay changed]] 24 steady: void; [[Called when the slider position has changed and has remained unchanged for 0.2s.
25 slider,drag,start: void; [[Called when slider drag started]] 25 This allows filtering out unwanted "noise" from the slider signal if you are only
26 slider,drag,stop: void; [[Called when slider drag stopped]] 26 interested in the final position of the slider.
27 Use this signal instead of @[Efl.Ui.Slider.changed] if you are going to perform a costly operation
28 on its handler.]]
29 slider,drag,start: void; [[Called when a slider drag operation has started. This means a $press event
30 has been received on the slider thumb but not the $unpress.]]
31 slider,drag,stop: void; [[Called when a slider drag operation has finished. This means an $unpress event
32 has been received on the slider thumb.]]
27 } 33 }
28} 34}
diff --git a/src/lib/elementary/efl_ui_slider_interval.c b/src/lib/elementary/efl_ui_slider_interval.c
index 8256c7de22..0f0f9a5b8d 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_DELAY_CHANGED, NULL); 25 efl_event_callback_call(data, EFL_UI_SLIDER_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/lib/elementary/elm_slider.c b/src/lib/elementary/elm_slider.c
index fe148057c4..927c6f8860 100644
--- a/src/lib/elementary/elm_slider.c
+++ b/src/lib/elementary/elm_slider.c
@@ -62,7 +62,7 @@ _delay_change(void *data)
62 ELM_SLIDER_DATA_GET(data, sd); 62 ELM_SLIDER_DATA_GET(data, sd);
63 63
64 sd->delay = NULL; 64 sd->delay = NULL;
65 efl_event_callback_legacy_call(data, EFL_UI_SLIDER_EVENT_DELAY_CHANGED, NULL); 65 efl_event_callback_legacy_call(data, EFL_UI_SLIDER_EVENT_STEADY, NULL);
66 66
67 if (_elm_config->atspi_mode) 67 if (_elm_config->atspi_mode)
68 efl_access_value_changed_signal_emit(data); 68 efl_access_value_changed_signal_emit(data);