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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/paint/ForeignLayerDisplayItem.cpp

Issue 2894093002: Don't access DisplayItemClient::VisualRect() for cached display items. (Closed)
Patch Set: - Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "platform/graphics/paint/ForeignLayerDisplayItem.h" 5 #include "platform/graphics/paint/ForeignLayerDisplayItem.h"
6 6
7 #include <utility> 7 #include <utility>
8 #include "cc/layers/layer.h" 8 #include "cc/layers/layer.h"
9 #include "platform/graphics/GraphicsContext.h" 9 #include "platform/graphics/GraphicsContext.h"
10 #include "platform/graphics/paint/PaintController.h" 10 #include "platform/graphics/paint/PaintController.h"
(...skipping 17 matching lines...) Expand all
28 DCHECK(layer_); 28 DCHECK(layer_);
29 } 29 }
30 30
31 ForeignLayerDisplayItem::~ForeignLayerDisplayItem() {} 31 ForeignLayerDisplayItem::~ForeignLayerDisplayItem() {}
32 32
33 void ForeignLayerDisplayItem::Replay(GraphicsContext&) const { 33 void ForeignLayerDisplayItem::Replay(GraphicsContext&) const {
34 NOTREACHED(); 34 NOTREACHED();
35 } 35 }
36 36
37 void ForeignLayerDisplayItem::AppendToWebDisplayItemList( 37 void ForeignLayerDisplayItem::AppendToWebDisplayItemList(
38 const IntRect&, 38 const LayoutSize&,
39 WebDisplayItemList*) const { 39 WebDisplayItemList*) const {
40 NOTREACHED(); 40 NOTREACHED();
41 } 41 }
42 42
43 bool ForeignLayerDisplayItem::DrawsContent() const { 43 bool ForeignLayerDisplayItem::DrawsContent() const {
44 return true; 44 return true;
45 } 45 }
46 46
47 bool ForeignLayerDisplayItem::Equals(const DisplayItem& other) const { 47 bool ForeignLayerDisplayItem::Equals(const DisplayItem& other) const {
48 return DisplayItem::Equals(other) && 48 return DisplayItem::Equals(other) &&
(...skipping 16 matching lines...) Expand all
65 const IntSize& bounds) { 65 const IntSize& bounds) {
66 PaintController& paint_controller = context.GetPaintController(); 66 PaintController& paint_controller = context.GetPaintController();
67 if (paint_controller.DisplayItemConstructionIsDisabled()) 67 if (paint_controller.DisplayItemConstructionIsDisabled())
68 return; 68 return;
69 69
70 paint_controller.CreateAndAppend<ForeignLayerDisplayItem>( 70 paint_controller.CreateAndAppend<ForeignLayerDisplayItem>(
71 client, type, web_layer->CcLayer(), location, bounds); 71 client, type, web_layer->CcLayer(), location, bounds);
72 } 72 }
73 73
74 } // namespace blink 74 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698