From: Artur Świgoń Date: Thu, 7 Jul 2022 10:54:38 +0000 (+0200) Subject: [AT-SPI] Suppress some events in Widget windows X-Git-Tag: dali_2.1.31~9^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F86%2F277486%2F2;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git [AT-SPI] Suppress some events in Widget windows While the Widget is technically a window in DALi, it should not be seen as a window by AT clients such as the Screen Reader, i.e. it should not grab and narrow down the navigation context. Suppressing window events and some state events (notably, State::SHOWING, however the API offers an all-or-nothing granularity only) is necessary to achieve this goal. Change-Id: I0873751f025bbdd321aa26444c070bf064c0ce3f --- diff --git a/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp b/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp index 0f762bb..5e03ef1 100644 --- a/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp +++ b/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp @@ -19,11 +19,13 @@ #include // EXTERNAL INCLUDES +#include #include #include // INTERNAL INCLUDES #include +#include namespace Dali { @@ -75,6 +77,11 @@ void WidgetImplTizen::SetInformation(Dali::Window window, const std::string& wid auto preferredBusName = Bridge::MakeBusNameForWidget(widgetId); Bridge::GetCurrentBridge()->SetPreferredBusName(preferredBusName); + + // Widget should not send window events (which could narrow down the navigation context) + auto& suppressedEvents = Accessibility::Accessible::Get(window.GetRootLayer())->GetSuppressedEvents(); + suppressedEvents[Accessibility::AtspiEvent::STATE_CHANGED] = true; + suppressedEvents[Accessibility::AtspiEvent::WINDOW_CHANGED] = true; } Dali::Window WidgetImplTizen::GetWindow() const