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

Unified Diff: chrome/browser/chromeos/ui/focus_ring_layer.cc

Issue 1057873004: Pass a ui::PaintContext from ui::Layer to layer delegates. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: layer-paintcontext: mac Created 5 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
Index: chrome/browser/chromeos/ui/focus_ring_layer.cc
diff --git a/chrome/browser/chromeos/ui/focus_ring_layer.cc b/chrome/browser/chromeos/ui/focus_ring_layer.cc
index 812055e056333816d3f5eb5da6444ae12d15e6e5..c0ca65fe7990d8cb3106fe58b08e8d0013ce67ea 100644
--- a/chrome/browser/chromeos/ui/focus_ring_layer.cc
+++ b/chrome/browser/chromeos/ui/focus_ring_layer.cc
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "ui/aura/window.h"
#include "ui/compositor/layer.h"
+#include "ui/compositor/paint_context.h"
#include "ui/gfx/canvas.h"
namespace chromeos {
@@ -56,10 +57,11 @@ void FocusRingLayer::CreateOrUpdateLayer(
layer_->parent()->StackAtTop(layer_.get());
}
-void FocusRingLayer::OnPaintLayer(gfx::Canvas* canvas) {
+void FocusRingLayer::OnPaintLayer(const ui::PaintContext& context) {
if (!root_window_ || focus_ring_.IsEmpty())
return;
+ gfx::Canvas* canvas = context.canvas();
gfx::Rect bounds = focus_ring_ - layer_->bounds().OffsetFromOrigin();
SkPaint paint;
paint.setColor(kShadowColor);
« no previous file with comments | « chrome/browser/chromeos/ui/focus_ring_layer.h ('k') | content/browser/renderer_host/render_widget_host_view_aura.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698