Aurum: add updateApplication for updateXpath
authorHosang Kim <hosang12.kim@samsung.com>
Mon, 25 Mar 2024 11:15:31 +0000 (20:15 +0900)
committerHosang Kim <hosang12.kim@samsung.com>
Thu, 28 Mar 2024 11:27:49 +0000 (20:27 +0900)
Change-Id: I00b3827eccfe33ad97fd85a7abd4ae19cb4853b9

libaurum/src/Comparer.cc
libaurum/src/Impl/Accessibility/AtspiAccessibleNode.cc

index a370772..6f43318 100644 (file)
@@ -63,6 +63,8 @@ void Comparer::findObjects(std::vector<std::shared_ptr<AccessibleNode>> &ret,
     }
 
     if (selector->mMatchXPath) {
+        root->updateApplication();
+        root->updatePid();
         std::string pkg = root->getPkg();
         int pid = root->getPid();
         auto XMLDoc = AccessibleWatcher::getInstance()->getXMLDoc({pkg, pid});
index b9071bd..29ff6dc 100644 (file)
@@ -263,6 +263,7 @@ void AtspiAccessibleNode::updateExtents()
 
 void AtspiAccessibleNode::updateXPath()
 {
+    updateApplication();
     updatePid();
     auto XMLDoc = AccessibleWatcher::getInstance()->getXMLDoc({mPkg, mPid});
     if (XMLDoc.get() == nullptr) return;