| <?xml version="1.0" encoding="utf-8"?> |
| <!-- Copyright 2016 The Chromium Authors. All rights reserved. |
| Use of this source code is governed by a BSD-style license that can be |
| found in the LICENSE file. --> |
| <org.chromium.chrome.browser.ntp.NewTabPageLayout |
| xmlns:android="http://schemas.android.com/apk/res/android" |
| xmlns:app="http://schemas.android.com/apk/res-auto" |
| android:id="@+id/ntp_content" |
| android:layout_width="match_parent" |
| android:layout_height="wrap_content" |
| android:layout_gravity="center_horizontal" |
| android:orientation="vertical" |
| android:gravity="center" |
| android:paddingTop="@dimen/toolbar_height_no_shadow" |
| android:visibility="gone" > |
| |
| <!-- Search provider logo --> |
| <org.chromium.chrome.browser.ntp.LogoView |
| android:id="@+id/search_provider_logo" |
| android:layout_width="wrap_content" |
| android:layout_height="@dimen/ntp_logo_height" |
| android:layout_marginStart="16dp" |
| android:layout_marginEnd="16dp" |
| android:layout_marginTop="26dp" |
| android:layout_marginBottom="23dp" /> |
| |
| <!-- Search box --> |
| <view |
| class="org.chromium.chrome.browser.ntp.NewTabPageLayout$SearchBoxContainerView" |
| android:id="@+id/search_box" |
| android:layout_width="match_parent" |
| android:layout_height="@dimen/ntp_search_box_height" |
| android:layout_marginStart="10dp" |
| android:layout_marginEnd="10dp" |
| android:layout_marginTop="0dp" |
| android:layout_marginBottom="1dp" |
| android:gravity="center_vertical" |
| android:addStatesFromChildren="true" |
| android:background="@drawable/card_single" |
| android:orientation="horizontal" |
| android:paddingStart="2dp" |
| android:paddingEnd="2dp" |
| android:paddingTop="3dp" |
| android:paddingBottom="3dp" > |
| <EditText |
| android:id="@+id/search_box_text" |
| android:layout_width="0dp" |
| android:layout_height="match_parent" |
| android:layout_marginStart="12dp" |
| android:layout_marginEnd="12dp" |
| android:layout_weight="1" |
| android:background="@null" |
| android:drawableStart="@drawable/ic_logo_googleg_24dp" |
| android:drawablePadding="@dimen/ntp_search_box_logo_padding" |
| android:ellipsize="end" |
| android:focusableInTouchMode="false" |
| android:focusable="false" |
| android:gravity="center_vertical" |
| android:inputType="text" |
| android:singleLine="true" |
| android:textAppearance="@style/TextAppearance.NewTabPageSearchBoxText" /> |
| <org.chromium.chrome.browser.widget.TintedImageView |
| android:id="@+id/voice_search_button" |
| android:layout_width="wrap_content" |
| android:layout_height="wrap_content" |
| android:layout_marginEnd="12dp" |
| android:contentDescription="@string/accessibility_toolbar_btn_mic" |
| android:src="@drawable/btn_mic" |
| app:chrometint="@color/dark_mode_tint" /> |
| </view> |
| |
| <ViewStub |
| android:id="@+id/shortcuts_stub" |
| android:layout_width="match_parent" |
| android:layout_height="wrap_content" |
| android:inflatedId="@+id/shortcuts" |
| android:layout="@layout/ntp_shortcuts" /> |
| |
| <!-- Middle spacer --> |
| <View |
| android:id="@+id/ntp_middle_spacer" |
| android:layout_width="0dp" |
| android:layout_height="0dp" |
| android:layout_weight="0" |
| android:visibility="invisible" /> |
| |
| <!-- Insertion point of the SiteSectionView, see NewTabPageLayout#insertSiteSection() --> |
| |
| <ViewStub |
| android:id="@+id/explore_sites_stub" |
| android:layout_width="match_parent" |
| android:layout_height="wrap_content" |
| android:inflatedId="@+id/explore_sites" |
| android:layout="@layout/experimental_explore_sites_section" /> |
| |
| <!-- Site suggestion tile grid placeholder --> |
| <ViewStub |
| android:id="@+id/tile_grid_placeholder_stub" |
| android:layout_width="match_parent" |
| android:layout_height="wrap_content" |
| android:layout_weight="1" |
| android:inflatedId="@+id/tile_grid_placeholder" |
| android:layout="@layout/new_tab_page_tile_grid_placeholder" /> |
| |
| <!-- Spacer for when there is no search provider logo. --> |
| <View |
| android:id="@+id/no_search_logo_spacer" |
| android:layout_width="match_parent" |
| android:layout_height="0dp" |
| android:layout_weight="1" |
| android:visibility="gone" /> |
| </org.chromium.chrome.browser.ntp.NewTabPageLayout> |