1<?xml version="1.0" encoding="utf-8"?>
2
3<!--
4  Copyright 2015 Google Inc. All rights reserved.
5
6  Licensed under the Apache License, Version 2.0 (the "License");
7  you may not use this file except in compliance with the License.
8  You may obtain a copy of the License at
9
10       http://www.apache.org/licenses/LICENSE-2.0
11
12  Unless required by applicable law or agreed to in writing, software
13  distributed under the License is distributed on an "AS IS" BASIS,
14  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  See the License for the specific language governing permissions and
16  limitations under the License.
17  -->
18
19<android.support.design.widget.CoordinatorLayout
20    xmlns:android="http://schemas.android.com/apk/res/android"
21    xmlns:app="http://schemas.android.com/apk/res-auto"
22    android:layout_width="match_parent"
23    android:layout_height="match_parent">
24
25    <LinearLayout
26        android:orientation="vertical"
27        android:layout_width="match_parent"
28        android:layout_height="match_parent"
29        android:weightSum="100">
30
31        <ImageView
32            android:id="@+id/imageView"
33            android:layout_width="match_parent"
34            android:layout_height="0dp"
35            android:layout_weight="50"
36            android:scaleType="centerCrop"
37            android:transitionName="image" />
38
39        <LinearLayout
40            android:id="@+id/textLayout"
41            android:layout_width="match_parent"
42            android:layout_height="wrap_content"
43            android:background="?colorPrimary"
44            android:orientation="vertical"
45            android:paddingStart="@dimen/keyline2"
46            android:paddingEnd="@dimen/keyline3"
47            android:paddingTop="@dimen/standard_margin"
48            android:paddingBottom="@dimen/standard_margin"
49            android:elevation="2dp">
50
51            <TextView
52                android:id="@+id/nameTextView"
53                android:layout_width="match_parent"
54                android:layout_height="wrap_content"
55                android:maxLines="2"
56                android:ellipsize="end"
57                android:textIsSelectable="true"
58                style="@style/TextAppearance.AppCompat.Title.Inverse" />
59
60            <TextView
61                android:id="@+id/distanceTextView"
62                android:layout_width="wrap_content"
63                android:layout_height="wrap_content"
64                style="@style/TextAppearance.AppCompat.Subhead.Inverse" />
65
66        </LinearLayout>
67
68        <ScrollView
69            android:layout_width="match_parent"
70            android:layout_height="0dp"
71            android:layout_weight="50"
72            android:paddingTop="@dimen/standard_margin"
73            android:paddingBottom="@dimen/standard_margin"
74            android:scrollbarStyle="outsideOverlay"
75            android:clipToPadding="false">
76
77            <TextView
78                android:id="@+id/descriptionTextView"
79                android:layout_height="wrap_content"
80                android:layout_width="match_parent"
81                android:textIsSelectable="true"
82                style="@style/TextAppearance.AppCompat.Body1"
83                android:paddingStart="@dimen/keyline2"
84                android:paddingEnd="@dimen/keyline3" />
85
86        </ScrollView>
87
88    </LinearLayout>
89
90    <android.support.design.widget.FloatingActionButton
91        android:id="@+id/mapFab"
92        android:layout_height="wrap_content"
93        android:layout_width="wrap_content"
94        android:src="@drawable/ic_action_map"
95        app:layout_anchor="@id/textLayout"
96        app:layout_anchorGravity="bottom|start"
97        app:rippleColor="@color/colorFabRipple"
98        android:layout_marginStart="@dimen/fab_margin"
99        android:clickable="true" />
100
101</android.support.design.widget.CoordinatorLayout>