Applied code review changes.

This commit is contained in:
Isira Seneviratne 2022-08-05 06:54:03 +05:30
parent fc46233baf
commit a9af1dfdd2
3 changed files with 6 additions and 6 deletions

View file

@ -34,7 +34,6 @@ import org.schabi.newpipe.util.DeviceUtils;
import org.schabi.newpipe.util.ThemeHelper;
import org.schabi.newpipe.views.FocusOverlayView;
import java.util.ArrayList;
import java.util.List;
import java.util.stream.IntStream;
@ -76,9 +75,10 @@ public class NotificationActionsPreference extends Preference {
////////////////////////////////////////////////////////////////////////////
private void setupActions(@NonNull final View view) {
compactSlots = new ArrayList<>(NotificationConstants
.getCompactSlotsFromPreferences(getContext(), getSharedPreferences(), 5));
notificationSlots = IntStream.range(0, 5).mapToObj(i -> new NotificationSlot(i, view))
compactSlots = NotificationConstants.getCompactSlotsFromPreferences(getContext(),
getSharedPreferences(), 5);
notificationSlots = IntStream.range(0, 5)
.mapToObj(i -> new NotificationSlot(i, view))
.toArray(NotificationSlot[]::new);
}