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

Commit 02ca80db authored by Kshitij's avatar Kshitij Committed by Mohammed Althaf T
Browse files

feat: Disable blurring in dock



- Only use vibrancy in hotseat

Signed-off-by: default avatarSaalim Quadri <danascape@gmail.com>
parent af8c1703
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -58,7 +58,8 @@ class BlurWallpaperFilter(private val context: Context) :
    private fun blur(wallpaper: Bitmap, config: BlurWallpaperProvider.BlurConfig): Bitmap {
        val source =
            if (config.scale == 1) {
                wallpaper
                // Make mutable copy in case we need to return source
                Bitmap.createBitmap(wallpaper)
            } else {
                Bitmap.createScaledBitmap(
                    wallpaper,
@@ -68,6 +69,12 @@ class BlurWallpaperFilter(private val context: Context) :
                )
            }

        // Bypass blur processor if we don't need to blur (hotseat)
        // This will only happen if the input is full resolution (scale = 1) and blur radius = 0
        if (config.radius == 0 && config.scale == 1) {
            return source
        }

        return HokoBlur.with(context)
            .scheme(HokoBlur.SCHEME_NATIVE)
            .mode(HokoBlur.MODE_STACK)
+1 −1
Original line number Diff line number Diff line
@@ -288,7 +288,7 @@ class BlurWallpaperProvider(val context: Context) : SafeCloseable {

        @JvmField val blurConfigBackground = BlurConfig({ it.background }, 2, 8)

        @JvmField val blurConfigDock = BlurConfig({ it.dock }, 2, 0)
        @JvmField val blurConfigDock = BlurConfig({ it.dock }, 1, 0)

        @JvmField val blurConfigAppGroup = BlurConfig({ it.appGroup }, 6, 8)