Loading packages/SystemUI/compose/features/src/com/android/systemui/qs/ui/composable/QuickSettingsShadeOverlay.kt +17 −1 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ import androidx.compose.animation.core.tween import androidx.compose.animation.fadeIn import androidx.compose.animation.fadeOut import androidx.compose.animation.togetherWith import androidx.compose.foundation.focusable import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Row Loading @@ -38,6 +39,7 @@ import androidx.compose.material3.IconButton import androidx.compose.material3.IconButtonDefaults import androidx.compose.material3.MaterialTheme import androidx.compose.runtime.Composable import androidx.compose.runtime.LaunchedEffect import androidx.compose.runtime.ReadOnlyComposable import androidx.compose.runtime.derivedStateOf import androidx.compose.runtime.getValue Loading @@ -46,6 +48,8 @@ import androidx.compose.runtime.rememberCoroutineScope import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.draw.blur import androidx.compose.ui.focus.FocusRequester import androidx.compose.ui.focus.focusRequester import androidx.compose.ui.geometry.Offset import androidx.compose.ui.geometry.Rect import androidx.compose.ui.geometry.Size Loading Loading @@ -277,8 +281,20 @@ private fun ContentScope.QuickSettingsContainer( if (QsDetailedView.isEnabled) containerViewModel.detailsViewModel.activeTileDetails else null val focusRequester = remember { FocusRequester() } LaunchedEffect(focusRequester) { // Request focus on the `QuickSettingsContainer` without user interaction so that the user // can press the tab key once to enter the Quick Settings area. Without this line, the user // has to tab through unrelated views of the higher view hierarchy level. focusRequester.requestFocus() } AnimatedContent( modifier = Modifier.sysuiResTag("quick_settings_container"), modifier = Modifier .focusRequester(focusRequester) .focusable() .sysuiResTag("quick_settings_container"), targetState = when { isEditing -> ShadeBodyState.Editing Loading Loading
packages/SystemUI/compose/features/src/com/android/systemui/qs/ui/composable/QuickSettingsShadeOverlay.kt +17 −1 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ import androidx.compose.animation.core.tween import androidx.compose.animation.fadeIn import androidx.compose.animation.fadeOut import androidx.compose.animation.togetherWith import androidx.compose.foundation.focusable import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Row Loading @@ -38,6 +39,7 @@ import androidx.compose.material3.IconButton import androidx.compose.material3.IconButtonDefaults import androidx.compose.material3.MaterialTheme import androidx.compose.runtime.Composable import androidx.compose.runtime.LaunchedEffect import androidx.compose.runtime.ReadOnlyComposable import androidx.compose.runtime.derivedStateOf import androidx.compose.runtime.getValue Loading @@ -46,6 +48,8 @@ import androidx.compose.runtime.rememberCoroutineScope import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.draw.blur import androidx.compose.ui.focus.FocusRequester import androidx.compose.ui.focus.focusRequester import androidx.compose.ui.geometry.Offset import androidx.compose.ui.geometry.Rect import androidx.compose.ui.geometry.Size Loading Loading @@ -277,8 +281,20 @@ private fun ContentScope.QuickSettingsContainer( if (QsDetailedView.isEnabled) containerViewModel.detailsViewModel.activeTileDetails else null val focusRequester = remember { FocusRequester() } LaunchedEffect(focusRequester) { // Request focus on the `QuickSettingsContainer` without user interaction so that the user // can press the tab key once to enter the Quick Settings area. Without this line, the user // has to tab through unrelated views of the higher view hierarchy level. focusRequester.requestFocus() } AnimatedContent( modifier = Modifier.sysuiResTag("quick_settings_container"), modifier = Modifier .focusRequester(focusRequester) .focusable() .sysuiResTag("quick_settings_container"), targetState = when { isEditing -> ShadeBodyState.Editing Loading