diff --git a/OsmAnd/res/drawable-hdpi/box_night_top_l_normal.9.png b/OsmAnd/res/drawable-hdpi/box_night_top_l_normal.9.png index 4f6ca4ff2d..e2c21c8f7f 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_night_top_l_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_night_top_l_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_night_top_r_normal.9.png b/OsmAnd/res/drawable-hdpi/box_night_top_r_normal.9.png index 8e3f127b97..9cde79c975 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_night_top_r_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_night_top_r_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_night_top_simple.9.png b/OsmAnd/res/drawable-hdpi/box_night_top_simple.9.png index 49ba455acc..bf420c7006 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_night_top_simple.9.png and b/OsmAnd/res/drawable-hdpi/box_night_top_simple.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_night_top_stack_normal.9.png b/OsmAnd/res/drawable-hdpi/box_night_top_stack_normal.9.png index 164ca18514..6fd9a29751 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_night_top_stack_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_night_top_stack_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_l_normal.9.png b/OsmAnd/res/drawable-hdpi/box_top_l_normal.9.png index b667b2e424..e3502e7eaa 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_l_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_top_l_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_l_pressed.9.png b/OsmAnd/res/drawable-hdpi/box_top_l_pressed.9.png index 90a4fc1594..04e49a2087 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_l_pressed.9.png and b/OsmAnd/res/drawable-hdpi/box_top_l_pressed.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_pressed.9.png b/OsmAnd/res/drawable-hdpi/box_top_pressed.9.png index 9e126be317..c36775357d 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_pressed.9.png and b/OsmAnd/res/drawable-hdpi/box_top_pressed.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_r_normal.9.png b/OsmAnd/res/drawable-hdpi/box_top_r_normal.9.png index 9b0239d022..2f1b8bb70f 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_r_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_top_r_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_r_pressed.9.png b/OsmAnd/res/drawable-hdpi/box_top_r_pressed.9.png index 3e77bda71d..f6b636d4fc 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_r_pressed.9.png and b/OsmAnd/res/drawable-hdpi/box_top_r_pressed.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_simple.9.png b/OsmAnd/res/drawable-hdpi/box_top_simple.9.png index 9eade3d336..2096a6ad73 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_simple.9.png and b/OsmAnd/res/drawable-hdpi/box_top_simple.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_stack_normal.9.png b/OsmAnd/res/drawable-hdpi/box_top_stack_normal.9.png index f1740f49cb..b82095b168 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_stack_normal.9.png and b/OsmAnd/res/drawable-hdpi/box_top_stack_normal.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_stack_pressed.9.png b/OsmAnd/res/drawable-hdpi/box_top_stack_pressed.9.png index a83e159579..1df3bfc581 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_stack_pressed.9.png and b/OsmAnd/res/drawable-hdpi/box_top_stack_pressed.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_trans.9.png b/OsmAnd/res/drawable-hdpi/box_top_trans.9.png index 879073cf17..0ebd89527b 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_trans.9.png and b/OsmAnd/res/drawable-hdpi/box_top_trans.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_trans_l.9.png b/OsmAnd/res/drawable-hdpi/box_top_trans_l.9.png index cee8a6e42f..c241ee506a 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_trans_l.9.png and b/OsmAnd/res/drawable-hdpi/box_top_trans_l.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_trans_r.9.png b/OsmAnd/res/drawable-hdpi/box_top_trans_r.9.png index 9c98c9b463..8aec0602b8 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_trans_r.9.png and b/OsmAnd/res/drawable-hdpi/box_top_trans_r.9.png differ diff --git a/OsmAnd/res/drawable-hdpi/box_top_trans_stack.9.png b/OsmAnd/res/drawable-hdpi/box_top_trans_stack.9.png index c293b350d5..6710954ef9 100644 Binary files a/OsmAnd/res/drawable-hdpi/box_top_trans_stack.9.png and b/OsmAnd/res/drawable-hdpi/box_top_trans_stack.9.png differ diff --git a/OsmAnd/src/net/osmand/plus/views/mapwidgets/StackWidgetView.java b/OsmAnd/src/net/osmand/plus/views/mapwidgets/StackWidgetView.java index d8e35f8208..0a2b7ff875 100644 --- a/OsmAnd/src/net/osmand/plus/views/mapwidgets/StackWidgetView.java +++ b/OsmAnd/src/net/osmand/plus/views/mapwidgets/StackWidgetView.java @@ -198,7 +198,8 @@ public class StackWidgetView extends ViewGroup { setMeasuredDimension(w, h); } - private final static int MAGIC_CONSTANT_STACK = 3; + // magic constant (should be removed when image will be recropped) + private final static int MAGIC_CONSTANT_STACK = 8; private int shadowColor; @Override protected void onLayout(boolean changed, int left, int top, int right, int bottom) { @@ -208,10 +209,8 @@ public class StackWidgetView extends ViewGroup { if (c.getVisibility() != View.GONE) { if (y == 0) { y += c.getPaddingTop(); - } else { - // magic constant (should be removed when image will be recropped) - y -= MAGIC_CONSTANT_STACK; } + y -= MAGIC_CONSTANT_STACK; c.layout(0, y, cw, y + c.getMeasuredHeight()); y += c.getMeasuredHeight(); y -= c.getPaddingBottom(); @@ -223,10 +222,8 @@ public class StackWidgetView extends ViewGroup { if (c.getVisibility() != View.GONE) { if (y == 0) { y += c.getPaddingTop(); - } else { - // magic constant (should be removed when image will be recropped) - y -= MAGIC_CONSTANT_STACK; } + y -= MAGIC_CONSTANT_STACK; c.layout(0, y, cw, y + c.getMeasuredHeight()); y += c.getMeasuredHeight(); y -= c.getPaddingBottom(); @@ -240,6 +237,7 @@ public class StackWidgetView extends ViewGroup { } if (isCollapsible) { + y -= MAGIC_CONSTANT_STACK; expandView.setVisibility(VISIBLE); int w = expandView.getDrawable().getMinimumWidth(); int h = expandView.getDrawable().getMinimumHeight();