Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d9e3b8e2 authored by Alex Chau's avatar Alex Chau Committed by Android (Google) Code Review
Browse files

Merge "Revert "Add detailed exception for snappedIndex == -1 when dismissing tasks"" into main

parents f096f3eb ee3a7e90
Loading
Loading
Loading
Loading
+12 −26
Original line number Original line Diff line number Diff line
@@ -3812,7 +3812,6 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
                                        taskViewIdArray.removeValue(
                                        taskViewIdArray.removeValue(
                                                finalNextFocusedTaskView.getTaskViewId());
                                                finalNextFocusedTaskView.getTaskViewId());
                                    }
                                    }
                                    try {
                                    if (snappedIndex < taskViewIdArray.size()) {
                                    if (snappedIndex < taskViewIdArray.size()) {
                                        taskViewIdToSnapTo = taskViewIdArray.get(snappedIndex);
                                        taskViewIdToSnapTo = taskViewIdArray.get(snappedIndex);
                                    } else if (snappedIndex == taskViewIdArray.size()) {
                                    } else if (snappedIndex == taskViewIdArray.size()) {
@@ -3827,19 +3826,6 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
                                                    snappedIndex);
                                                    snappedIndex);
                                        }
                                        }
                                    }
                                    }
                                    } catch (ArrayIndexOutOfBoundsException e) {
                                        throw new IllegalStateException(
                                                "b/269956477 invalid snappedIndex"
                                                        + "\nsnappedTaskViewId: "
                                                        + snappedTaskViewId
                                                        + "\nfocusedTaskViewId: "
                                                        + mFocusedTaskViewId
                                                        + "\ntopRowIdArray: "
                                                        + getTopRowIdArray().toConcatString()
                                                        + "\nbottomRowIdArray: "
                                                        + getBottomRowIdArray().toConcatString(),
                                                e);
                                    }
                                }
                                }
                            }
                            }