diff options
author | finnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-15 22:05:52 +0000 |
---|---|---|
committer | finnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-15 22:05:52 +0000 |
commit | 34fce2a5030cb53a1e2decb37b5f7517f98457f7 (patch) | |
tree | 06613242809aa025f8f152ffc9e7b6a923c7be4a | |
parent | 910a39ca11c5cfa20cb03e408586b63d3ac321d8 (diff) | |
download | chromium_src-34fce2a5030cb53a1e2decb37b5f7517f98457f7.zip chromium_src-34fce2a5030cb53a1e2decb37b5f7517f98457f7.tar.gz chromium_src-34fce2a5030cb53a1e2decb37b5f7517f98457f7.tar.bz2 |
Unified the color definitions for the dividers so that extension shelf is using the same values as the bookmark bar. The bookmark bar dividers looked much better against very light background than the extension shelf ones did.
BUG=18452
TEST=The dividers should look like the bookmark ones and should not look bad against very light colored backgrounds.
Review URL: http://codereview.chromium.org/204026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26274 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/views/bookmark_bar_view.cc | 12 | ||||
-rw-r--r-- | chrome/browser/views/detachable_toolbar_view.cc | 5 | ||||
-rw-r--r-- | chrome/browser/views/detachable_toolbar_view.h | 5 | ||||
-rw-r--r-- | chrome/browser/views/extensions/extension_shelf.cc | 7 |
4 files changed, 15 insertions, 14 deletions
diff --git a/chrome/browser/views/bookmark_bar_view.cc b/chrome/browser/views/bookmark_bar_view.cc index 24b287c..ff1cbef 100644 --- a/chrome/browser/views/bookmark_bar_view.cc +++ b/chrome/browser/views/bookmark_bar_view.cc @@ -77,9 +77,6 @@ static SkBitmap* kDefaultFavIcon = NULL; // Icon used for folders. static SkBitmap* kFolderIcon = NULL; -// Border colors for the BookmarBarView. -static const SkColor kTopBorderColor = SkColorSetRGB(222, 234, 248); - // Offset for where the menu is shown relative to the bottom of the // BookmarkBarView. static const int kMenuOffset = 3; @@ -104,10 +101,6 @@ static const int kSeparatorWidth = 4; // Starting x-coordinate of the separator line within a separator. static const int kSeparatorStartX = 2; -// Border color along the left edge of the view representing the most recently -// view pages. -static const SkColor kSeparatorColor = SkColorSetRGB(194, 205, 212); - // Left-padding for the instructional text. static const int kInstructionsPadding = 6; @@ -295,8 +288,9 @@ class BookmarkBarView::ButtonSeparatorView : public views::View { virtual void Paint(gfx::Canvas* canvas) { DetachableToolbarView::PaintVerticalDivider( - canvas, kSeparatorStartX, height(), 1, kTopBorderColor, - kSeparatorColor, + canvas, kSeparatorStartX, height(), 1, + DetachableToolbarView::kEdgeDividerColor, + DetachableToolbarView::kMiddleDividerColor, GetThemeProvider()->GetColor(BrowserThemeProvider::COLOR_TOOLBAR)); } diff --git a/chrome/browser/views/detachable_toolbar_view.cc b/chrome/browser/views/detachable_toolbar_view.cc index 9cc81d2..8363620 100644 --- a/chrome/browser/views/detachable_toolbar_view.cc +++ b/chrome/browser/views/detachable_toolbar_view.cc @@ -12,6 +12,11 @@ // How round the 'new tab' style bookmarks bar is. static const int kNewtabBarRoundness = 5; +const SkColor DetachableToolbarView::kEdgeDividerColor = + SkColorSetRGB(222, 234, 248); +const SkColor DetachableToolbarView::kMiddleDividerColor = + SkColorSetRGB(194, 205, 212); + // static void DetachableToolbarView::PaintBackgroundDetachedMode(gfx::Canvas* canvas, views::View* view) { diff --git a/chrome/browser/views/detachable_toolbar_view.h b/chrome/browser/views/detachable_toolbar_view.h index f831ea1..266a41d 100644 --- a/chrome/browser/views/detachable_toolbar_view.h +++ b/chrome/browser/views/detachable_toolbar_view.h @@ -14,6 +14,11 @@ struct SkRect; // from the Chrome frame, such as the BookmarkBarView and the Extension shelf. class DetachableToolbarView : public views::View { public: + // The color gradient start value close to the edge of the divider. + static const SkColor kEdgeDividerColor; + // The color gradient value for the middle of the divider. + static const SkColor kMiddleDividerColor; + DetachableToolbarView() {} virtual ~DetachableToolbarView() {} diff --git a/chrome/browser/views/extensions/extension_shelf.cc b/chrome/browser/views/extensions/extension_shelf.cc index 2928f75..3d2b42f 100644 --- a/chrome/browser/views/extensions/extension_shelf.cc +++ b/chrome/browser/views/extensions/extension_shelf.cc @@ -62,9 +62,6 @@ static const int kNewtabExtraVerMargin = 2; // Height of the toolstrip within the shelf. static const int kToolstripHeight = kShelfHeight - (kTopMargin + kBottomMargin); -// Colors for the ExtensionShelf. -static const SkColor kDividerHighlightColor = SkColorSetRGB(247, 250, 253); - // Handle padding. static const int kHandlePadding = 4; @@ -659,8 +656,8 @@ void ExtensionShelf::PaintChildren(gfx::Canvas* canvas) { DetachableToolbarView::PaintVerticalDivider( canvas, right, height(), vertical_padding, - SK_ColorWHITE, - kDividerHighlightColor, + DetachableToolbarView::kEdgeDividerColor, + DetachableToolbarView::kMiddleDividerColor, GetThemeProvider()->GetColor(BrowserThemeProvider::COLOR_TOOLBAR)); } } |