Index: chrome/android/java/src/org/chromium/chrome/browser/ntp/MostVisitedItem.java |
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ntp/MostVisitedItem.java b/chrome/android/java/src/org/chromium/chrome/browser/ntp/MostVisitedItem.java |
index 3e83b9e264149fb990bfd8a9dcc46afb3ca03d35..75a4e78a0616bd46811f65e8451bffa0473110db 100644 |
--- a/chrome/android/java/src/org/chromium/chrome/browser/ntp/MostVisitedItem.java |
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ntp/MostVisitedItem.java |
@@ -49,25 +49,31 @@ public class MostVisitedItem implements OnCreateContextMenuListener, |
private MostVisitedItemManager mManager; |
private String mTitle; |
private String mUrl; |
+ private String mWhitelistIconPath; |
private boolean mOfflineAvailable; |
private int mIndex; |
private int mTileType; |
private View mView; |
/** |
- * Constructs a MostVisitedItem with the given manager, title, URL, index, and view. |
+ * Constructs a MostVisitedItem with the given manager, title, URL, whitelist icon path, index, |
+ * and |
+ * view. |
Marc Treib
2016/03/16 11:06:03
nit: merge into the previous line please.
atanasova
2016/03/16 17:58:17
Done.
|
* |
* @param manager The NewTabPageManager used to handle clicks and context menu events. |
* @param title The title of the page. |
* @param url The URL of the page. |
+ * @param whitelistIconPath The path to the icon image file, if this is a whitelisted most |
+ * visited item. Empty otherwise. |
* @param offlineAvailable Whether there is an offline copy of the URL available. |
* @param index The index of this item in the list of most visited items. |
*/ |
public MostVisitedItem(MostVisitedItemManager manager, String title, String url, |
- boolean offlineAvailable, int index) { |
+ String whitelistIconPath, boolean offlineAvailable, int index) { |
mManager = manager; |
mTitle = title; |
mUrl = url; |
+ mWhitelistIconPath = whitelistIconPath; |
mOfflineAvailable = offlineAvailable; |
mIndex = index; |
mTileType = MostVisitedTileType.NONE; |
@@ -106,6 +112,13 @@ public class MostVisitedItem implements OnCreateContextMenuListener, |
} |
/** |
+ * @return The path of the whitelist icon associated with the URL. |
+ */ |
+ public String getWhitelistIconPath() { |
+ return mWhitelistIconPath; |
+ } |
+ |
+ /** |
* @return Whether this item is available offline. |
*/ |
public boolean isOfflineAvailable() { |