2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-03 23:15:31 +00:00

No issue: Correct TabsTrayAction naming

This commit is contained in:
Jonathan Almeida 2021-11-04 03:58:13 -04:00 committed by mergify[bot]
parent 08b15689b1
commit 8ced675817
3 changed files with 4 additions and 4 deletions

View File

@ -134,7 +134,7 @@ sealed class TabsTrayAction : Action {
/**
* Removes the [TabsTrayState.focusGroupTabId] of the [TabsTrayState].
*/
object ConsumeFocusGroupTabIdAction : TabsTrayAction()
object ConsumeFocusGroupTabId : TabsTrayAction()
/**
* Updates the list of tabs in [TabsTrayState.inactiveTabs].
@ -185,7 +185,7 @@ internal object TabsTrayReducer {
state.copy(syncing = true)
is TabsTrayAction.SyncCompleted ->
state.copy(syncing = false)
is TabsTrayAction.ConsumeFocusGroupTabIdAction ->
is TabsTrayAction.ConsumeFocusGroupTabId ->
state.copy(focusGroupTabId = null)
is TabsTrayAction.UpdateInactiveTabs ->
state.copy(inactiveTabs = action.tabs)

View File

@ -135,7 +135,7 @@ class NormalBrowserPageViewHolder(
layoutManager.scrollToPosition(indexToScrollTo)
if (focusGroupTabId != null) {
tabsTrayStore.dispatch(TabsTrayAction.ConsumeFocusGroupTabIdAction)
tabsTrayStore.dispatch(TabsTrayAction.ConsumeFocusGroupTabId)
}
return@observeFirstInsert
}

View File

@ -16,7 +16,7 @@ class TabsTrayStoreReducerTest {
val resultState = TabsTrayReducer.reduce(
initialState,
TabsTrayAction.ConsumeFocusGroupTabIdAction
TabsTrayAction.ConsumeFocusGroupTabId
)
assertEquals(expectedState, resultState)