Is it possible for an Activity to get to and inspect, ideally even modify, the entire View hierarchy for itself, without special access such as instrumentation mode or rooting?
findViewById(android.R.id.content)
returns the View
that hosts the content you supplied in setContentView()
. Beyond that, try getRootView()
(called on any View
) to retrieve "the topmost view in the current view hierarchy".