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

Commit da8fdfbc authored by Mohammed Althaf T's avatar Mohammed Althaf T 😊
Browse files

test launcher crash

parent d2100267
Loading
Loading
Loading
Loading
Loading
+4 −6
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@ import android.graphics.Color
import android.graphics.ColorMatrix
import android.graphics.ColorMatrixColorFilter
import android.graphics.Paint
import android.util.Log
import android.widget.Toast
import androidx.core.graphics.drawable.toBitmap
import com.android.launcher3.Utilities
@@ -184,12 +185,9 @@ class BlurWallpaperProvider(val context: Context) {
        mVibrancyPaint.colorFilter =
            ColorMatrixColorFilter(ColorMatrix().apply { setSaturation(1.25f) })

        val bitmap =
            Bitmap.createBitmap(
                wallpaper.width,
                wallpaper.height,
                wallpaper.config ?: Bitmap.Config.ARGB_8888
            )
        val origBitmap = Bitmap.createBitmap(wallpaper)
        val bitmap = origBitmap.copy(Bitmap.Config.ARGB_8888, true)
        Log.i("BlurWallpaperProvider", "config=${origBitmap.isMutable} ${origBitmap.config}")
        Canvas().apply {
            setBitmap(bitmap)
            drawBitmap(wallpaper, 0f, 0f, mVibrancyPaint)