From: sungwook79.park Date: Mon, 23 Oct 2017 04:41:41 +0000 (+0900) Subject: Support screen reader X-Git-Tag: accepted/tizen/unified/20171024.071442~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c3fe22e4247c789ff4f999895078642887145767;p=platform%2Fcore%2Fuifw%2Finputdelegator.git Support screen reader Change-Id: Ib7757d4686e67d1da49ff390ff193217a7032d7e Signed-off-by: sungwook79.park --- diff --git a/src/w-input-selector.cpp b/src/w-input-selector.cpp index 23db269..51a15af 100755 --- a/src/w-input-selector.cpp +++ b/src/w-input-selector.cpp @@ -305,13 +305,22 @@ static Evas_Object * __ise_gl_2button_content_get(void *data, Evas_Object *obj, if (!strcmp(first_input_type, "input_voice")) { elm_object_style_set(btn, "ime_button_stt"); path_ic = path + "images/w_mode_stt_ic.png"; + evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(first_input_type, "input_emoticon")) { elm_object_style_set(btn, "ime_button_emoticon"); path_ic = path + "images/Delta_w_mode_emoticon_ic.png"; + evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(first_input_type, "input_keyboard")) { elm_object_style_set(btn, "ime_button_keyboard"); path_ic = path + "images/w_mode_keyboard_ic.png"; evas_object_propagate_events_set(btn, EINA_FALSE); + evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); @@ -321,13 +330,22 @@ static Evas_Object * __ise_gl_2button_content_get(void *data, Evas_Object *obj, if (!strcmp(second_input_type, "input_voice")) { elm_object_style_set(btn, "ime_button_stt"); path_ic = path + "images/w_mode_stt_ic.png"; + evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(second_input_type, "input_emoticon")) { elm_object_style_set(btn, "ime_button_emoticon"); path_ic = path + "images/Delta_w_mode_emoticon_ic.png"; + evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(second_input_type, "input_keyboard")) { elm_object_style_set(btn, "ime_button_keyboard"); path_ic = path + "images/w_mode_keyboard_ic.png"; evas_object_propagate_events_set(btn, EINA_FALSE); + evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); @@ -344,21 +362,33 @@ static Evas_Object * __ise_gl_2button_content_get(void *data, Evas_Object *obj, evas_object_layer_set(btn, 32000); if (!strcmp(first_input_type, "input_voice")) { evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(first_input_type, "input_emoticon")) { evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(first_input_type, "input_keyboard")) { evas_object_propagate_events_set(btn, EINA_FALSE); evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } } else if (!strcmp(part, "elm.icon.2.touch_area")){ evas_object_layer_set(btn, 32000); if (!strcmp(second_input_type, "input_voice")) { evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(second_input_type, "input_emoticon")) { evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(second_input_type, "input_keyboard")) { evas_object_propagate_events_set(btn, EINA_FALSE); evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } } return btn; @@ -392,6 +422,9 @@ static Evas_Object * __ise_gl_3button_content_get(void *data, Evas_Object *obj, elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); + evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(part, "elm.icon.2")){ elm_object_style_set(btn, "ime_button_emoticon"); @@ -399,6 +432,9 @@ static Evas_Object * __ise_gl_3button_content_get(void *data, Evas_Object *obj, elm_image_file_set(ic, path_ic.c_str(), NULL); elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); + evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(part, "elm.icon.3")){ elm_object_style_set(btn, "ime_button_keyboard"); @@ -407,6 +443,9 @@ static Evas_Object * __ise_gl_3button_content_get(void *data, Evas_Object *obj, elm_object_content_set(btn, ic); evas_object_layer_set(btn, 32000); evas_object_propagate_events_set(btn, EINA_FALSE); + evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } return btn; @@ -419,14 +458,20 @@ static Evas_Object * __ise_gl_3button_content_get(void *data, Evas_Object *obj, if (!strcmp(part, "elm.icon.1.touch_area")) { evas_object_layer_set(btn, 32000); evas_object_smart_callback_add(btn, "clicked", _stt_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_IME_MBODY_VOICE_INPUT"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(part, "elm.icon.2.touch_area")){ evas_object_layer_set(btn, 32000); evas_object_smart_callback_add(btn, "clicked", _emoticon_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_HEADER_EMOTICON"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } else if (!strcmp(part, "elm.icon.3.touch_area")) { evas_object_layer_set(btn, 32000); evas_object_propagate_events_set(btn, EINA_FALSE); evas_object_smart_callback_add(btn, "clicked", _keyboard_clicked_cb, app_data); + elm_atspi_accessible_name_set(btn, "IDS_COM_OPT_KEYBOARD"); + elm_atspi_accessible_translation_domain_set(btn, PACKAGE); } return btn;