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

Commit e6b091b3 authored by Yuichiro Hanada's avatar Yuichiro Hanada
Browse files

Show resize veil on top of the other tasks

Bug: 396613981
Test: manual - go/cd-smoke
Flag: com.android.window.flags.enable_connected_displays_window_drag
Change-Id: I12db478ce40ee14cf59207bc817069cf52f8126a
parent 2a2f062d
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ import android.graphics.Rect
import android.os.Trace
import android.view.Display
import android.view.SurfaceControl
import android.window.TaskConstants
import androidx.compose.material3.dynamicDarkColorScheme
import androidx.compose.material3.dynamicLightColorScheme
import androidx.compose.ui.graphics.toArgb
@@ -98,7 +99,10 @@ class MultiDisplayDragMoveIndicatorSurface(

        rootTaskDisplayAreaOrganizer.reparentToDisplayArea(displayId, veil, transaction)
        relayout(bounds, transaction, shouldBeVisible = true)
        transaction.show(veil).setColor(veil, Color.valueOf(backgroundColor.toArgb()).components)
        transaction
            .show(veil)
            .setColor(veil, Color.valueOf(backgroundColor.toArgb()).components)
            .setLayer(veil, MOVE_INDICATOR_LAYER)
        transaction.apply()
    }

@@ -148,4 +152,8 @@ class MultiDisplayDragMoveIndicatorSurface(
            }
        }
    }

    companion object {
        private const val MOVE_INDICATOR_LAYER = TaskConstants.TASK_CHILD_LAYER_RESIZE_VEIL
    }
}