Loading packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -22,7 +22,7 @@ import com.android.systemui.recents.model.TaskStack; /** /** * This is sent by the activity whenever the task stach has changed. * This is sent by the activity whenever the task stach has changed. */ */ public class TaskStackUpdatedEvent extends EventBus.Event { public class TaskStackUpdatedEvent extends EventBus.AnimatedEvent { /** /** * A new TaskStack instance representing the latest stack state. * A new TaskStack instance representing the latest stack state. Loading packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragStartInitializeDropTargetsEvent.java +5 −1 Original line number Original line Diff line number Diff line Loading @@ -19,6 +19,7 @@ package com.android.systemui.recents.events.ui.dragndrop; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.views.RecentsViewTouchHandler; import com.android.systemui.recents.views.RecentsViewTouchHandler; import com.android.systemui.recents.views.TaskView; /** /** * This event is sent by the drag manager when it requires drop targets to register themselves for * This event is sent by the drag manager when it requires drop targets to register themselves for Loading @@ -27,10 +28,13 @@ import com.android.systemui.recents.views.RecentsViewTouchHandler; public class DragStartInitializeDropTargetsEvent extends EventBus.Event { public class DragStartInitializeDropTargetsEvent extends EventBus.Event { public final Task task; public final Task task; public final TaskView taskView; public final RecentsViewTouchHandler handler; public final RecentsViewTouchHandler handler; public DragStartInitializeDropTargetsEvent(Task task, RecentsViewTouchHandler handler) { public DragStartInitializeDropTargetsEvent(Task task, TaskView taskView, RecentsViewTouchHandler handler) { this.task = task; this.task = task; this.taskView = taskView; this.handler = handler; this.handler = handler; } } } } packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -400,7 +400,12 @@ public class TaskStack { // Calculate the task stack bounds from the new window bounds // Calculate the task stack bounds from the new window bounds Rect searchBarSpaceBounds = new Rect(); Rect searchBarSpaceBounds = new Rect(); Rect taskStackBounds = new Rect(); Rect taskStackBounds = new Rect(); config.getTaskStackBounds(newWindowBounds, insets.top, insets.right, // If the task stack bounds is specifically under the dock area, then ignore the top // inset int top = dockArea.bottom < 1f ? 0 : insets.top; config.getTaskStackBounds(newWindowBounds, top, insets.right, searchBarSpaceBounds, taskStackBounds); searchBarSpaceBounds, taskStackBounds); return taskStackBounds; return taskStackBounds; } } Loading packages/SystemUI/src/com/android/systemui/recents/tv/RecentsTvActivity.java +0 −16 Original line number Original line Diff line number Diff line Loading @@ -319,22 +319,6 @@ public class RecentsTvActivity extends Activity implements OnPreDrawListener { } } } } @Override public void onMultiWindowModeChanged(boolean multiWindowMode) { super.onMultiWindowModeChanged(multiWindowMode); if (!multiWindowMode) { RecentsTaskLoader loader = Recents.getTaskLoader(); RecentsTaskLoadPlan.Options launchOpts = new RecentsTaskLoadPlan.Options(); launchOpts.loadIcons = false; launchOpts.loadThumbnails = false; launchOpts.onlyLoadForCache = true; RecentsTaskLoadPlan loadPlan = loader.createLoadPlan(this); loader.preloadTasks(loadPlan, -1, false); loader.loadTasks(this, loadPlan, launchOpts); EventBus.getDefault().send(new TaskStackUpdatedEvent(loadPlan.getTaskStack())); } } @Override @Override public boolean onKeyDown(int keyCode, KeyEvent event) { public boolean onKeyDown(int keyCode, KeyEvent event) { switch (keyCode) { switch (keyCode) { Loading packages/SystemUI/src/com/android/systemui/recents/tv/views/RecentsTvView.java +0 −7 Original line number Original line Diff line number Diff line Loading @@ -227,12 +227,6 @@ public class RecentsTvView extends FrameLayout { EventBus.getDefault().send(new CancelEnterRecentsWindowAnimationEvent(null)); EventBus.getDefault().send(new CancelEnterRecentsWindowAnimationEvent(null)); } } public final void onBusEvent(TaskStackUpdatedEvent event) { mStack.setTasks(event.stack.computeAllTasksList(), true /* notifyStackChanges */); mStack.createAffiliatedGroupings(getContext()); } public final void onBusEvent(RecentsVisibilityChangedEvent event) { public final void onBusEvent(RecentsVisibilityChangedEvent event) { if (!event.visible) { if (!event.visible) { // Reset the view state // Reset the view state Loading @@ -240,7 +234,6 @@ public class RecentsTvView extends FrameLayout { } } } } public void setTaskStackViewAdapter(TaskStackHorizontalViewAdapter taskStackViewAdapter) { public void setTaskStackViewAdapter(TaskStackHorizontalViewAdapter taskStackViewAdapter) { if(mTaskStackHorizontalView != null) { if(mTaskStackHorizontalView != null) { mTaskStackHorizontalView.setAdapter(taskStackViewAdapter); mTaskStackHorizontalView.setAdapter(taskStackViewAdapter); Loading Loading
packages/SystemUI/src/com/android/systemui/recents/events/activity/TaskStackUpdatedEvent.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -22,7 +22,7 @@ import com.android.systemui.recents.model.TaskStack; /** /** * This is sent by the activity whenever the task stach has changed. * This is sent by the activity whenever the task stach has changed. */ */ public class TaskStackUpdatedEvent extends EventBus.Event { public class TaskStackUpdatedEvent extends EventBus.AnimatedEvent { /** /** * A new TaskStack instance representing the latest stack state. * A new TaskStack instance representing the latest stack state. Loading
packages/SystemUI/src/com/android/systemui/recents/events/ui/dragndrop/DragStartInitializeDropTargetsEvent.java +5 −1 Original line number Original line Diff line number Diff line Loading @@ -19,6 +19,7 @@ package com.android.systemui.recents.events.ui.dragndrop; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.events.EventBus; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.model.Task; import com.android.systemui.recents.views.RecentsViewTouchHandler; import com.android.systemui.recents.views.RecentsViewTouchHandler; import com.android.systemui.recents.views.TaskView; /** /** * This event is sent by the drag manager when it requires drop targets to register themselves for * This event is sent by the drag manager when it requires drop targets to register themselves for Loading @@ -27,10 +28,13 @@ import com.android.systemui.recents.views.RecentsViewTouchHandler; public class DragStartInitializeDropTargetsEvent extends EventBus.Event { public class DragStartInitializeDropTargetsEvent extends EventBus.Event { public final Task task; public final Task task; public final TaskView taskView; public final RecentsViewTouchHandler handler; public final RecentsViewTouchHandler handler; public DragStartInitializeDropTargetsEvent(Task task, RecentsViewTouchHandler handler) { public DragStartInitializeDropTargetsEvent(Task task, TaskView taskView, RecentsViewTouchHandler handler) { this.task = task; this.task = task; this.taskView = taskView; this.handler = handler; this.handler = handler; } } } }
packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -400,7 +400,12 @@ public class TaskStack { // Calculate the task stack bounds from the new window bounds // Calculate the task stack bounds from the new window bounds Rect searchBarSpaceBounds = new Rect(); Rect searchBarSpaceBounds = new Rect(); Rect taskStackBounds = new Rect(); Rect taskStackBounds = new Rect(); config.getTaskStackBounds(newWindowBounds, insets.top, insets.right, // If the task stack bounds is specifically under the dock area, then ignore the top // inset int top = dockArea.bottom < 1f ? 0 : insets.top; config.getTaskStackBounds(newWindowBounds, top, insets.right, searchBarSpaceBounds, taskStackBounds); searchBarSpaceBounds, taskStackBounds); return taskStackBounds; return taskStackBounds; } } Loading
packages/SystemUI/src/com/android/systemui/recents/tv/RecentsTvActivity.java +0 −16 Original line number Original line Diff line number Diff line Loading @@ -319,22 +319,6 @@ public class RecentsTvActivity extends Activity implements OnPreDrawListener { } } } } @Override public void onMultiWindowModeChanged(boolean multiWindowMode) { super.onMultiWindowModeChanged(multiWindowMode); if (!multiWindowMode) { RecentsTaskLoader loader = Recents.getTaskLoader(); RecentsTaskLoadPlan.Options launchOpts = new RecentsTaskLoadPlan.Options(); launchOpts.loadIcons = false; launchOpts.loadThumbnails = false; launchOpts.onlyLoadForCache = true; RecentsTaskLoadPlan loadPlan = loader.createLoadPlan(this); loader.preloadTasks(loadPlan, -1, false); loader.loadTasks(this, loadPlan, launchOpts); EventBus.getDefault().send(new TaskStackUpdatedEvent(loadPlan.getTaskStack())); } } @Override @Override public boolean onKeyDown(int keyCode, KeyEvent event) { public boolean onKeyDown(int keyCode, KeyEvent event) { switch (keyCode) { switch (keyCode) { Loading
packages/SystemUI/src/com/android/systemui/recents/tv/views/RecentsTvView.java +0 −7 Original line number Original line Diff line number Diff line Loading @@ -227,12 +227,6 @@ public class RecentsTvView extends FrameLayout { EventBus.getDefault().send(new CancelEnterRecentsWindowAnimationEvent(null)); EventBus.getDefault().send(new CancelEnterRecentsWindowAnimationEvent(null)); } } public final void onBusEvent(TaskStackUpdatedEvent event) { mStack.setTasks(event.stack.computeAllTasksList(), true /* notifyStackChanges */); mStack.createAffiliatedGroupings(getContext()); } public final void onBusEvent(RecentsVisibilityChangedEvent event) { public final void onBusEvent(RecentsVisibilityChangedEvent event) { if (!event.visible) { if (!event.visible) { // Reset the view state // Reset the view state Loading @@ -240,7 +234,6 @@ public class RecentsTvView extends FrameLayout { } } } } public void setTaskStackViewAdapter(TaskStackHorizontalViewAdapter taskStackViewAdapter) { public void setTaskStackViewAdapter(TaskStackHorizontalViewAdapter taskStackViewAdapter) { if(mTaskStackHorizontalView != null) { if(mTaskStackHorizontalView != null) { mTaskStackHorizontalView.setAdapter(taskStackViewAdapter); mTaskStackHorizontalView.setAdapter(taskStackViewAdapter); Loading