fix: deprecating warning for getLayoutDirection and LAYOUT_DIRECTION_LTR

This commit is contained in:
Producdevity 2025-07-12 20:46:33 +02:00 committed by crueter
parent e00abd0281
commit ab50b5cc9a

View file

@ -1234,7 +1234,7 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback {
val cutInsets: Insets = windowInsets.getInsets(WindowInsetsCompat.Type.displayCutout()) val cutInsets: Insets = windowInsets.getInsets(WindowInsetsCompat.Type.displayCutout())
var left = 0 var left = 0
var right = 0 var right = 0
if (ViewCompat.getLayoutDirection(v) == ViewCompat.LAYOUT_DIRECTION_LTR) { if (v.layoutDirection == View.LAYOUT_DIRECTION_LTR) {
left = cutInsets.left left = cutInsets.left
} else { } else {
right = cutInsets.right right = cutInsets.right