about works

This commit is contained in:
Odweta
2024-12-22 11:51:43 +01:00
parent 7618535493
commit 78fca78c75
2 changed files with 7 additions and 9 deletions
@@ -40,9 +40,7 @@ import androidx.compose.ui.unit.sp
@Composable @Composable
fun AboutScreen() { fun AboutScreen() {
// handle the back gesture (back swipe form side or back button on bottom android navbar) // handle the back gesture (back swipe form side or back button on bottom android navbar)
BackHandler { BackHandler { global.currentScreenElement = ScreenElement.Menu }
isShowing = IsShowing.Menu
}
Column( Column(
modifier = Modifier modifier = Modifier
@@ -115,7 +113,7 @@ fun AboutTableRow(key: String, value: String, href: String = "") {
Row( Row(
modifier = Modifier modifier = Modifier
.padding(10.dp) .padding(10.dp)
.background(color = Color.Black, shape = RoundedCornerShape(roundedCornerDimen)) .background(color = Color.Black, shape = RoundedCornerShape(global.dimens.roundedCorner))
.fillMaxWidth() .fillMaxWidth()
) { ) {
Text( Text(
@@ -45,8 +45,8 @@ fun BackButton(onClick: () -> Unit) {
), ),
modifier = Modifier modifier = Modifier
.border( .border(
width = 5.dp, width = global.dimens.borderWidth,
shape = RoundedCornerShape(roundedCornerDimen), shape = RoundedCornerShape(global.dimens.roundedCorner),
color = PastelYellow color = PastelYellow
) )
.width(70.dp) .width(70.dp)
@@ -65,9 +65,9 @@ object BackButtonFactory: BackButtonFactoryInterface {
@Composable @Composable
override fun get(type: BackButtonType): @Composable () -> Unit { override fun get(type: BackButtonType): @Composable () -> Unit {
return when (type) { return when (type) {
BackButtonType.Menu -> { { BackButton({ isShowing = IsShowing.Menu }) } } BackButtonType.Menu -> { { BackButton { global.currentScreenElement = ScreenElement.Menu } } }
BackButtonType.MarksAll -> { { BackButton({ global.marksDepthLevel = MarksDepthLevel.All }) } } BackButtonType.MarksAll -> { { BackButton { global.marksDepthLevel = MarksDepthLevel.All } } }
BackButtonType.MarksSubject -> { { BackButton({ global.marksDepthLevel = MarksDepthLevel.Subject }) } } BackButtonType.MarksSubject -> { { BackButton { global.marksDepthLevel = MarksDepthLevel.Subject } } }
} }
} }
} }