0

I try to debug my android app and I see a redundant blank activity sometimes.

However I cannot understand the flow which leads me to that blank activity.

How can eclipse help me understand which Activity is displayed?

I have looked at the DDMS perspective and have found no answer.

Also tried to press "pause" run (debug play, stop and pause buttons)

and i couldn't see where to read the current active activity.

Does someone know?

update

I have tried

adb logcat | grep "ActivityManager"

    D/dalvikvm(28517): Note: class Landroid/app/ActivityManagerNative; has 192 unimplemented (abstract) methods
    W/ApplicationsProvider(27925):  at android.app.ActivityManager.getAllPackageUsageStats(ActivityManager.java:2520)
    D/dalvikvm(28691): Note: class Landroid/app/ActivityManagerNative; has 192 unimplemented (abstract) methods
    W/ApplicationsProvider(27925):  at android.app.ActivityManager.getAllPackageUsageStats(ActivityManager.java:2520)
    W/ApplicationsProvider(27925):  at android.app.ActivityManager.getAllPackageUsageStats(ActivityManager.java:2520)
    E/Parcel  (27354):  at com.android.server.am.ActivityManagerService.startActivityAsUser(ActivityManagerService.java:4066)
    E/Parcel  (27354):  at com.android.server.am.ActivityManagerService.startActivity(ActivityManagerService.java:3964)
    E/Parcel  (27354):  at android.app.ActivityManagerNative.onTransact(ActivityManagerNative.java:159)
    E/Parcel  (27354):  at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:2645)

but where do I see the Activity name?

enter image description here

update 2

I have tried to open hierarchy view but it has an error inspecting my app:

enter image description here

update 3

I cannot see it even in the log cat

enter image description here

Elad Benda2
  • 13,852
  • 29
  • 82
  • 157

2 Answers2

0

yes u can log ur activity which you are currently IN :

adb logcat | grep "ActivityManager"

Below is ScreenShot showing activity with package name :

enter image description here

KOTIOS
  • 11,177
  • 3
  • 39
  • 66
0

use hierarchy viewer and observe the bold text which describes currently visible activity.To open hierarchy viewer from eclipse,select Window -> Open Perspective -> Hierarchy View.

using hierarchy viewer for currently visible activity

To learn more about hierarchy viewer refer this link

rupesh jain
  • 3,410
  • 1
  • 14
  • 22
  • hierarchy viewer is part of eclipse? – Elad Benda2 Aug 11 '14 at 04:51
  • I have tried to open hierarchy view but it has an error inspecting my app – Elad Benda2 Aug 11 '14 at 05:05
  • @user1065869 refer https://forums.pragprog.com/forums/152/topics/12024 and http://stackoverflow.com/questions/4626767/android-hierarchyviewer-unable-to-load-window-data and http://stackoverflow.com/questions/20325051/android-emulator-in-adt-plugin-not-running to solve this issue – rupesh jain Aug 11 '14 at 13:03