Add line on top of selected tab item
This commit is contained in:
parent
02117a8ffd
commit
095c22a035
7 changed files with 50 additions and 1 deletions
8
OsmAnd/res/drawable/bottom_navigation_item_bg_dark.xml
Normal file
8
OsmAnd/res/drawable/bottom_navigation_item_bg_dark.xml
Normal file
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<item android:drawable="@color/wikivoyage_card_bg_dark" android:state_selected="false" />
|
||||
|
||||
<item android:drawable="@drawable/navigation_item_active_bg_dark" android:state_selected="true" />
|
||||
|
||||
</selector>
|
8
OsmAnd/res/drawable/bottom_navigation_item_bg_light.xml
Normal file
8
OsmAnd/res/drawable/bottom_navigation_item_bg_light.xml
Normal file
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<item android:drawable="@color/wikivoyage_card_bg_light" android:state_selected="false" />
|
||||
|
||||
<item android:drawable="@drawable/navigation_item_active_bg_light" android:state_selected="true" />
|
||||
|
||||
</selector>
|
15
OsmAnd/res/drawable/navigation_item_active_bg_dark.xml
Normal file
15
OsmAnd/res/drawable/navigation_item_active_bg_dark.xml
Normal file
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="@color/active_color_primary_dark" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<item android:top="2dp">
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="@color/wikivoyage_card_bg_dark" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
</layer-list>
|
15
OsmAnd/res/drawable/navigation_item_active_bg_light.xml
Normal file
15
OsmAnd/res/drawable/navigation_item_active_bg_light.xml
Normal file
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="@color/active_color_primary_light" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<item android:top="2dp">
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="@color/wikivoyage_card_bg_light" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
</layer-list>
|
|
@ -206,7 +206,7 @@
|
|||
android:layout_height="@dimen/context_menu_action_buttons_height"
|
||||
android:layout_gravity="bottom"
|
||||
android:background="?attr/wikivoyage_card_bg_color"
|
||||
osmand:itemBackground="?attr/wikivoyage_card_bg_color"
|
||||
osmand:itemBackground="?attr/bottom_navigation_item_background"
|
||||
osmand:itemIconTint="@color/bottom_navigation_color_selector_light"
|
||||
osmand:itemTextColor="@color/bottom_navigation_color_selector_light"
|
||||
osmand:labelVisibilityMode="labeled"
|
||||
|
|
|
@ -142,6 +142,7 @@
|
|||
<attr name="text_input_background" format="reference"/>
|
||||
<attr name="image_help_announcement_time" format="reference"/>
|
||||
<attr name="switch_button_active" format="reference" />
|
||||
<attr name="bottom_navigation_item_background" format="reference" />
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="PagerSlidingTabStrip">
|
||||
|
|
|
@ -249,6 +249,7 @@
|
|||
<item name="text_input_background">@color/text_input_background_light</item>
|
||||
<item name="image_help_announcement_time">@drawable/img_help_announcement_time_day</item>
|
||||
<item name="switch_button_active">@color/switch_button_active_light</item>
|
||||
<item name="bottom_navigation_item_background">@drawable/bottom_navigation_item_bg_light</item>
|
||||
</style>
|
||||
|
||||
<style name="ToolbarStyle" parent="@style/Widget.AppCompat.Toolbar">
|
||||
|
@ -547,6 +548,7 @@
|
|||
<item name="text_input_background">@color/text_input_background_dark</item>
|
||||
<item name="image_help_announcement_time">@drawable/img_help_announcement_time_night</item>
|
||||
<item name="switch_button_active">@color/switch_button_active_dark</item>
|
||||
<item name="bottom_navigation_item_background">@drawable/bottom_navigation_item_bg_dark</item>
|
||||
</style>
|
||||
|
||||
<style name="FreeVersionBanner" parent="OsmandDarkTheme">
|
||||
|
|
Loading…
Reference in a new issue