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

Unified Diff: chrome/browser/ui/cocoa/location_bar/star_decoration.mm

Issue 1787023003: Change star decoration to blue under MD (Mac). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/location_bar/star_decoration.mm
diff --git a/chrome/browser/ui/cocoa/location_bar/star_decoration.mm b/chrome/browser/ui/cocoa/location_bar/star_decoration.mm
index d1937f9323d2fa1bbba6efb7603d49419e46ed1c..08ee25ee35afb7f7f4843156c3213ddfc3a6c4a5 100644
--- a/chrome/browser/ui/cocoa/location_bar/star_decoration.mm
+++ b/chrome/browser/ui/cocoa/location_bar/star_decoration.mm
@@ -13,6 +13,7 @@
#include "grit/theme_resources.h"
#include "ui/base/l10n/l10n_util_mac.h"
#include "ui/base/material_design/material_design_controller.h"
+#include "ui/gfx/color_palette.h"
#include "ui/gfx/image/image_skia_util_mac.h"
#include "ui/gfx/paint_vector_icon.h"
#include "ui/gfx/vector_icons_public.h"
@@ -45,13 +46,16 @@ void StarDecoration::SetStarred(bool starred, bool locationBarIsDark) {
gfx::VectorIconId iconId = starred_ ?
gfx::VectorIconId::LOCATION_BAR_STAR_ACTIVE :
gfx::VectorIconId::LOCATION_BAR_STAR;
+ SkColor starColor = gfx::kPlaceholderColor;
if (locationBarIsDark) {
- theImage = NSImageFromImageSkia(gfx::CreateVectorIcon(
- iconId, 16, SK_ColorWHITE));
+ starColor = SK_ColorWHITE;
+ } else if (starred_) {
+ starColor = gfx::kGoogleBlue500;
} else {
- theImage = NSImageFromImageSkia(gfx::CreateVectorIcon(
- iconId, 16, SkColorSetARGB(0xFF, 0x5A, 0x5A, 0x5A)));
+ starColor = gfx::kChromeIconGrey;
}
+ theImage = NSImageFromImageSkia(gfx::CreateVectorIcon(
+ iconId, 16, starColor));
SetImage(theImage);
} else {
SetImage(OmniboxViewMac::ImageForResource(image_id));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698