[android] add: Elevation shadows for search/downloader panels.

This commit is contained in:
a.marchuk 2015-07-22 14:00:34 +03:00 committed by Alex Zolotarev
parent 8350ccb9c2
commit 8bdcbb2613
12 changed files with 33 additions and 23 deletions

View file

@ -32,7 +32,7 @@
<com.mapswithme.maps.widget.placepage.PlacePageView
android:id="@+id/info_box"
style="@style/MwmWidget.PlacePage.Floating"
style="@style/MwmWidget.Floating.PlacePage"
android:layout_width="360dp"
android:layout_height="match_parent"
android:layout_below="@+id/fl__routing"

View file

@ -27,7 +27,7 @@
<com.mapswithme.maps.widget.placepage.PlacePageView
android:id="@+id/info_box"
style="@style/MwmWidget.PlacePage.Floating"
style="@style/MwmWidget.Floating.PlacePage"
android:layout_width="@dimen/panel_width"
android:layout_height="wrap_content"
android:layout_below="@+id/toolbar_search"
@ -43,9 +43,11 @@
<FrameLayout
android:id="@+id/fragment_container"
android:layout_width="@dimen/panel_width"
style="@style/MwmWidget.Floating"
android:layout_width="@dimen/floating_panel_width"
android:layout_height="match_parent"
android:layout_margin="@dimen/margin_base"/>
android:padding="@dimen/margin_base"
android:clipToPadding="false"/>
<include
android:id="@+id/toolbar_search"

View file

@ -48,9 +48,10 @@
<FrameLayout
android:id="@+id/fragment_container"
android:layout_width="@dimen/panel_width"
android:layout_width="@dimen/floating_panel_width"
android:layout_height="match_parent"
android:layout_margin="@dimen/margin_base"/>
android:padding="@dimen/margin_base"
android:clipToPadding="false"/>
<com.mapswithme.maps.widget.BottomButtonsLayout
android:id="@+id/map_bottom_buttons"

View file

@ -1,8 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
style="@style/MwmWidget.Floating"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
android:orientation="vertical"
android:background="@android:color/white">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
@ -33,8 +35,7 @@
<ListView
android:id="@android:id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/white"/>
android:layout_height="match_parent"/>
</FrameLayout>

View file

@ -26,7 +26,7 @@
<com.mapswithme.maps.widget.placepage.PlacePageView
android:id="@+id/info_box"
style="@style/MwmWidget.PlacePage.Floating"
style="@style/MwmWidget.Floating.PlacePage"
android:layout_width="@dimen/panel_width"
android:layout_height="wrap_content"
android:layout_margin="@dimen/margin_base"
@ -41,9 +41,10 @@
<FrameLayout
android:id="@+id/fragment_container"
android:layout_width="@dimen/panel_width"
android:layout_width="@dimen/floating_panel_width"
android:layout_height="match_parent"
android:layout_margin="@dimen/margin_base"/>
android:padding="@dimen/margin_base"
android:clipToPadding="false"/>
<include
android:id="@+id/toolbar_search"

View file

@ -1,8 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
style="@style/MwmWidget.Floating"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
android:orientation="vertical"
android:background="@android:color/white">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"

View file

@ -1,9 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
style="@style/MwmWidget.Floating"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
android:orientation="vertical"
android:background="@android:color/white">
<include
android:id="@+id/toolbar"
layout="@layout/toolbar_with_search"
@ -13,8 +14,7 @@
<FrameLayout
style="@style/MwmWidget.FrameLayout.Elevation"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/white">
android:layout_height="match_parent">
<include
layout="@layout/recycler_default"

View file

@ -2,8 +2,7 @@
<resources>
<style name="MwmWidget.FrameLayout.Elevation"/>
<style name="MwmWidget.PlacePage.Floating">
<style name="MwmWidget.Floating">
<item name="android:elevation">@dimen/appbar_elevation</item>
<item name="android:background">@color/bg_top_panels</item>
</style>
</resources>

View file

@ -44,6 +44,8 @@
<dimen name="routing_button_width">51dp</dimen>
<dimen name="routing_progress_size">32dp</dimen>
<dimen name="panel_width">400dp</dimen>
<dimen name="floating_panel_width">432dp</dimen>
<!-- direction fragment -->
<dimen name="margin_direction_small">8dp</dimen>
<dimen name="margin_direction_big">20dp</dimen>

View file

@ -120,9 +120,12 @@
<item name="android:background">@drawable/bg_btn_green</item>
</style>
<style name="MwmWidget.PlacePage"/>
<style name="MwmWidget.Floating"/>
<style name="MwmWidget.PlacePage.Floating"/>
<style name="MwmWidget.Floating.PlacePage"
parent="MwmWidget.Floating">
<item name="android:background">@color/bg_top_panels</item>
</style>
<style name="MwmWidget.PlacePage.EditText" parent="Widget.AppCompat.EditText">
<item name="android:imeOptions">actionDone</item>

View file

@ -1087,10 +1087,8 @@ public class MWMActivity extends BaseMwmFragmentActivity
private boolean popFragment()
{
for (String tag : new String[]{SearchFragment.class.getName(), DownloadFragment.class.getName()})
{
if (popFragment(tag))
return true;
}
return false;
}

View file

@ -65,6 +65,7 @@ public abstract class BaseMwmRecyclerFragment extends Fragment
return mRecycler;
}
@Override
public void onResume()
{
super.onResume();