diff options
| author | 2016-01-08 00:06:34 +0000 | |
|---|---|---|
| committer | 2016-01-08 00:06:34 +0000 | |
| commit | 3e9bc83e6e64d9f4134628690c75d10c264f57ec (patch) | |
| tree | ff1fb19c4cd85636de6e7e4eb49cd004d5031e54 | |
| parent | 5e677425e039de72578060ae5bd5ef9181c5678f (diff) | |
| parent | dc8de848201f64542ad87940cfaa7a5e3d1343ad (diff) | |
Merge "Cleaning up imports and dead code."
23 files changed, 6 insertions, 45 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java index 0cfe0763938a..e4d80672d30d 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java +++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java @@ -68,7 +68,6 @@ import com.android.systemui.recents.events.ui.focus.FocusNextTaskViewEvent; import com.android.systemui.recents.events.ui.focus.FocusPreviousTaskViewEvent; import com.android.systemui.recents.history.RecentsHistoryView; import com.android.systemui.recents.misc.DozeTrigger; -import com.android.systemui.recents.misc.ReferenceCountedTrigger; import com.android.systemui.recents.misc.SystemServicesProxy; import com.android.systemui.recents.model.RecentsPackageMonitor; import com.android.systemui.recents.model.RecentsTaskLoadPlan; diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java index cfbd1cb13ab9..67135d5621b4 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java +++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java @@ -19,7 +19,6 @@ package com.android.systemui.recents; import android.content.Context; import android.content.res.Resources; import android.graphics.Rect; -import android.provider.Settings; import com.android.systemui.R; import com.android.systemui.recents.misc.SystemServicesProxy; diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsImpl.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsImpl.java index fd00289b0248..213018a50b2c 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/RecentsImpl.java +++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsImpl.java @@ -338,7 +338,6 @@ public class RecentsImpl extends IRecentsNonSystemUserCallbacks.Stub implements if (topTask != null && ssp.isRecentsTopMost(topTask, isTopTaskHome)) { RecentsConfiguration config = Recents.getConfiguration(); RecentsActivityLaunchState launchState = config.getLaunchState(); - RecentsDebugFlags flags = Recents.getDebugFlags(); if (!launchState.launchedWithAltTab) { // Notify recents to move onto the next task EventBus.getDefault().post(new IterateRecentsEvent()); diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/EventBus.java b/packages/SystemUI/src/com/android/systemui/recents/events/EventBus.java index 5c49ac380b9b..b0c8ff3c15b6 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/EventBus.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/EventBus.java @@ -27,7 +27,6 @@ import android.os.SystemClock; import android.os.UserHandle; import android.util.Log; import android.util.MutableBoolean; - import com.android.systemui.recents.misc.ReferenceCountedTrigger; import java.lang.ref.WeakReference; @@ -663,8 +662,6 @@ public class EventBus extends BroadcastReceiver { /** * Registers a new subscriber. - * - * @return return whether or not this */ private void registerSubscriber(Object subscriber, int priority, MutableBoolean hasInterprocessEventsChangedOut) { diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/activity/HideHistoryEvent.java b/packages/SystemUI/src/com/android/systemui/recents/events/activity/HideHistoryEvent.java index e85dea31c837..af3eeb0c837d 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/activity/HideHistoryEvent.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/activity/HideHistoryEvent.java @@ -17,7 +17,6 @@ package com.android.systemui.recents.events.activity; import com.android.systemui.recents.events.EventBus; -import com.android.systemui.recents.misc.ReferenceCountedTrigger; /** * This is sent when the history view will be closed. diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/activity/ShowHistoryEvent.java b/packages/SystemUI/src/com/android/systemui/recents/events/activity/ShowHistoryEvent.java index 94e5a9725c49..b39d645b9326 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/activity/ShowHistoryEvent.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/activity/ShowHistoryEvent.java @@ -17,7 +17,6 @@ package com.android.systemui.recents.events.activity; import com.android.systemui.recents.events.EventBus; -import com.android.systemui.recents.misc.ReferenceCountedTrigger; /** * This is sent when the history view button is clicked. diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java b/packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java index b94ed7b4104b..7579cd8b82a0 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java @@ -16,7 +16,6 @@ package com.android.systemui.recents.events.activity; -import com.android.systemui.recents.RecentsAppWidgetHost; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.model.TaskStack; diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/ui/DeleteTaskDataEvent.java b/packages/SystemUI/src/com/android/systemui/recents/events/ui/DeleteTaskDataEvent.java index bf14082e661b..4ed027084def 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/ui/DeleteTaskDataEvent.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/ui/DeleteTaskDataEvent.java @@ -18,7 +18,6 @@ package com.android.systemui.recents.events.ui; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.model.Task; -import com.android.systemui.recents.views.TaskView; /** * This is sent when the data associated with a given {@link Task} should be deleted from the diff --git a/packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragEndEvent.java b/packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragEndEvent.java index 8aa463179082..73c282fe8816 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragEndEvent.java +++ b/packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragEndEvent.java @@ -17,7 +17,6 @@ package com.android.systemui.recents.events.ui.dragndrop; import com.android.systemui.recents.events.EventBus; -import com.android.systemui.recents.misc.ReferenceCountedTrigger; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.views.DropTarget; import com.android.systemui.recents.views.TaskView; diff --git a/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java b/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java index 72ec7b76f1c9..f0fa1da7810f 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java +++ b/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryAdapter.java @@ -185,7 +185,6 @@ public class RecentsHistoryAdapter extends RecyclerView.Adapter<RecentsHistoryAd * remove the task from the TaskStack since the TaskStackView will also receive this event. */ public void removeTasks(String packageName, int userId) { - boolean packagesRemoved = false; for (int i = mRows.size() - 1; i >= 0; i--) { Row row = mRows.get(i); if (row.getViewType() == TASK_ROW_VIEW_TYPE) { diff --git a/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java b/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java index 9524da5d08bb..a2f5159a7ec3 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java +++ b/packages/SystemUI/src/com/android/systemui/recents/history/RecentsHistoryView.java @@ -35,7 +35,6 @@ import com.android.systemui.recents.RecentsConfiguration; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.activity.PackagesChangedEvent; import com.android.systemui.recents.misc.ReferenceCountedTrigger; -import com.android.systemui.recents.misc.SystemServicesProxy; import com.android.systemui.recents.model.TaskStack; /** diff --git a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java index 108029d68805..ca50fc5ef981 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java +++ b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java @@ -68,7 +68,6 @@ import com.android.systemui.Prefs; import com.android.systemui.R; import com.android.systemui.recents.RecentsDebugFlags; import com.android.systemui.recents.RecentsImpl; -import com.android.systemui.statusbar.BaseStatusBar; import java.io.IOException; import java.util.ArrayList; @@ -79,7 +78,6 @@ import java.util.Random; import static android.app.ActivityManager.StackId.DOCKED_STACK_ID; import static android.app.ActivityManager.StackId.FREEFORM_WORKSPACE_STACK_ID; import static android.app.ActivityManager.StackId.HOME_STACK_ID; -import static android.app.ActivityManager.StackId.INVALID_STACK_ID; import static android.provider.Settings.Global.DEVELOPMENT_ENABLE_FREEFORM_WINDOWS_SUPPORT; /** diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java index bae478472a5d..856200df6529 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java +++ b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java @@ -495,9 +495,6 @@ public class TaskStack { // Sort all the tasks to ensure they are ordered correctly Collections.sort(newTasks, FREEFORM_LAST_ACTIVE_TIME_COMPARATOR); - // TODO: Update screen pinning for the new front-most task post refactoring lockToTask out - // of the Task - // Filter out the historical tasks from this new list ArrayList<Task> stackTasks = new ArrayList<>(); ArrayList<Task> historyTasks = new ArrayList<>(); diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/FreeformWorkspaceLayoutAlgorithm.java b/packages/SystemUI/src/com/android/systemui/recents/views/FreeformWorkspaceLayoutAlgorithm.java index 871afd9449c1..fce916b9d2d3 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/FreeformWorkspaceLayoutAlgorithm.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/FreeformWorkspaceLayoutAlgorithm.java @@ -19,8 +19,6 @@ package com.android.systemui.recents.views; import android.content.Context; import android.graphics.Rect; import android.graphics.RectF; -import android.util.Log; - import com.android.systemui.R; import com.android.systemui.recents.model.Task; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsTransitionHelper.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsTransitionHelper.java index 796556d11e49..51cae862cdcc 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsTransitionHelper.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsTransitionHelper.java @@ -32,16 +32,15 @@ import android.view.AppTransitionAnimationSpec; import android.view.IAppTransitionAnimationSpecsFuture; import android.view.WindowManagerGlobal; import com.android.internal.annotations.GuardedBy; -import com.android.systemui.recents.events.activity.ExitRecentsWindowFirstAnimationFrameEvent; import com.android.systemui.recents.Recents; import com.android.systemui.recents.RecentsDebugFlags; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.activity.CancelEnterRecentsWindowAnimationEvent; +import com.android.systemui.recents.events.activity.ExitRecentsWindowFirstAnimationFrameEvent; import com.android.systemui.recents.events.activity.LaunchTaskFailedEvent; import com.android.systemui.recents.events.activity.LaunchTaskStartedEvent; import com.android.systemui.recents.events.activity.LaunchTaskSucceededEvent; import com.android.systemui.recents.events.component.ScreenPinningRequestEvent; -import com.android.systemui.recents.events.ui.TaskViewDismissedEvent; import com.android.systemui.recents.misc.SystemServicesProxy; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.model.TaskStack; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java index f49d98e4e404..e28e2b383aba 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java @@ -19,7 +19,6 @@ package com.android.systemui.recents.views; import android.animation.Animator; import android.animation.AnimatorListenerAdapter; import android.content.Context; -import android.content.res.Resources; import android.graphics.Canvas; import android.graphics.Rect; import android.graphics.drawable.Drawable; @@ -34,8 +33,8 @@ import android.view.WindowInsets; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; import android.widget.FrameLayout; -import com.android.internal.logging.MetricsLogger; 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.RecentsActivity; @@ -45,7 +44,6 @@ import com.android.systemui.recents.RecentsConfiguration; import com.android.systemui.recents.RecentsDebugFlags; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.activity.CancelEnterRecentsWindowAnimationEvent; -import com.android.systemui.recents.events.activity.DebugFlagsChangedEvent; import com.android.systemui.recents.events.activity.DismissRecentsToHomeAnimationStarted; import com.android.systemui.recents.events.activity.HideHistoryButtonEvent; import com.android.systemui.recents.events.activity.HideHistoryEvent; @@ -61,13 +59,13 @@ import com.android.systemui.recents.events.ui.dragndrop.DragEndEvent; import com.android.systemui.recents.events.ui.dragndrop.DragStartEvent; import com.android.systemui.recents.misc.ReferenceCountedTrigger; import com.android.systemui.recents.misc.SystemServicesProxy; -import com.android.systemui.recents.misc.Utilities; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.model.TaskStack; import com.android.systemui.stackdivider.WindowManagerProxy; import com.android.systemui.statusbar.FlingAnimationUtils; import java.util.ArrayList; +import java.util.Collections; import java.util.List; import static android.app.ActivityManager.StackId.INVALID_STACK_ID; @@ -215,7 +213,6 @@ public class RecentsView extends FrameLayout { /** Launches the focused task from the first stack if possible */ public boolean launchFocusedTask() { if (mTaskStackView != null) { - TaskStack stack = mTaskStackView.getStack(); Task task = mTaskStackView.getFocusedTask(); if (task != null) { TaskView taskView = mTaskStackView.getChildViewForTask(task); @@ -245,7 +242,6 @@ public class RecentsView extends FrameLayout { /** Launches a given task. */ public boolean launchTask(Task task, Rect taskBounds, int destinationStack) { if (mTaskStackView != null) { - TaskStack stack = mTaskStackView.getStack(); // Iterate the stack views and try and find the given task. List<TaskView> taskViews = mTaskStackView.getTaskViews(); int taskViewCount = taskViews.size(); @@ -645,9 +641,7 @@ public class RecentsView extends FrameLayout { private void updateVisibleDockRegions(TaskStack.DockState[] newDockStates, int overrideAlpha) { ArraySet<TaskStack.DockState> newDockStatesSet = new ArraySet<>(); if (newDockStates != null) { - for (TaskStack.DockState dockState : newDockStates) { - newDockStatesSet.add(dockState); - } + Collections.addAll(newDockStatesSet, newDockStates); } for (TaskStack.DockState dockState : mVisibleDockStates) { TaskStack.DockState.ViewState viewState = dockState.viewState; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsViewTouchHandler.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsViewTouchHandler.java index 5fbf421e9836..473334b40d8d 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsViewTouchHandler.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsViewTouchHandler.java @@ -145,7 +145,6 @@ public class RecentsViewTouchHandler { /** * Handles dragging touch events - * @param ev */ private void handleTouchEvent(MotionEvent ev) { int action = ev.getAction(); diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java b/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java index f84eb5367665..9618f212d983 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java @@ -22,9 +22,6 @@ import android.view.View; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; import com.android.systemui.R; -import com.android.systemui.recents.Recents; -import com.android.systemui.recents.RecentsActivityLaunchState; -import com.android.systemui.recents.RecentsConfiguration; import com.android.systemui.recents.events.activity.DismissRecentsToHomeAnimationStarted; import com.android.systemui.recents.events.activity.EnterRecentsWindowAnimationCompletedEvent; @@ -64,8 +61,6 @@ public class SystemBarScrimViews { */ public void prepareEnterRecentsAnimation(boolean hasStatusBarScrim, boolean animateStatusBarScrim, boolean hasNavBarScrim, boolean animateNavBarScrim) { - RecentsConfiguration config = Recents.getConfiguration(); - RecentsActivityLaunchState launchState = config.getLaunchState(); mHasNavBarScrim = hasStatusBarScrim; mShouldAnimateStatusBarScrim = animateStatusBarScrim; mHasStatusBarScrim = hasNavBarScrim; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackAnimationHelper.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackAnimationHelper.java index 787e330b85d7..80a35de9feb7 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackAnimationHelper.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackAnimationHelper.java @@ -24,7 +24,6 @@ import android.graphics.RectF; import android.view.View; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; - import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.RecentsActivityLaunchState; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java index 33ceaa1ca6dc..9568facf87fb 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java @@ -29,7 +29,6 @@ import android.os.Bundle; import android.os.Parcelable; import android.provider.Settings; import android.util.IntProperty; -import android.util.Log; import android.util.Property; import android.view.LayoutInflater; import android.view.MotionEvent; @@ -92,9 +91,6 @@ public class TaskStackView extends FrameLayout implements TaskStack.TaskStackCal TaskView.TaskViewCallbacks, TaskStackViewScroller.TaskStackViewScrollerCallbacks, ViewPool.ViewPoolConsumer<TaskView, Task> { - private final static String TAG = "TaskStackView"; - private final static boolean DEBUG = false; - private final static String KEY_SAVED_STATE_SUPER = "saved_instance_state_super"; private final static String KEY_SAVED_STATE_LAYOUT_FOCUSED_STATE = "saved_instance_state_layout_focused_state"; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java index 5852d07a9275..c748efcc842b 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java @@ -33,8 +33,8 @@ import com.android.systemui.recents.Constants; import com.android.systemui.recents.Recents; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.activity.HideRecentsEvent; -import com.android.systemui.recents.events.ui.TaskViewDismissedEvent; import com.android.systemui.recents.events.ui.StackViewScrolledEvent; +import com.android.systemui.recents.events.ui.TaskViewDismissedEvent; import com.android.systemui.recents.misc.SystemServicesProxy; import com.android.systemui.recents.misc.Utilities; import com.android.systemui.statusbar.FlingAnimationUtils; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java index b9fefde89223..e8652f5b5d7b 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java @@ -41,7 +41,6 @@ import android.view.animation.AccelerateInterpolator; import android.view.animation.AnimationUtils; import android.view.animation.Interpolator; import android.widget.FrameLayout; - import com.android.systemui.R; import com.android.systemui.recents.Recents; import com.android.systemui.recents.RecentsActivity; diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewAnimation.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewAnimation.java index 0e7f677b9f30..363ad667bc7d 100644 --- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewAnimation.java +++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewAnimation.java @@ -24,7 +24,7 @@ import android.view.animation.LinearInterpolator; import java.util.List; /** - * The animation properties to animate a {@link TaskView} to a given {@TaskViewTransform}. + * The animation properties to animate a {@link TaskView} to a given {@link TaskViewTransform}. */ public class TaskViewAnimation { |