diff --git a/src/org/thoughtcrime/securesms/loki/activities/SettingsActivity.kt b/src/org/thoughtcrime/securesms/loki/activities/SettingsActivity.kt index aa9e5b7fd9..72ec815eca 100644 --- a/src/org/thoughtcrime/securesms/loki/activities/SettingsActivity.kt +++ b/src/org/thoughtcrime/securesms/loki/activities/SettingsActivity.kt @@ -11,11 +11,11 @@ import android.os.AsyncTask import android.os.Bundle import android.os.Handler import android.os.Looper -import android.support.v7.app.AppCompatDelegate import android.view.View import android.view.inputmethod.InputMethodManager import android.widget.LinearLayout import android.widget.Toast +import androidx.appcompat.app.AppCompatDelegate import kotlinx.android.synthetic.main.activity_settings.* import network.loki.messenger.BuildConfig import network.loki.messenger.R @@ -115,9 +115,10 @@ class SettingsActivity : PassphraseRequiredActionBarActivity() { return themeFlag == Configuration.UI_MODE_NIGHT_YES; } + //TODO Remove it. private fun setDarkTheme(darkTheme: Boolean) { // AppCompatDelegate.setDefaultNightMode(if (darkTheme) AppCompatDelegate.MODE_NIGHT_YES else AppCompatDelegate.MODE_NIGHT_NO ) - AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_AUTO) + AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM) } public override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {