Skip to content

Commit

Permalink
force recomposition everytimes actionModeCounter is changed
Browse files Browse the repository at this point in the history
  • Loading branch information
cuong-tran committed Oct 27, 2024
1 parent bfcbe13 commit c2c71d6
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import androidx.compose.material3.LocalContentColor
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.surfaceColorAtElevation
import androidx.compose.runtime.Composable
import androidx.compose.runtime.derivedStateOf
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.remember
Expand Down Expand Up @@ -46,9 +45,7 @@ fun MangaToolbar(
modifier: Modifier = Modifier,
backgroundAlphaProvider: () -> Float,
) {
val isActionMode by remember(actionModeCounter) {
derivedStateOf { actionModeCounter > 0 }
}
val isActionMode = remember(actionModeCounter) { actionModeCounter > 0 }
AppBar(
modifier = modifier,
title = title,
Expand Down

0 comments on commit c2c71d6

Please sign in to comment.