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

Commit 3b489717 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Screen capture: Guard settings button in toolbar behind feature flag" into main

parents 87569c9e 124f35bf
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1961,6 +1961,13 @@ flag {
    bug: "422833825"
}

flag {
    name: "large_screen_recording"
    namespace: "systemui"
    description: "Enables screen recording UI for large screen devices."
    bug: "423707369"
}

flag {
    name: "new_screen_record_toolbar"
    namespace: "systemui"
+2 −0
Original line number Diff line number Diff line
@@ -23,4 +23,6 @@ import javax.inject.Inject
@SysUISingleton
class ScreenCaptureRecordLargeScreenFeaturesInteractor @Inject constructor() {
    val appWindowRegionSupported = Flags.desktopScreenCaptureAppWindow()

    val screenRecordingSupported = Flags.largeScreenRecording()
}
+8 −6
Original line number Diff line number Diff line
@@ -56,6 +56,7 @@ fun PreCaptureToolbar(

    Toolbar(expanded = expanded, onCloseClick = onCloseClick, modifier = modifier) {
        Row {
            if (viewModel.screenRecordingSupported) {
                IconToggleButton(
                    checked = false,
                    onCheckedChange = {},
@@ -63,6 +64,7 @@ fun PreCaptureToolbar(
                ) {
                    viewModel.icons?.let { Icon(icon = it.moreOptions) }
                }
            }

            Spacer(Modifier.size(8.dp))

+2 −0
Original line number Diff line number Diff line
@@ -63,6 +63,8 @@ constructor(
    // TODO(b/423697394) Init default value to be user's previously selected option
    val captureRegion: ScreenCaptureRegion by captureRegionSource.hydratedStateOf()

    val screenRecordingSupported = featuresInteractor.screenRecordingSupported

    val captureTypeButtonViewModels: List<RadioButtonGroupItemViewModel> by
        combine(captureTypeSource, iconProvider.icons) { selectedType, icons ->
                generateCaptureTypeButtonViewModels(selectedType, icons)