Skip to content

Commit

Permalink
Use rememberSaveable to remember the marker type page
Browse files Browse the repository at this point in the history
  • Loading branch information
dkhawk committed Apr 26, 2024
1 parent e0d74bb commit 6850e6e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import androidx.compose.runtime.CompositionLocalProvider
import androidx.compose.runtime.collectAsState
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.remember
import androidx.compose.runtime.saveable.rememberSaveable
import androidx.compose.runtime.setValue
import androidx.compose.ui.Modifier
import androidx.compose.ui.platform.LocalConfiguration
Expand Down Expand Up @@ -69,7 +69,7 @@ class MainActivity : ComponentActivity() {
dynamicColor = false
) {
// Remember the type of marker we want to show
var selectedMarkerType by remember {
var selectedMarkerType by rememberSaveable {
mutableStateOf(MarkerType.Basic)
}

Expand Down

0 comments on commit 6850e6e

Please sign in to comment.