diff --git a/src/com/dtmilano/android/viewclient.py b/src/com/dtmilano/android/viewclient.py index 53a4f6b1..61dbe891 100644 --- a/src/com/dtmilano/android/viewclient.py +++ b/src/com/dtmilano/android/viewclient.py @@ -3955,7 +3955,7 @@ def __findViewWithAttributeInTreeThatMatches(self, attr, regex, root, rlist=[]): if DEBUG: print("__findViewWithAttributeInTreeThatMatches: checking if root=%s attr=%s matches %s" % ( root.__smallStr__(), attr, regex), file=sys.stderr) - if root and attr in root.map and regex.match(root.map[attr]): + if root and attr in root.map and regex.search(root.map[attr]): if DEBUG: print("__findViewWithAttributeInTreeThatMatches: FOUND: %s" % root.__smallStr__(), file=sys.stderr) return root @@ -3981,7 +3981,7 @@ def __findViewsWithAttributeInTreeThatMatches(self, attr, regex, root, rlist=[]) print("__findViewsWithAttributeInTreeThatMatches: checking if root=%s attr=%s matches %s" % ( root.__smallStr__(), attr, regex), file=sys.stderr) - if root and attr in root.map and regex.match(root.map[attr]): + if root and attr in root.map and regex.search(root.map[attr]): if DEBUG: print("__findViewsWithAttributeInTreeThatMatches: FOUND: %s" % root.__smallStr__(), file=sys.stderr) matchingViews.append(root)