Fix #3271
This commit is contained in:
parent
8059e46cc2
commit
b15aca3570
1 changed files with 0 additions and 10 deletions
|
@ -571,7 +571,6 @@ public class MapActivityActions implements DialogProvider {
|
||||||
|
|
||||||
public ContextMenuAdapter createMainOptionsMenu() {
|
public ContextMenuAdapter createMainOptionsMenu() {
|
||||||
final OsmandMapTileView mapView = mapActivity.getMapView();
|
final OsmandMapTileView mapView = mapActivity.getMapView();
|
||||||
int viewHeight = mapView.getViewHeight();
|
|
||||||
final OsmandApplication app = mapActivity.getMyApplication();
|
final OsmandApplication app = mapActivity.getMyApplication();
|
||||||
ContextMenuAdapter optionsMenuHelper = new ContextMenuAdapter();
|
ContextMenuAdapter optionsMenuHelper = new ContextMenuAdapter();
|
||||||
|
|
||||||
|
@ -790,15 +789,6 @@ public class MapActivityActions implements DialogProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
ItemBuilder divider = new ItemBuilder().setLayout(R.layout.drawer_divider);
|
ItemBuilder divider = new ItemBuilder().setLayout(R.layout.drawer_divider);
|
||||||
if (viewHeight > 0) {
|
|
||||||
int listItemHeight = app.getResources().getDimensionPixelSize(R.dimen.list_item_height);
|
|
||||||
int dividerHeight = viewHeight - optionsMenuHelper.length() * listItemHeight;
|
|
||||||
if (dividerHeight > 0) {
|
|
||||||
divider.setMinHeight(dividerHeight);
|
|
||||||
} else if (dividerHeight < 0) {
|
|
||||||
divider.setMinHeight(AndroidUtils.dpToPx(app, 16f));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
divider.setPosition(pluginsItemIndex >= 0 ? pluginsItemIndex : 7);
|
divider.setPosition(pluginsItemIndex >= 0 ? pluginsItemIndex : 7);
|
||||||
optionsMenuHelper.addItem(divider.createItem());
|
optionsMenuHelper.addItem(divider.createItem());
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue