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

Unified Diff: chrome/browser/ui/views/detachable_toolbar_view.cc

Issue 798283002: Cleanup: Move PaintVerticalDivider() into bookmark_bar_view.cc. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 | « chrome/browser/ui/views/detachable_toolbar_view.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/detachable_toolbar_view.cc
diff --git a/chrome/browser/ui/views/detachable_toolbar_view.cc b/chrome/browser/ui/views/detachable_toolbar_view.cc
index 998cd1bcde2711eabc402ee6783f01267dd2711f..6b70d0da68ab1e720d944d7bee9b5c85fcb79e6b 100644
--- a/chrome/browser/ui/views/detachable_toolbar_view.cc
+++ b/chrome/browser/ui/views/detachable_toolbar_view.cc
@@ -11,7 +11,6 @@
#include "ui/base/theme_provider.h"
#include "ui/gfx/canvas.h"
#include "ui/gfx/image/image_skia.h"
-#include "ui/gfx/skia_util.h"
#include "ui/views/window/non_client_view.h"
// static
@@ -59,34 +58,3 @@ void DetachableToolbarView::PaintHorizontalBorder(gfx::Canvas* canvas,
int y = at_top ? 0 : (view->height() - thickness);
canvas->FillRect(gfx::Rect(0, y, view->width(), thickness), color);
}
-
-// static
-void DetachableToolbarView::PaintVerticalDivider(gfx::Canvas* canvas,
- int x,
- int height,
- int vertical_padding,
- SkColor top_color,
- SkColor middle_color,
- SkColor bottom_color) {
- // Draw the upper half of the divider.
- SkPaint paint;
- skia::RefPtr<SkShader> shader = gfx::CreateGradientShader(
- vertical_padding + 1, height / 2, top_color, middle_color);
- paint.setShader(shader.get());
- SkRect rc = { SkIntToScalar(x),
- SkIntToScalar(vertical_padding + 1),
- SkIntToScalar(x + 1),
- SkIntToScalar(height / 2) };
- canvas->sk_canvas()->drawRect(rc, paint);
-
- // Draw the lower half of the divider.
- SkPaint paint_down;
- shader = gfx::CreateGradientShader(
- height / 2, height - vertical_padding, middle_color, bottom_color);
- paint_down.setShader(shader.get());
- SkRect rc_down = { SkIntToScalar(x),
- SkIntToScalar(height / 2),
- SkIntToScalar(x + 1),
- SkIntToScalar(height - vertical_padding) };
- canvas->sk_canvas()->drawRect(rc_down, paint_down);
-}
« no previous file with comments | « chrome/browser/ui/views/detachable_toolbar_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698