Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(284)

Unified Diff: chrome/android/java/res/layout/new_tab_page_status_card.xml

Issue 2024933002: [NTP Snippets] Show a status card when there are no available snippets (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased and address comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPage.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/res/layout/new_tab_page_status_card.xml
diff --git a/chrome/android/java/res/layout/new_tab_page_status_card.xml b/chrome/android/java/res/layout/new_tab_page_status_card.xml
new file mode 100644
index 0000000000000000000000000000000000000000..b7a00c4fac09eacb93513d63b16be9a7d3b96c31
--- /dev/null
+++ b/chrome/android/java/res/layout/new_tab_page_status_card.xml
@@ -0,0 +1,50 @@
+<?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. -->
+
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:chrome="http://schemas.android.com/apk/res-auto"
+ android:id="@+id/status_card_view"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="end"
+ android:orientation="vertical"
+ android:padding="@dimen/snippets_padding_and_peeking_card_height"
+ android:background="@color/snippets_background_color">
+
+ <org.chromium.ui.widget.TextViewWithLeading
+ android:id="@+id/status_headline"
+ android:text="@string/ntp_status_card_title_empty"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textSize="16sp"
+ android:textColor="@color/snippets_headline_text_color"
+ chrome:leading="24dp" />
+
+ <org.chromium.ui.widget.TextViewWithLeading
+ android:id="@+id/status_snippet"
+ android:text="@string/ntp_status_card_body_empty"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginTop="8dp"
+ android:textSize="14sp"
+ android:textColor="@color/snippets_text_color"
+ chrome:leading="20dp" />
+
+ <!-- Negative marginEnd to balance the parent's padding. Buttons are
+ supposed to have 8dp margin while we have a 16dp margin at the parent
+ level. -->
+ <Button
+ android:id="@+id/reload_button"
+ style="@style/ButtonCompatBorderless"
+ android:layout_marginEnd="-8dp"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/reload"
+ android:textAllCaps="true"
+ android:textColor="@color/light_active_color"
+ android:textSize="15sp" />
+
+</LinearLayout>
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPage.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698