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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java

Issue 1465363002: [Storage] Android - ManageSpace UI, Important Origins, and CBD Dialog (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: compile & comments Created 4 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
Index: chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java b/chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java
index 0f273251fcc1b5eef8babcc710f8911293d52c67..119a586a17b5e97d113aad5a284ae67749ae126e 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/preferences/PrefServiceBridge.java
@@ -88,9 +88,11 @@ public final class PrefServiceBridge {
* See net/base/registry_controlled_domains/registry_controlled_domain.h for more details on
* registrable domains and the current list of effective eTLDs.
* @param domains Important registerable domains.
+ * @param exampleOrigins Example origins for each domain. These can be used to retrieve
+ * favicons.
Ted C 2016/06/06 23:53:55 should be aligned with "Example origins " above
dmurph 2016/06/07 17:57:01 Done.
*/
@CalledByNative("ImportantSitesCallback")
- void onImportantRegisterableDomainsReady(String[] domains);
+ void onImportantRegisterableDomainsReady(String[] domains, String[] exampleOrigins);
}
/**
@@ -815,6 +817,17 @@ public final class PrefServiceBridge {
nativeFetchImportantSites(callback);
}
+ /** @return The maximum number of important sites that will be returned from the call above. */
+ public static int getMaxImportantSites() {
+ return nativeGetMaxImportantSites();
+ }
+
+ /** This lets us mark an origin as important for testing. */
+ @VisibleForTesting
+ public static void markOriginAsImportantForTesting(String origin) {
+ nativeMarkOriginAsImportantForTesting(origin);
+ }
+
/**
* Requests that the web history service finds out if we should inform the user about the
* existence of other forms of browsing history. The response will be asynchronous, through
@@ -1147,6 +1160,8 @@ public final class PrefServiceBridge {
OtherFormsOfBrowsingHistoryListener listener);
private native boolean nativeCanDeleteBrowsingHistory();
private static native void nativeFetchImportantSites(ImportantSitesCallback callback);
+ private static native int nativeGetMaxImportantSites();
+ private static native void nativeMarkOriginAsImportantForTesting(String origin);
private native void nativeSetAutoplayEnabled(boolean allow);
private native void nativeSetAllowCookiesEnabled(boolean allow);
private native void nativeSetBackgroundSyncEnabled(boolean allow);

Powered by Google App Engine
This is Rietveld 408576698