Loading packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java +5 −5 Original line number Diff line number Diff line Loading @@ -240,11 +240,11 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD /** * Dismisses recents if we are already visible and the intent is to toggle the recents view. */ boolean dismissRecentsToFocusedTask() { boolean dismissRecentsToFocusedTask(int logCategory) { SystemServicesProxy ssp = Recents.getSystemServices(); if (ssp.isRecentsTopMost(ssp.getTopMostTask(), null)) { // If we have a focused Task, launch that Task now if (mRecentsView.launchFocusedTask()) return true; if (mRecentsView.launchFocusedTask(logCategory)) return true; } return false; } Loading @@ -270,7 +270,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD SystemServicesProxy ssp = Recents.getSystemServices(); if (ssp.isRecentsTopMost(ssp.getTopMostTask(), null)) { // If we have a focused Task, launch that Task now if (mRecentsView.launchFocusedTask()) return true; if (mRecentsView.launchFocusedTask(0 /* logCategory */)) return true; // If none of the other cases apply, then just go Home dismissRecentsToHome(true /* animateTaskViews */); return true; Loading Loading @@ -360,7 +360,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD mIterateTrigger = new DozeTrigger(mFocusTimerDuration, new Runnable() { @Override public void run() { dismissRecentsToFocusedTask(); dismissRecentsToFocusedTask(MetricsEvent.OVERVIEW_SELECT_TIMEOUT); } }); Loading Loading @@ -634,7 +634,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD // Focus the next task EventBus.getDefault().send(new FocusNextTaskViewEvent(timerIndicatorDuration)); MetricsLogger.action(this, MetricsEvent.ACTION_OVERVIEW_PAGE); MetricsLogger.action(this, MetricsEvent.OVERVIEW_PAGE); } } Loading packages/SystemUI/src/com/android/systemui/recents/RecentsActivityLaunchState.java +3 −2 Original line number Diff line number Diff line Loading @@ -66,8 +66,9 @@ public class RecentsActivityLaunchState { */ public int getInitialFocusTaskIndex(int numTasks) { RecentsDebugFlags debugFlags = Recents.getDebugFlags(); RecentsActivityLaunchState launchState = Recents.getConfiguration().getLaunchState(); if (launchedFromAppWithThumbnail) { if (debugFlags.isFastToggleRecentsEnabled()) { if (!launchState.launchedWithAltTab && debugFlags.isFastToggleRecentsEnabled()) { // If fast toggling, focus the front most task so that the next tap will focus the // N-1 task return numTasks - 1; Loading @@ -76,7 +77,7 @@ public class RecentsActivityLaunchState { // If coming from another app, focus the next task return numTasks - 2; } else { if (debugFlags.isFastToggleRecentsEnabled()) { if (!launchState.launchedWithAltTab && debugFlags.isFastToggleRecentsEnabled()) { // If fast toggling, defer focusing until the next tap (which will automatically // focus the front most task) return -1; Loading packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java +1 −1 Original line number Diff line number Diff line Loading @@ -161,7 +161,7 @@ public class RecentsHistoryAdapter extends RecyclerView.Adapter<RecentsHistoryAd ssp.startActivityFromRecents(v.getContext(), task.key.id, task.title, ActivityOptions.makeBasic()); MetricsLogger.action(v.getContext(), MetricsEvent.ACTION_OVERVIEW_SELECT, MetricsLogger.action(v.getContext(), MetricsEvent.OVERVIEW_SELECT, task.key.getComponent().toString()); } Loading packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryItemTouchCallbacks.java +3 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.support.v7.widget.RecyclerView; import android.support.v7.widget.helper.ItemTouchHelper; import com.android.internal.logging.MetricsLogger; import com.android.internal.logging.MetricsProto.MetricsEvent; import com.android.systemui.recents.Constants; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.ui.DeleteTaskDataEvent; Loading Loading @@ -72,6 +73,8 @@ public class RecentsHistoryItemTouchCallbacks extends ItemTouchHelper.SimpleCall // Keep track of deletions by swiping within history MetricsLogger.histogram(mContext, "overview_task_dismissed_source", Constants.Metrics.DismissSourceHistorySwipeGesture); MetricsLogger.action(mContext, MetricsEvent.OVERVIEW_DISMISS, taskRow.task.key.getComponent().toString()); } } } packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java +2 −0 Original line number Diff line number Diff line Loading @@ -62,6 +62,8 @@ public class Utilities { } }; public static final RectFEvaluator RECTF_EVALUATOR = new RectFEvaluator(); /** * @return the first parent walking up the view hierarchy that has the given class type. * Loading Loading
packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java +5 −5 Original line number Diff line number Diff line Loading @@ -240,11 +240,11 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD /** * Dismisses recents if we are already visible and the intent is to toggle the recents view. */ boolean dismissRecentsToFocusedTask() { boolean dismissRecentsToFocusedTask(int logCategory) { SystemServicesProxy ssp = Recents.getSystemServices(); if (ssp.isRecentsTopMost(ssp.getTopMostTask(), null)) { // If we have a focused Task, launch that Task now if (mRecentsView.launchFocusedTask()) return true; if (mRecentsView.launchFocusedTask(logCategory)) return true; } return false; } Loading @@ -270,7 +270,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD SystemServicesProxy ssp = Recents.getSystemServices(); if (ssp.isRecentsTopMost(ssp.getTopMostTask(), null)) { // If we have a focused Task, launch that Task now if (mRecentsView.launchFocusedTask()) return true; if (mRecentsView.launchFocusedTask(0 /* logCategory */)) return true; // If none of the other cases apply, then just go Home dismissRecentsToHome(true /* animateTaskViews */); return true; Loading Loading @@ -360,7 +360,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD mIterateTrigger = new DozeTrigger(mFocusTimerDuration, new Runnable() { @Override public void run() { dismissRecentsToFocusedTask(); dismissRecentsToFocusedTask(MetricsEvent.OVERVIEW_SELECT_TIMEOUT); } }); Loading Loading @@ -634,7 +634,7 @@ public class RecentsActivity extends Activity implements ViewTreeObserver.OnPreD // Focus the next task EventBus.getDefault().send(new FocusNextTaskViewEvent(timerIndicatorDuration)); MetricsLogger.action(this, MetricsEvent.ACTION_OVERVIEW_PAGE); MetricsLogger.action(this, MetricsEvent.OVERVIEW_PAGE); } } Loading
packages/SystemUI/src/com/android/systemui/recents/RecentsActivityLaunchState.java +3 −2 Original line number Diff line number Diff line Loading @@ -66,8 +66,9 @@ public class RecentsActivityLaunchState { */ public int getInitialFocusTaskIndex(int numTasks) { RecentsDebugFlags debugFlags = Recents.getDebugFlags(); RecentsActivityLaunchState launchState = Recents.getConfiguration().getLaunchState(); if (launchedFromAppWithThumbnail) { if (debugFlags.isFastToggleRecentsEnabled()) { if (!launchState.launchedWithAltTab && debugFlags.isFastToggleRecentsEnabled()) { // If fast toggling, focus the front most task so that the next tap will focus the // N-1 task return numTasks - 1; Loading @@ -76,7 +77,7 @@ public class RecentsActivityLaunchState { // If coming from another app, focus the next task return numTasks - 2; } else { if (debugFlags.isFastToggleRecentsEnabled()) { if (!launchState.launchedWithAltTab && debugFlags.isFastToggleRecentsEnabled()) { // If fast toggling, defer focusing until the next tap (which will automatically // focus the front most task) return -1; Loading
packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java +1 −1 Original line number Diff line number Diff line Loading @@ -161,7 +161,7 @@ public class RecentsHistoryAdapter extends RecyclerView.Adapter<RecentsHistoryAd ssp.startActivityFromRecents(v.getContext(), task.key.id, task.title, ActivityOptions.makeBasic()); MetricsLogger.action(v.getContext(), MetricsEvent.ACTION_OVERVIEW_SELECT, MetricsLogger.action(v.getContext(), MetricsEvent.OVERVIEW_SELECT, task.key.getComponent().toString()); } Loading
packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryItemTouchCallbacks.java +3 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.support.v7.widget.RecyclerView; import android.support.v7.widget.helper.ItemTouchHelper; import com.android.internal.logging.MetricsLogger; import com.android.internal.logging.MetricsProto.MetricsEvent; import com.android.systemui.recents.Constants; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.ui.DeleteTaskDataEvent; Loading Loading @@ -72,6 +73,8 @@ public class RecentsHistoryItemTouchCallbacks extends ItemTouchHelper.SimpleCall // Keep track of deletions by swiping within history MetricsLogger.histogram(mContext, "overview_task_dismissed_source", Constants.Metrics.DismissSourceHistorySwipeGesture); MetricsLogger.action(mContext, MetricsEvent.OVERVIEW_DISMISS, taskRow.task.key.getComponent().toString()); } } }
packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java +2 −0 Original line number Diff line number Diff line Loading @@ -62,6 +62,8 @@ public class Utilities { } }; public static final RectFEvaluator RECTF_EVALUATOR = new RectFEvaluator(); /** * @return the first parent walking up the view hierarchy that has the given class type. * Loading