Merge pull request #1750 from kiwix/feature/macgills/1707-night-mode-7

#1707 A Problem with the Night Mode
This commit is contained in:
Seán Mac Gillicuddy 2020-02-03 13:35:26 +00:00 committed by GitHub
commit 84cb7db9f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 3 deletions

View File

@ -1404,8 +1404,7 @@ public abstract class CoreMainActivity extends BaseActivity
break;
case REQUEST_PREFERENCES:
if (resultCode == RESULT_RESTART) {
startActivity(Intents.internal(CoreMainActivity.class));
finish();
recreate();
}
if (resultCode == RESULT_HISTORY_CLEARED) {
webViewList.clear();

View File

@ -175,7 +175,6 @@ public abstract class CorePrefsFragment extends PreferenceFragment implements
@Override
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
if (key.equals(PREF_ZOOM_ENABLED)) {
setSliderState();
}
@ -185,6 +184,7 @@ public abstract class CorePrefsFragment extends PreferenceFragment implements
}
if (key.equals(PREF_NIGHT_MODE)) {
sharedPreferenceUtil.updateNightMode();
restartActivity();
}
}