0
0
Fork 0
mirror of https://github.com/YTVanced/VancedManager synced 2024-11-27 05:23:00 +00:00

improved code

This commit is contained in:
X1nto 2020-07-06 18:36:27 +04:00
parent d3caeb7554
commit 70affaefda

View file

@ -87,9 +87,11 @@ class MainActivity : AppCompatActivity() {
override fun onPause() {
super.onPause()
getSharedPreferences("installPrefs", Context.MODE_PRIVATE).edit().putBoolean("isInstalling", false).apply()
getSharedPreferences("installPrefs", Context.MODE_PRIVATE).edit().putBoolean("isVancedDownloading", false).apply()
getSharedPreferences("installPrefs", Context.MODE_PRIVATE).edit().putBoolean("isMicrogDownloading", false).apply()
with(getSharedPreferences("installPrefs", Context.MODE_PRIVATE).edit()) {
putBoolean("isInstalling", false).apply()
putBoolean("isVancedDownloading", false).apply()
putBoolean("isMicrogDownloading", false).apply()
}
localBroadcastManager.unregisterReceiver(broadcastReceiver)
Crowdin.unregisterDataLoadingObserver(loadingObserver)
}