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

Side by Side Diff: cc/blink/web_layer_impl.cc

Issue 638213004: cc: Remove WebLayerImpl::invalidateRect(WebFloatRect) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rm-invalidatefloatrect: . Created 6 years, 2 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
« no previous file with comments | « cc/blink/web_layer_impl.h ('k') | cc/blink/web_layer_impl_fixed_bounds.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "cc/blink/web_layer_impl.h" 5 #include "cc/blink/web_layer_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/debug/trace_event_impl.h" 8 #include "base/debug/trace_event_impl.h"
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 70
71 // static 71 // static
72 void WebLayerImpl::SetImplSidePaintingEnabled(bool enabled) { 72 void WebLayerImpl::SetImplSidePaintingEnabled(bool enabled) {
73 g_impl_side_painting_enabled = enabled; 73 g_impl_side_painting_enabled = enabled;
74 } 74 }
75 75
76 int WebLayerImpl::id() const { 76 int WebLayerImpl::id() const {
77 return layer_->id(); 77 return layer_->id();
78 } 78 }
79 79
80 void WebLayerImpl::invalidateRect(const blink::WebFloatRect& rect) {
81 layer_->SetNeedsDisplayRect(gfx::ToEnclosingRect(rect));
82 }
83
84 void WebLayerImpl::invalidateRect(const blink::WebRect& rect) { 80 void WebLayerImpl::invalidateRect(const blink::WebRect& rect) {
85 layer_->SetNeedsDisplayRect(rect); 81 layer_->SetNeedsDisplayRect(rect);
86 } 82 }
87 83
88 void WebLayerImpl::invalidate() { 84 void WebLayerImpl::invalidate() {
89 layer_->SetNeedsDisplay(); 85 layer_->SetNeedsDisplay();
90 } 86 }
91 87
92 void WebLayerImpl::addChild(WebLayer* child) { 88 void WebLayerImpl::addChild(WebLayer* child) {
93 layer_->AddChild(static_cast<WebLayerImpl*>(child)->layer()); 89 layer_->AddChild(static_cast<WebLayerImpl*>(child)->layer());
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
477 if (parent) 473 if (parent)
478 clip_parent = static_cast<WebLayerImpl*>(parent)->layer(); 474 clip_parent = static_cast<WebLayerImpl*>(parent)->layer();
479 layer_->SetClipParent(clip_parent); 475 layer_->SetClipParent(clip_parent);
480 } 476 }
481 477
482 Layer* WebLayerImpl::layer() const { 478 Layer* WebLayerImpl::layer() const {
483 return layer_.get(); 479 return layer_.get();
484 } 480 }
485 481
486 } // namespace cc_blink 482 } // namespace cc_blink
OLDNEW
« no previous file with comments | « cc/blink/web_layer_impl.h ('k') | cc/blink/web_layer_impl_fixed_bounds.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698