fix: load after setup screen
Signed-off-by: rhunk <101876869+rhunk@users.noreply.github.com>
This commit is contained in:
@@ -69,8 +69,8 @@ class RemoteSharedLibraryManager(
|
|||||||
|
|
||||||
remoteSideContext.log.info("Updating sif from $currentVersion to $latestVersion")
|
remoteSideContext.log.info("Updating sif from $currentVersion to $latestVersion")
|
||||||
if (downloadLatest(libraryFile)) {
|
if (downloadLatest(libraryFile)) {
|
||||||
remoteSideContext.sharedPreferences.edit().putString("sif", latestVersion).apply()
|
remoteSideContext.sharedPreferences.edit().putString("sif", latestVersion).commit()
|
||||||
remoteSideContext.log.info("sif updated to $latestVersion")
|
remoteSideContext.shortToast("SIF updated to $latestVersion!")
|
||||||
// force restart snapchat
|
// force restart snapchat
|
||||||
remoteSideContext.bridgeService?.stopSelf()
|
remoteSideContext.bridgeService?.stopSelf()
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -78,7 +78,7 @@ class RemoteSideContext(
|
|||||||
val tracker = RemoteTracker(this)
|
val tracker = RemoteTracker(this)
|
||||||
val accountStorage = RemoteAccountStorage(this)
|
val accountStorage = RemoteAccountStorage(this)
|
||||||
val locationManager = RemoteLocationManager(this)
|
val locationManager = RemoteLocationManager(this)
|
||||||
private val remoteSharedLibraryManager = RemoteSharedLibraryManager(this)
|
val remoteSharedLibraryManager = RemoteSharedLibraryManager(this)
|
||||||
|
|
||||||
//used to load bitmoji selfies and download previews
|
//used to load bitmoji selfies and download previews
|
||||||
val imageLoader by lazy {
|
val imageLoader by lazy {
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ import androidx.compose.ui.Modifier
|
|||||||
import androidx.compose.ui.text.font.FontWeight
|
import androidx.compose.ui.text.font.FontWeight
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
|
import kotlinx.coroutines.launch
|
||||||
import me.rhunk.snapenhance.ui.setup.screens.SetupScreen
|
import me.rhunk.snapenhance.ui.setup.screens.SetupScreen
|
||||||
|
|
||||||
class SecurityScreen : SetupScreen() {
|
class SecurityScreen : SetupScreen() {
|
||||||
@@ -63,7 +64,10 @@ class SecurityScreen : SetupScreen() {
|
|||||||
) {
|
) {
|
||||||
Button(
|
Button(
|
||||||
onClick = {
|
onClick = {
|
||||||
context.sharedPreferences.edit().putString("sif", "").apply()
|
context.coroutineScope.launch {
|
||||||
|
context.sharedPreferences.edit().putString("sif", "").commit()
|
||||||
|
context.remoteSharedLibraryManager.init()
|
||||||
|
}
|
||||||
goNext()
|
goNext()
|
||||||
}
|
}
|
||||||
) {
|
) {
|
||||||
|
|||||||
Reference in New Issue
Block a user