Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/webapps/WebappActivity.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebappActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebappActivity.java |
| index 0d5ca4d166536798505232c421e02d634e2824f7..a07dfd71ffa9a1eccea8d79ce60db3efd2fa3af3 100644 |
| --- a/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebappActivity.java |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/webapps/WebappActivity.java |
| @@ -262,6 +262,10 @@ public class WebappActivity extends FullScreenActivity { |
| ? getActivityTab().getTitle() : mWebappInfo.title(); |
| Bitmap icon = mWebappInfo.icon() == null |
| ? getActivityTab().getFavicon() : mWebappInfo.icon(); |
| + |
| + if (mBrandColor == null && mWebappInfo.themeColor() != -1) { |
|
mlamouri (slow - plz ping)
2015/07/17 13:28:29
ditto
Lalit Maganti
2015/07/17 14:34:15
Done.
|
| + mBrandColor = (int) mWebappInfo.themeColor(); |
| + } |
| int color = mBrandColor == null |
| ? getResources().getColor(R.color.default_primary_color) : mBrandColor; |
| @@ -330,7 +334,7 @@ public class WebappActivity extends FullScreenActivity { |
| * @param orientation Default orientation for the activity. |
| */ |
| public static void launchInstance(Context context, String id, String url, String icon, |
| - String title, int orientation, int source) { |
| + String title, int orientation, int source, long themeColor) { |
| String activityName = WebappActivity.class.getName(); |
| if (!FeatureUtilities.isDocumentModeEligible(context)) { |
| // Specifically assign the app to a particular WebappActivity instance. |
| @@ -347,6 +351,7 @@ public class WebappActivity extends FullScreenActivity { |
| webappIntent.putExtra(ShortcutHelper.EXTRA_TITLE, title); |
| webappIntent.putExtra(ShortcutHelper.EXTRA_ORIENTATION, orientation); |
| webappIntent.putExtra(ShortcutHelper.EXTRA_SOURCE, source); |
| + webappIntent.putExtra(ShortcutHelper.EXTRA_THEME_COLOR, themeColor); |
| // On L, firing intents with the exact same data should relaunch a particular Activity. |
| webappIntent.setAction(Intent.ACTION_VIEW); |