<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2018 The Chromium Authors
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->
<org.chromium.components.browser_ui.widget.MaterialCardViewNoShadow
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:clickable="true"
android:focusable="true"
style="@style/MaterialCardStyle">
<androidx.gridlayout.widget.GridLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:columnCount="1"
app:rowCount="2">
<!-- Set the src attribute in Java to wrap the drawable properly. -->
<org.chromium.components.browser_ui.widget.async_image.ForegroundRoundedCornerImageView
android:id="@+id/thumbnail"
android:layout_width="match_parent"
android:layout_height="200dp"
android:layout_marginTop="1dp"
android:layout_marginStart="1dp"
android:layout_marginEnd="1dp"
android:scaleType="centerInside"
android:adjustViewBounds="true"
app:layout_column="0"
app:layout_row="0"
app:layout_gravity="center"
app:cornerRadiusTopStart="@dimen/card_rounded_corner_radius"
app:cornerRadiusTopEnd="@dimen/card_rounded_corner_radius"
app:roundedfillColor="@color/baseline_neutral_70"
app:foregroundCompat="@drawable/async_image_view_waiting" />
<org.chromium.chrome.browser.download.home.list.view.CircularProgressView
android:id="@+id/action_button"
app:layout_column="0"
app:layout_row="0"
app:layout_gravity="center"
style="@style/LargeCircularProgress" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:baselineAligned="false"
app:layout_column="0"
app:layout_row="1">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginStart="16dp"
android:layout_weight="1">
<TextView
android:id="@+id/title"
style="@style/DownloadItemText"
android:layout_width="match_parent"
android:layout_marginTop="11dp"
android:textAppearance="@style/TextAppearance.TextLarge.Primary" />
<TextView
android:id="@+id/caption"
style="@style/DownloadItemText"
android:layout_width="match_parent"
android:layout_marginBottom="11dp"
android:textAppearance="@style/TextAppearance.TextMedium.Secondary" />
</LinearLayout>
<org.chromium.ui.widget.ChromeImageButton
android:id="@+id/cancel_button"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_weight="0"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/download_notification_cancel_button"
android:src="@drawable/btn_close"
app:tint="@macro/default_icon_color" />
</LinearLayout>
</androidx.gridlayout.widget.GridLayout>
</org.chromium.components.browser_ui.widget.MaterialCardViewNoShadow>