mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-21 05:43:37 +00:00
[android][sdk] Fix ThemeUtils usage in sdk
Signed-off-by: Andrei Shkrob <github@shkrob.dev>
This commit is contained in:
committed by
Konstantin Pastbin
parent
886d569895
commit
447266c328
@@ -458,12 +458,10 @@ public class MwmActivity extends BaseMwmFragmentActivity
|
||||
@StyleRes
|
||||
protected int getThemeResourceId(@NonNull String theme)
|
||||
{
|
||||
Context context = getApplicationContext();
|
||||
|
||||
if (ThemeUtils.isDefaultTheme(context, theme))
|
||||
if (Config.UiTheme.isDefault(theme))
|
||||
return R.style.MwmTheme_MainActivity;
|
||||
|
||||
if (ThemeUtils.isNightTheme(context, theme))
|
||||
if (Config.UiTheme.isNight(theme))
|
||||
return R.style.MwmTheme_Night_MainActivity;
|
||||
|
||||
return super.getThemeResourceId(theme);
|
||||
@@ -585,7 +583,7 @@ public class MwmActivity extends BaseMwmFragmentActivity
|
||||
|
||||
private void refreshLightStatusBar()
|
||||
{
|
||||
UiUtils.setLightStatusBar(this, !(ThemeUtils.isNightTheme(this) || RoutingController.get().isPlanning()
|
||||
UiUtils.setLightStatusBar(this, !(ThemeUtils.isNightTheme() || RoutingController.get().isPlanning()
|
||||
|| ChoosePositionMode.get() != ChoosePositionMode.None));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user