Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

manager: hides navbar on action screen, disable back gesture and save… #2321

Closed
wants to merge 9 commits into from
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import android.os.Environment
import androidx.activity.compose.BackHandler
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.navigationBarsPadding
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.verticalScroll
Expand Down Expand Up @@ -121,7 +122,9 @@ fun ExecuteModuleActionScreen(navigator: DestinationsNavigator, moduleId: String
icon = { Icon(Icons.Filled.Close, contentDescription = null) },
onClick = {
navigator.popBackStack()
}
},
modifier = Modifier
.navigationBarsPadding()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think change the contentWindowInsets (line 131 for now ) to WindowInsets.safeDrawing without only(WindowInsetsSides.Top + WindowInsetsSides.Horizontal) will be better

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the system to decide? Sure

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot_20241230-093043
Screenshot_20241230-093030

But the positioning for vertical is a bit off for my personal taste, are you okay with it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove modifier = Modifier.navigationBarsPadding() pls
We needn't that because Scaffold has already added the navigation bar insets

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove modifier = Modifier.navigationBarsPadding() pls We needn't that because Scaffold has already added the navigation bar insets

It was for when WindowInsets.safeDrawing without only(WindowInsetsSides.Top + WindowInsetsSides.Horizontal) was there and the button would be behind the nav bar, so since it's removed I can just get rid of the modifier = Modifier.navigationBarsPadding() sure

)
}
},
Expand Down