Loading core/java/com/android/internal/logging/MetricsLogger.java +16 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,22 @@ public class MetricsLogger implements MetricsConstants { public static final int PROFILE_CHALLENGE = 271; public static final int QS_BATTERY_DETAIL = 272; /** * Logged when the user goes into the overview history. */ public static final int OVERVIEW_HISTORY = 273; /** * Logged when the user pages through overview. */ public static final int ACTION_OVERVIEW_PAGE = 274; /** * Logged when the user launches a task from overview. */ public static final int ACTION_OVERVIEW_SELECT = 275; public static void visible(Context context, int category) throws IllegalArgumentException { if (Build.IS_DEBUGGABLE && category == VIEW_UNKNOWN) { throw new IllegalArgumentException("Must define metric category"); Loading packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java +2 −0 Original line number Diff line number Diff line Loading @@ -628,6 +628,8 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD mIterateTrigger.poke(); } } MetricsLogger.action(this, MetricsLogger.ACTION_OVERVIEW_PAGE); } } Loading packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java +4 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ import android.view.View; import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; import com.android.internal.logging.MetricsLogger; import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.events.EventBus; Loading Loading @@ -129,6 +130,9 @@ public class RecentsHistoryAdapter extends RecyclerView.Adapter<RecentsHistoryAd SystemServicesProxy ssp = Recents.getSystemServices(); ssp.startActivityFromRecents(v.getContext(), task.key.id, task.title, ActivityOptions.makeBasic()); MetricsLogger.action(v.getContext(), MetricsLogger.ACTION_OVERVIEW_SELECT, task.key.getComponent().toString()); } @Override Loading packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java +5 −0 Original line number Diff line number Diff line Loading @@ -28,6 +28,7 @@ import android.view.WindowInsets; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; import android.widget.LinearLayout; import com.android.internal.logging.MetricsLogger; import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.RecentsActivity; Loading Loading @@ -99,6 +100,8 @@ public class RecentsHistoryView extends LinearLayout { }); mAdapter.updateTasks(getContext(), stack); mIsVisible = true; MetricsLogger.visible(mRecyclerView.getContext(), MetricsLogger.OVERVIEW_HISTORY); } /** Loading Loading @@ -129,6 +132,8 @@ public class RecentsHistoryView extends LinearLayout { setVisibility(View.INVISIBLE); } mIsVisible = false; MetricsLogger.hidden(mRecyclerView.getContext(), MetricsLogger.OVERVIEW_HISTORY); } /** Loading Loading
core/java/com/android/internal/logging/MetricsLogger.java +16 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,22 @@ public class MetricsLogger implements MetricsConstants { public static final int PROFILE_CHALLENGE = 271; public static final int QS_BATTERY_DETAIL = 272; /** * Logged when the user goes into the overview history. */ public static final int OVERVIEW_HISTORY = 273; /** * Logged when the user pages through overview. */ public static final int ACTION_OVERVIEW_PAGE = 274; /** * Logged when the user launches a task from overview. */ public static final int ACTION_OVERVIEW_SELECT = 275; public static void visible(Context context, int category) throws IllegalArgumentException { if (Build.IS_DEBUGGABLE && category == VIEW_UNKNOWN) { throw new IllegalArgumentException("Must define metric category"); Loading
packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java +2 −0 Original line number Diff line number Diff line Loading @@ -628,6 +628,8 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD mIterateTrigger.poke(); } } MetricsLogger.action(this, MetricsLogger.ACTION_OVERVIEW_PAGE); } } Loading
packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java +4 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ import android.view.View; import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; import com.android.internal.logging.MetricsLogger; import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.events.EventBus; Loading Loading @@ -129,6 +130,9 @@ public class RecentsHistoryAdapter extends RecyclerView.Adapter<RecentsHistoryAd SystemServicesProxy ssp = Recents.getSystemServices(); ssp.startActivityFromRecents(v.getContext(), task.key.id, task.title, ActivityOptions.makeBasic()); MetricsLogger.action(v.getContext(), MetricsLogger.ACTION_OVERVIEW_SELECT, task.key.getComponent().toString()); } @Override Loading
packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java +5 −0 Original line number Diff line number Diff line Loading @@ -28,6 +28,7 @@ import android.view.WindowInsets; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; import android.widget.LinearLayout; import com.android.internal.logging.MetricsLogger; import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.RecentsActivity; Loading Loading @@ -99,6 +100,8 @@ public class RecentsHistoryView extends LinearLayout { }); mAdapter.updateTasks(getContext(), stack); mIsVisible = true; MetricsLogger.visible(mRecyclerView.getContext(), MetricsLogger.OVERVIEW_HISTORY); } /** Loading Loading @@ -129,6 +132,8 @@ public class RecentsHistoryView extends LinearLayout { setVisibility(View.INVISIBLE); } mIsVisible = false; MetricsLogger.hidden(mRecyclerView.getContext(), MetricsLogger.OVERVIEW_HISTORY); } /** Loading