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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java

Issue 2897293002: Adding CrHome-specific implementation for home page tile. (Closed)
Patch Set: Refactor tests and initialization Created 3 years, 7 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/suggestions/MostVisitedSitesBridge.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java
index 9c981b232b4b57cc4f978483d64bf3f2510ba5bb..1597af0f1987b4180ee18be779c3753cbfc0856e 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSites.java
@@ -6,6 +6,8 @@ package org.chromium.chrome.browser.suggestions;
import org.chromium.base.annotations.CalledByNative;
+import javax.annotation.Nullable;
+
/**
* Methods to provide most recent urls, titles and thumbnails.
*/
@@ -41,6 +43,30 @@ interface MostVisitedSites {
}
/**
+ * An interface to provide {@link MostVisitedSites} with platform-specific home page data.
+ */
+ interface HomePageClient {
+ /**
+ * @return True if a home page is active and set.
+ */
+ @CalledByNative("HomePageClient")
+ boolean isHomePageEnabled();
+
+ /**
+ * @return True if the new tab page was set as home page.
+ */
+ @CalledByNative("HomePageClient")
+ boolean isNewTabPageUsedAsHomePage();
+
+ /**
+ * @return The raw URL of the currently set home page.
+ */
+ @CalledByNative("HomePageClient")
+ @Nullable
+ String getHomePageUrl();
+ }
+
+ /**
* This instance must not be used after calling destroy().
*/
void destroy();
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/suggestions/MostVisitedSitesBridge.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698