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

Verified Commit 87b6509f authored by Kshitij's avatar Kshitij Committed by Saalim Quadri
Browse files

chore: @SuppressLint("NewApi") for setPageIndicatorInset

parent eb3c0f50
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -417,6 +417,7 @@ public class Workspace<T extends View & PageIndicator> extends PagedView<T>
        setPageIndicatorInset();
    }

    @SuppressLint("NewApi")
    private void setPageIndicatorInset() {
        DeviceProfile grid = mLauncher.getDeviceProfile();

@@ -439,11 +440,7 @@ public class Workspace<T extends View & PageIndicator> extends PagedView<T>
            // Get "safe" drawable inset to not overlap gesture pill
            int safeBottomInset;
            WindowInsets rootInsets = mLauncher.getWindow().getDecorView().getRootWindowInsets();
            if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.R) {
            safeBottomInset = rootInsets.getInsetsIgnoringVisibility(WindowInsets.Type.systemBars()).bottom;
            } else {
                safeBottomInset = rootInsets.getStableInsetBottom();
            }
            lp.bottomMargin = safeBottomInset;
        } else {
            lp.bottomMargin = grid.hotseatBarSizePx;