diff --git a/OsmAnd/res/layout/bottom_sheet_item_with_two_text.xml b/OsmAnd/res/layout/bottom_sheet_item_with_two_text.xml new file mode 100644 index 0000000000..eb2efab2ef --- /dev/null +++ b/OsmAnd/res/layout/bottom_sheet_item_with_two_text.xml @@ -0,0 +1,44 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/OsmAnd/res/layout/route_line_appearance.xml b/OsmAnd/res/layout/route_line_appearance.xml index e5410cdd2f..5564b3b867 100644 --- a/OsmAnd/res/layout/route_line_appearance.xml +++ b/OsmAnd/res/layout/route_line_appearance.xml @@ -19,9 +19,7 @@ android:layout_height="wrap_content" android:background="?attr/bg_color" android:minHeight="@dimen/bottom_sheet_title_height" - android:orientation="vertical" - android:paddingLeft="@dimen/content_padding" - android:paddingRight="@dimen/content_padding"> + android:orientation="vertical"> - - - - - + diff --git a/OsmAnd/res/layout/route_line_color_card.xml b/OsmAnd/res/layout/route_line_color_card.xml index c25332de88..f8db414f16 100644 --- a/OsmAnd/res/layout/route_line_color_card.xml +++ b/OsmAnd/res/layout/route_line_color_card.xml @@ -9,43 +9,8 @@ - - - - - - - - + android:orientation="horizontal" + android:paddingTop="@dimen/content_padding_small"> + + - - - - - - - - colorCard.getViewHeight() + headerTitle.getBottom()) { + selectedHeader = widthCard; + } else { + selectedHeader = colorCard; + } + selectedHeader.onNeedHeaderUpdate(); + } + private void initVisibleRect() { MapActivity ctx = getMapActivity(); int screenHeight = AndroidUtils.getScreenHeight(ctx); @@ -385,7 +424,6 @@ public class RouteLineAppearanceFragment extends ContextMenuScrollFragment imple colorCard.onColorSelected(prevColor, newColor); } - @Override public void onSelectedColorChanged() { updateColorItems(); } @@ -418,7 +456,6 @@ public class RouteLineAppearanceFragment extends ContextMenuScrollFragment imple } } - @Override public void onMapThemeUpdated(@NonNull DayNightMode mapTheme) { changeMapTheme(mapTheme); updateColorItems(); @@ -435,4 +472,14 @@ public class RouteLineAppearanceFragment extends ContextMenuScrollFragment imple public interface OnApplyRouteLineListener { void applyRouteLineAppearance(@NonNull RouteLineDrawInfo routeLineDrawInfo); } + + public interface HeaderUiAdapter { + void onHeaderUpdate(@NonNull HeaderInfo headerInfo, + @NonNull String title, + @NonNull String description); + } + + public interface HeaderInfo { + void onNeedHeaderUpdate(); + } }