MCPcopy Index your code
hub / github.com/TarCV/uiautomatorviewer-gradle

github.com/TarCV/uiautomatorviewer-gradle @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
157 symbols 280 edges 18 files 11 documented · 7% updated 2mo ago★ 75
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Screenshot

Verifying this code against the SDK sources

  1. Verifying that this repository is actually based on the original viewer sources: This repository is based on https://android.googlesource.com/platform/tools/swt/+/1ad1e59667a2b7ea4c0c90e3bfb76c39c5a96fb3/uiautomatorviewer/ . The initial commit - da94b667bbdc007d2bdf74d300932eb3dc75256e is exactly that directory. Therefore, you can download that source and compare it against the sources in that initial commit.

There should be no differences except in timestamps. 2. Reviewing changes: Some changes were made to those original sources to fix building on the latest Java/OS/etc., update libraries, and for convenience. These changes can be reviewed by comparing the current main with the initial commit.

Running

Install JDK 17+ if needed, older versions won't be able to build or run the app. Build the app and its start scripts with installDist Gradle task. Make sure Android Debug Bridge is available. Once that is done, you can just run the start script for your OS:

./gradlew installDist
./build/install/uiautomatorviewer-gradle/bin/uiautomatorviewer-gradle

Note: For Win, you might need the .bat scripts (gradlew.bat and uiautomatorviewer-gradle.bat) instead.

Running in an IDE on a Mac

When using the run task from Gradle or calling the relevant start script for your OS (as described in Running) everything should work as is. Otherwise, make sure the option -XstartOnFirstThread is passed to JVM when launching the app from your IDE.

Also make sure Android Debug Bridge is available.

Extension points exported contracts — how you extend this code

IFindNodeListener (Interface)
(no doc) [2 implementers]
src/main/java/com/android/uiautomator/tree/BasicTreeNode.java

Core symbols most depended-on inside this repo

getScaledSize
called by 18
src/main/java/com/android/uiautomator/UiAutomatorView.java
loadImageDescriptorFromResource
called by 9
src/main/java/com/android/uiautomator/actions/ImageHelper.java
redrawScreenshot
called by 5
src/main/java/com/android/uiautomator/UiAutomatorView.java
findAdbIn
called by 3
src/main/java/com/android/uiautomator/DebugBridge.java
clearSearchResult
called by 3
src/main/java/com/android/uiautomator/UiAutomatorView.java
updateSearchResultSelection
called by 3
src/main/java/com/android/uiautomator/UiAutomatorView.java
getValue
called by 3
src/main/java/com/android/uiautomator/UiAutomatorView.java
shouldShowNafNodes
called by 3
src/main/java/com/android/uiautomator/UiAutomatorView.java

Shape

Method 133
Class 23
Interface 1

Languages

Java100%

Modules by API surface

src/main/java/com/android/uiautomator/UiAutomatorView.java34 symbols
src/main/java/com/android/uiautomator/UiAutomatorModel.java16 symbols
src/main/java/com/android/uiautomator/tree/BasicTreeNode.java12 symbols
src/main/java/com/android/uiautomator/OpenDialog.java12 symbols
src/main/java/com/android/uiautomator/actions/ScreenshotAction.java11 symbols
src/main/java/com/android/uiautomator/UiAutomatorViewer.java10 symbols
src/main/java/com/android/uiautomator/tree/UiNode.java8 symbols
src/main/java/com/android/uiautomator/UiAutomatorHelper.java8 symbols
src/main/java/com/android/uiautomator/tree/UiHierarchyXmlLoader.java7 symbols
src/main/java/com/android/uiautomator/tree/BasicTreeNodeContentProvider.java7 symbols
src/main/java/com/android/uiautomator/DebugBridge.java7 symbols
src/main/java/com/android/uiautomator/tree/RootWindowNode.java5 symbols

For agents

$ claude mcp add uiautomatorviewer-gradle \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page