summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Kurzberg <i.kurtsberg@samsung.com>2017-10-27 16:59:45 +0300
committerNilesh Trimbake <t.shripati@samsung.com>2018-03-16 15:34:33 +0530
commitf52dba6f1ee544a0a49a53ae83a4183f2538acc9 (patch)
tree507b66d3e63015095278958b553ded64f5c13e69
parent88bc7672619b5bb23071cd76d100e8ef79ce433a (diff)
downloadalarm-f52dba6f1ee544a0a49a53ae83a4183f2538acc9.tar.gz
alarm-f52dba6f1ee544a0a49a53ae83a4183f2538acc9.tar.bz2
alarm-f52dba6f1ee544a0a49a53ae83a4183f2538acc9.zip
Fix screen reader gestures for Snooze and Dismiss button in Alert.
Change-Id: Ic85c8401b09dfe742a7f9ca6f22bb20ba354d92a Signed-off-by: Eugene Kurzberg <i.kurtsberg@samsung.com>
-rw-r--r--alarm-app/inc/Alert/AlertView.h2
-rw-r--r--alarm-app/src/Alert/AlertView.cpp15
2 files changed, 2 insertions, 15 deletions
diff --git a/alarm-app/inc/Alert/AlertView.h b/alarm-app/inc/Alert/AlertView.h
index b077020..5b13d8b 100644
--- a/alarm-app/inc/Alert/AlertView.h
+++ b/alarm-app/inc/Alert/AlertView.h
@@ -59,8 +59,6 @@ namespace Alert
void onSnoozeClicked(Evas_Object *button, void *eventInfo);
void onFocusChanged(sound_stream_focus_state_e state);
static void onButtonPressed(const char *signal, Evas_Object *button, void *eventInfo);
- static Eina_Bool onButtonActivated(Evas_Object *button, Evas_Object *obj,
- Elm_Access_Action_Info *accessInfo);
static Eina_Bool onFeedbackTimer(void *data);
Evas_Object *m_DismissButton;
diff --git a/alarm-app/src/Alert/AlertView.cpp b/alarm-app/src/Alert/AlertView.cpp
index b418014..99ab792 100644
--- a/alarm-app/src/Alert/AlertView.cpp
+++ b/alarm-app/src/Alert/AlertView.cpp
@@ -165,7 +165,7 @@ Evas_Object *AlertView::createButton(Evas_Object *parent, const char *iconPath,
Evas_Object *AlertView::createButtonAccessObject(Evas_Object *button,
const char *name, const char *description)
{
- Evas_Object *obj = Ui::createPartAccessObject(button, "elm.swallow.content");
+ Evas_Object *obj = Ui::createPartAccessObject(button, "elm.swallow.content");
elm_atspi_accessible_translation_domain_set(obj, TEXT_DOMAIN);
elm_atspi_accessible_name_set(obj, name);
elm_atspi_accessible_description_set(obj, description);
@@ -173,8 +173,7 @@ Evas_Object *AlertView::createButtonAccessObject(Evas_Object *button,
ELM_ACCESSIBLE_READING_INFO_TYPE_NAME |
ELM_ACCESSIBLE_READING_INFO_TYPE_DESCRIPTION));
elm_atspi_accessible_role_set(button, ELM_ATSPI_ROLE_REDUNDANT_OBJECT);
- elm_access_action_cb_set(obj, ELM_ACCESS_ACTION_SCROLL,
- (Elm_Access_Action_Cb) &AlertView::onButtonActivated, button);
+ elm_atspi_accessible_attribute_append(obj, "gesture_required", "scroll");
return obj;
}
@@ -256,16 +255,6 @@ void AlertView::onButtonPressed(const char *signal, Evas_Object *button, void *e
elm_layout_signal_emit(elm_object_parent_widget_get(button), signal, "");
}
-Eina_Bool AlertView::onButtonActivated(Evas_Object *button, Evas_Object *obj,
- Elm_Access_Action_Info *accessInfo)
-{
- /* Activate and expand the button by sending two "press" signals
- as if the bezel was rotated twice. */
- elm_layout_signal_emit(button, SIGNAL_BUTTON_PRESS, "");
- elm_layout_signal_emit(button, SIGNAL_BUTTON_PRESS, "");
- return EINA_TRUE;
-}
-
Eina_Bool AlertView::onFeedbackTimer(void *data)
{
feedback_play(FEEDBACK_PATTERN_WAKEUP);