目前,如果我点击Android Studio中的活动管理器状态,我将能够看到此类日志:
TASK com.blogspot.diannaoxiaobai.myorig2 id=289
ACTIVITY com.blogspot.diannaoxiaobai.myorig2/.MainActivity 3c65e06 pid=15238
Local FragmentActivity 3076abe State:
mCreated=truemResumed=true mStopped=false mReallyStopped=false
mLoadersStarted=true
FragmentManager misc state:
mHost=android.support.v4.app.FragmentActivity$HostCallbacks@9a2871f
mContainer=android.support.v4.app.FragmentActivity$HostCallbacks@9a2871f
mCurState=5 mStateSaved=false mDestroyed=false
View Hierarchy:
com.android.internal.policy.PhoneWindow$DecorView{592a6c V.E..... ... 0,0-1080,1920}
android.widget.LinearLayout{c6c2835 V.E..... ... 0,0-1080,1812}
android.view.ViewStub{c4b74ca G.E..... ... 0,0-0,0 #102039f android:id/action_mode_bar_stub}
android.widget.FrameLayout{7f2763b V.E..... ... 0,72-1080,1812}
android.support.v7.widget.FitWindowsLinearLayout{ee48158 V.E..... ... 0,0-1080,1740 #7f0c0055 app:id/action_bar_root}
android.support.v7.widget.ViewStubCompat{8c412b1 G.E..... ... 0,0-0,0 #7f0c0056 app:id/action_mode_bar_stub}
android.support.v7.widget.ContentFrameLayout{f141396 V.E..... ... 0,0-1080,1740 #1020002 android:id/content}
android.widget.RelativeLayout{5883b17 V.E..... ... 0,0-1080,1740}
android.support.v4.widget.NestedScrollView{7cc5b04 VFED.... ... 0,48-1032,1692}
android.widget.LinearLayout{ed628ed V.ED.... ... 0,90-942,8430}
android.widget.FrameLayout{5f5d322 V.E..... ... 0,0-942,900 #7f0c0087 app:id/nav_drawer}
android.widget.RelativeLayout{e4b71b3 V.E..... ... 0,0-942,900}
android.support.v7.widget.AppCompatImageView{6362370 V.ED.... ... 0,0-942,900}
...
我能够看到此日志中的哪个活动和片段名称,但 xml名称怎么样?是否有任何调试工具/实用程序来显示激活/聚焦/运行Activity / Fragment / Adapater的xml文件名(不在每个文件中手动插入Log.d()
)?就像kodi.log
一样。如果需要root,我可以接受。