summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2019-07-02 21:05:07 +0200
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2019-07-03 12:22:17 -0400
commitebf39e9fd7ba054f49031f7f4162ced8c63b1d22 (patch)
tree048afd936c66d6cb5e20bbe393a95857e7b1466a
parent8a0cad643597b8741e5b8b1c7bc3ecfff671aeed (diff)
efl_ui_check/radio: restore legacy behaviour
from now on, the "changed" signal is only emitted on radio/check buttons when the user interacted with this object. NOT due to the API change. However, in the eo-api the event is emitted all the time, due to user interaction, AND due to API interaction. ref T8042
-rw-r--r--src/lib/elementary/efl_ui_check.c6
-rw-r--r--src/lib/elementary/efl_ui_radio.c1
2 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/elementary/efl_ui_check.c b/src/lib/elementary/efl_ui_check.c
index 7b8e4026b6..9f575621ff 100644
--- a/src/lib/elementary/efl_ui_check.c
+++ b/src/lib/elementary/efl_ui_check.c
@@ -96,6 +96,8 @@ _activate(Evas_Object *obj)
96 // "elm,state,check,on" or "elm,state,check,off" for legacy 96 // "elm,state,check,on" or "elm,state,check,off" for legacy
97 // "efl,state,check,on" or "efl,state,check,off" for eo-api 97 // "efl,state,check,on" or "efl,state,check,off" for eo-api
98 efl_ui_check_selected_set(obj, !efl_ui_check_selected_get(obj)); 98 efl_ui_check_selected_set(obj, !efl_ui_check_selected_get(obj));
99 if (elm_widget_is_legacy(obj))
100 evas_object_smart_callback_call(obj, "changed", NULL);
99 101
100 if (_elm_config->atspi_mode) 102 if (_elm_config->atspi_mode)
101 efl_access_state_changed_signal_emit(obj, 103 efl_access_state_changed_signal_emit(obj,
@@ -291,9 +293,7 @@ _efl_ui_check_selected_set(Eo *obj, Efl_Ui_Check_Data *pd, Eina_Bool value)
291 293
292 pd->selected = value; 294 pd->selected = value;
293 295
294 if (elm_widget_is_legacy(obj)) 296 if (!elm_widget_is_legacy(obj))
295 evas_object_smart_callback_call(obj, "changed", NULL);
296 else
297 efl_event_callback_call(obj, EFL_UI_CHECK_EVENT_SELECTED_CHANGED, &pd->selected); 297 efl_event_callback_call(obj, EFL_UI_CHECK_EVENT_SELECTED_CHANGED, &pd->selected);
298} 298}
299 299
diff --git a/src/lib/elementary/efl_ui_radio.c b/src/lib/elementary/efl_ui_radio.c
index c38c9fadc7..edbc14844f 100644
--- a/src/lib/elementary/efl_ui_radio.c
+++ b/src/lib/elementary/efl_ui_radio.c
@@ -139,6 +139,7 @@ _activate(Evas_Object *obj)
139 if (_elm_config->access_mode) 139 if (_elm_config->access_mode)
140 _elm_access_say(E_("State: On")); 140 _elm_access_say(E_("State: On"));
141 } 141 }
142 evas_object_smart_callback_call(obj, "changed", NULL);
142 } 143 }
143 else 144 else
144 { 145 {