Fine tune items position of homepage

Since homepage becomes full screen and status bar is 80% of white,
some homepage items are overlappd by status bar.

Enlarge padding size and add a space for fixing this problem.

Test: visual
Bug: 116346521

Change-Id: I7bc9e9a08adafb8fe38bedf527199e4db4424fd0
This commit is contained in:
tmfang
2018-12-25 19:22:46 +08:00
parent af517d51cc
commit 191bde1b75
2 changed files with 10 additions and 4 deletions

View File

@@ -31,8 +31,9 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingTop="@dimen/app_bar_height"
android:descendantFocusability="blocksDescendants">
android:descendantFocusability="blocksDescendants"
android:paddingTop="104dp">
<!-- height of status bar(24dp) + height of action bar(48dp) + top/bottom margins(16dp) -->
<FrameLayout
android:id="@+id/contextual_cards_content"
@@ -52,6 +53,13 @@
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Space
android:layout_width="match_parent"
android:layout_height="@*android:dimen/status_bar_height"
android:background="@android:color/transparent"
app:layout_scrollFlags="scroll|enterAlways"/>
<include layout="@layout/search_bar"/>
</com.google.android.material.appbar.AppBarLayout>
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@@ -105,8 +105,6 @@
<dimen name="search_bar_avatar_size">32dp</dimen>
<dimen name="search_bar_avatar_start_margin">4dp</dimen>
<dimen name="search_bar_avatar_end_margin">16dp</dimen>
<!-- appbar height is equal search bar height (48dp) plus search bar top and bottom margin -->
<dimen name="app_bar_height">80dp</dimen>
<!-- Dimensions for Wifi Assistant Card -->
<dimen name="wifi_assistant_padding_top_bottom">16dp</dimen>