RecentsExtraCard

Bug fixing / formatting

Change-Id: If36cd64986cc213682af1c7b4fd3281909812c15
This commit is contained in:
Sreyas 2019-10-24 18:00:05 -07:00
parent 7afd271a17
commit d567b58810
4 changed files with 7 additions and 7 deletions

View File

@ -69,7 +69,7 @@ public class BackgroundAppState extends OverviewState {
return super.getOverviewScaleAndTranslation(launcher);
}
TaskView dummyTask;
if (recentsView.getCurrentPage() >= 0) {
if (recentsView.getCurrentPage() >= recentsView.getTaskViewStartIndex()) {
if (recentsView.getCurrentPage() <= taskCount - 1) {
dummyTask = recentsView.getCurrentPageTaskView();
} else {

View File

@ -326,8 +326,8 @@ public class LauncherRecentsView extends RecentsView<Launcher> implements StateL
@Override
protected void onAttachedToWindow() {
super.onAttachedToWindow();
PluginManagerWrapper.INSTANCE.get(getContext())
.addPluginListener(mRecentsExtraCardPluginListener, RecentsExtraCard.class);
PluginManagerWrapper.INSTANCE.get(getContext()).addPluginListener(
mRecentsExtraCardPluginListener, RecentsExtraCard.class);
}
@Override

View File

@ -1855,8 +1855,8 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
private void updateEnabledOverlays() {
int overlayEnabledPage = mOverlayEnabled ? getNextPage() : -1;
int taskCount = getTaskViewCount();
for (int i = 0; i < taskCount; i++) {
getTaskViewAt(i).setOverlayEnabled(i == overlayEnabledPage);
for (int i = mTaskViewStartIndex; i < mTaskViewStartIndex + taskCount; i++) {
getTaskViewAtByAbsoluteIndex(i).setOverlayEnabled(i == overlayEnabledPage);
}
}

View File

@ -34,9 +34,9 @@ public interface RecentsExtraCard extends Plugin {
/**
* Sets up the recents overview extra card and fills in data.
*
* @param context Plugin context
* @param context Plugin context
* @param frameLayout PlaceholderView
* @param activity Recents activity to hold extra view
* @param activity Recents activity to hold extra view
*/
void setupView(Context context, FrameLayout frameLayout, Activity activity);
}