• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!--
3    Copyright (C) 2018 The Android Open Source Project
4
5    Licensed under the Apache License, Version 2.0 (the "License");
6    you may not use this file except in compliance with the License.
7    You may obtain a copy of the License at
8
9        http://www.apache.org/licenses/LICENSE-2.0
10
11    Unless required by applicable law or agreed to in writing, software
12    distributed under the License is distributed on an "AS IS" BASIS,
13    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14    See the License for the specific language governing permissions and
15    limitations under the License.
16-->
17
18<RelativeLayout
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    android:id="@+id/header"
21    android:layout_width="match_parent"
22    android:layout_height="wrap_content"
23    android:clipChildren="false"
24    android:clipToPadding="false"
25    android:gravity="center_vertical"
26    android:orientation="horizontal">
27
28    <FrameLayout
29        android:id="@+id/exit_button_container"
30        android:layout_width="@dimen/panel_margin"
31        android:layout_height="@dimen/app_bar_height"
32        android:layout_alignParentStart="true"
33        android:layout_centerVertical="true"
34        android:background="?android:attr/selectableItemBackground"
35        android:clickable="true"
36        android:focusable="true">
37        <ImageButton
38            android:layout_width="@dimen/icon_size"
39            android:layout_height="@dimen/icon_size"
40            android:layout_gravity="center"
41            android:adjustViewBounds="true"
42            android:background="@null"
43            android:clickable="false"
44            android:focusable="false"
45            android:scaleType="fitXY"
46            android:src="@drawable/ic_clear_black"
47            android:tint="@color/icon_tint"/>
48    </FrameLayout>
49
50    <TextView
51        style="@style/TitleText"
52        android:layout_width="wrap_content"
53        android:layout_height="@dimen/app_bar_height"
54        android:layout_toEndOf="@id/exit_button_container"
55        android:gravity="center_vertical"
56        android:text="@string/all_apps"
57    />
58
59    <FrameLayout
60        android:id="@+id/search_button_container"
61        android:layout_width="@dimen/panel_margin"
62        android:layout_height="@dimen/app_grid_touch_target_size"
63        android:layout_alignParentEnd="true"
64        android:layout_centerVertical="true"
65        android:background="?android:attr/selectableItemBackground"
66        android:clickable="true"
67        android:focusable="true"
68        android:visibility="gone"
69    >
70        <ImageButton
71            android:layout_width="@dimen/icon_size"
72            android:layout_height="@dimen/icon_size"
73            android:layout_gravity="center"
74            android:adjustViewBounds="true"
75            android:background="@null"
76            android:clickable="false"
77            android:focusable="false"
78            android:scaleType="fitXY"
79            android:src="@drawable/ic_search_black"
80            android:tint="@color/icon_tint"/>
81    </FrameLayout>
82
83    <View
84        style="@style/HorizontalLineDivider"
85        android:layout_alignBottom="@id/exit_button_container"/>
86</RelativeLayout>
87
88