I am using monkeyrunner dump -VF option to list all ids and positions too. Now I need all ids and names of controls in webview control. Is it possible to get it using monkeyrunner or how to fetch those controls too.
Asked
Active
Viewed 233 times
1
-
@dtmilano Hi Is it possible? – Sep 25 '13 at 04:12
1 Answers
2
First things first, if you are running (as you should) dump
from AndroidViewClient >= 4.0.0 you should not use monkeyrunner
as the interpreter but python
.
Just:
$ ./dump -VF
on an operating system that supports shebang, or
python dump -VF
on a no-so-lucky OS.
dump
dumps all the android Views and its properties, so unfortunately it's not possible now to dig inside the WebView, perhaps in the future this feature could be added, but it should rely on different techniques than the ones used to obtain the View hierarchy.

Diego Torres Milano
- 65,697
- 9
- 111
- 134
-
-
1I don't know what you mean by `edit code`, but you may need to change WebView itself to provide this kind of information, so it would work only on your firmware. If you think of another way don't hesitate to share it. – Diego Torres Milano Sep 25 '13 at 04:44
-
@dtmilano Hi In calabash-android when query on webview it will show all ids Is it possible in AndroidViewClient dump? Is it any way to achieve it using python? – Abhijit Shelar Sep 27 '13 at 08:46