Save remembered tabs per user (#57)

If the remember tab setting is enabled, tabs will be remembered per user
profile now
This commit is contained in:
damontecres 2025-10-22 19:24:17 -04:00 committed by GitHub
parent f5ee5eceab
commit b5771db54e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 98 additions and 39 deletions

View file

@ -0,0 +1,24 @@
package com.github.damontecres.wholphin.util
import com.github.damontecres.wholphin.preferences.UserPreferences
import java.util.UUID
interface RememberTabManager {
/**
* If enabled, get the remembered tab index for the given item
*/
fun getRememberedTab(
preferences: UserPreferences,
itemId: UUID,
defaultTab: Int,
): Int
/**
* If enabled, save the remembered tab index for the given item
*/
fun saveRememberedTab(
preferences: UserPreferences,
itemId: UUID,
tabIndex: Int,
)
}