Fix status bar with turned off map controls; change light status bar color
This commit is contained in:
parent
8349309018
commit
31c8a5a53e
3 changed files with 5 additions and 3 deletions
|
@ -132,7 +132,7 @@
|
|||
|
||||
<color name="status_bar_light">#e58200</color>
|
||||
<color name="status_bar_dark">#2f3a40</color>
|
||||
<color name="status_bar_transparent_light">#33000000</color>
|
||||
<color name="status_bar_transparent_light">#66000000</color>
|
||||
<color name="status_bar_transparent_dark">#99000000</color>
|
||||
<color name="status_bar_transparent_gradient">#CC000000</color>
|
||||
<color name="status_bar_mapillary">#11ab51</color>
|
||||
|
|
|
@ -829,12 +829,13 @@ public class MapActivity extends OsmandActionBarActivity implements DownloadEven
|
|||
getWindow().setStatusBarColor(ContextCompat.getColor(this, colorId));
|
||||
return;
|
||||
}
|
||||
boolean mapControlsVisible = findViewById(R.id.MapHudButtonsOverlay).getVisibility() == View.VISIBLE;
|
||||
boolean night = app.getDaynightHelper().isNightModeForMapControls();
|
||||
boolean mapTopBar = findViewById(R.id.map_top_bar).getVisibility() == View.VISIBLE;
|
||||
boolean markerTopBar = findViewById(R.id.map_markers_top_bar).getVisibility() == View.VISIBLE;
|
||||
if (mapTopBar) {
|
||||
if (mapTopBar && mapControlsVisible) {
|
||||
colorId = night ? R.color.status_bar_route_dark : R.color.status_bar_route_light;
|
||||
} else if (markerTopBar) {
|
||||
} else if (markerTopBar && mapControlsVisible) {
|
||||
colorId = R.color.status_bar_dark;
|
||||
} else {
|
||||
colorId = night ? R.color.status_bar_transparent_dark : R.color.status_bar_transparent_light;
|
||||
|
|
|
@ -689,6 +689,7 @@ public class MapControlsLayer extends OsmandMapLayer {
|
|||
} else {
|
||||
showMapControls();
|
||||
}
|
||||
mapActivity.updateStatusBarColor();
|
||||
}
|
||||
|
||||
public void startNavigation() {
|
||||
|
|
Loading…
Reference in a new issue