From: Pawel Kurowski
Date: Mon, 26 Feb 2018 16:08:41 +0000 (+0100)
Subject: Remove keyboardRootName2 hack.
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c04a7ecbffda8302e51aadd35dff2f4a44b2c5a5;p=platform%2Fcore%2Faccessibility%2Funiversal-switch.git
Remove keyboardRootName2 hack.
Application with empty name may be incorrectly recognized as keyboard,
what will lead to looping the search for the scanning context.
Change-Id: Icba02f8e5f3aee0d320120d4f6eac251414de9fc
---
diff --git a/src/NavigationInterface.cpp b/src/NavigationInterface.cpp
index 0d40b84a..9f007e4b 100644
--- a/src/NavigationInterface.cpp
+++ b/src/NavigationInterface.cpp
@@ -806,18 +806,19 @@ private:
}
AtspiAccessiblePtr root, keyboardRoot;
UIElement::ApplicationCategory application = UIElement::ApplicationCategory::OTHER;
- static const std::string keyboardRootName1 = "ise-default";
- // TODO: remove keyboardRootName2, once app name patch will be merged and on image
- static const std::string keyboardRootName2 = "";
+ static const std::string keyboardRootName = "ise-default";
static const std::string homescreenRootName = "homescreen-efl";
for (auto pid : wins.all.pids) {
DEBUG("checking pid %d", pid);
auto ptr = wins.all.pidToAtspi[pid];
auto name = wins.all.names[ptr];
- if (pid == wins.all.ourPid && !wins.all.weHaveChildren) continue;
- if (name == keyboardRootName1 || name == keyboardRootName2) {
+ if (pid == wins.all.ourPid && !wins.all.weHaveChildren)
+ continue;
+ if (name == keyboardRootName) {
keyboardRoot = std::move(ptr);
- } else if (!root) {
+ continue;
+ }
+ if (!root) {
root = std::move(ptr);
if (name == homescreenRootName)
application = UIElement::ApplicationCategory::HOMESCREEN;