Android: robustness if locale failed to be detected at start

Sylvain Becker 2020-05-08 21:50:23 +02:00
parent 2491f16f85
commit 33642b47b2
1 changed files with 1 additions and 1 deletions

View File

@ -423,7 +423,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
Log.v(TAG, "onConfigurationChanged()");
super.onConfigurationChanged(newConfig);
if (!mCurrentLocale.equals(newConfig.locale)) {
if (mCurrentLocale == null || !mCurrentLocale.equals(newConfig.locale)) {
mCurrentLocale = newConfig.locale;
SDLActivity.onNativeLocaleChanged();
}