Fix detail pane state getting stuck after cancelled predictive back gesture.
Co-authored-by: Greyson Parrelli <greyson@signal.org>
This commit is contained in:
parent
70ab0baa3c
commit
6ea96795cb
@ -382,13 +382,5 @@ class MainNavigationViewModel(
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
override suspend fun seekBack(backNavigationBehavior: BackNavigationBehavior, fraction: Float) {
|
||||
super.seekBack(backNavigationBehavior, fraction)
|
||||
|
||||
if (fraction == 0f) {
|
||||
lockPaneToSecondary = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -58,6 +58,10 @@ open class AppScaffoldNavigator<T> @RememberInComposition constructor(private va
|
||||
}
|
||||
|
||||
override suspend fun seekBack(backNavigationBehavior: BackNavigationBehavior, fraction: Float) {
|
||||
if (fraction == 0f && state == NavigationState.SEEK) {
|
||||
state = NavigationState.ENTER
|
||||
}
|
||||
|
||||
if (fraction > 0f && state != NavigationState.SEEK) {
|
||||
state = NavigationState.SEEK
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user