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

Side by Side Diff: cc/debug/debug_colors.cc

Issue 17599002: cc: Add debug rects for touch and wheel event handler regions and slow scrolling areas (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Labeled "repaints on scroll" Created 7 years, 5 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/debug/debug_colors.h ('k') | cc/debug/debug_rect_history.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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/debug/debug_colors.h" 5 #include "cc/debug/debug_colors.h"
6 6
7 #include "cc/trees/layer_tree_impl.h" 7 #include "cc/trees/layer_tree_impl.h"
8 8
9 namespace cc { 9 namespace cc {
10 10
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 SkColor DebugColors::NonOccludingRectBorderColor() { 236 SkColor DebugColors::NonOccludingRectBorderColor() {
237 return SkColorSetARGB(255, 200, 0, 100); 237 return SkColorSetARGB(255, 200, 0, 100);
238 } 238 }
239 int DebugColors::NonOccludingRectBorderWidth(const LayerTreeImpl* tree_impl) { 239 int DebugColors::NonOccludingRectBorderWidth(const LayerTreeImpl* tree_impl) {
240 return Scale(2, tree_impl); 240 return Scale(2, tree_impl);
241 } 241 }
242 SkColor DebugColors::NonOccludingRectFillColor() { 242 SkColor DebugColors::NonOccludingRectFillColor() {
243 return SkColorSetARGB(10, 200, 0, 100); 243 return SkColorSetARGB(10, 200, 0, 100);
244 } 244 }
245 245
246 // Touch-event-handler rects in yellow.
247 SkColor DebugColors::TouchEventHandlerRectBorderColor() {
248 return SkColorSetARGB(255, 239, 229, 60);
249 }
250 int DebugColors::TouchEventHandlerRectBorderWidth(
251 const LayerTreeImpl* tree_impl) {
252 return Scale(2, tree_impl);
253 }
254 SkColor DebugColors::TouchEventHandlerRectFillColor() {
255 return SkColorSetARGB(30, 239, 229, 60);
256 }
257
258 // Wheel-event-handler rects in green.
259 SkColor DebugColors::WheelEventHandlerRectBorderColor() {
260 return SkColorSetARGB(255, 189, 209, 57);
261 }
262 int DebugColors::WheelEventHandlerRectBorderWidth(
263 const LayerTreeImpl* tree_impl) {
264 return Scale(2, tree_impl);
265 }
266 SkColor DebugColors::WheelEventHandlerRectFillColor() {
267 return SkColorSetARGB(30, 189, 209, 57);
268 }
269
270 // Non-fast-scrollable rects in orange.
271 SkColor DebugColors::NonFastScrollableRectBorderColor() {
272 return SkColorSetARGB(255, 238, 163, 59);
273 }
274 int DebugColors::NonFastScrollableRectBorderWidth(
275 const LayerTreeImpl* tree_impl) {
276 return Scale(2, tree_impl);
277 }
278 SkColor DebugColors::NonFastScrollableRectFillColor() {
279 return SkColorSetARGB(30, 238, 163, 59);
280 }
281
246 // Non-Painted rects in cyan. 282 // Non-Painted rects in cyan.
247 SkColor DebugColors::NonPaintedFillColor() { return SK_ColorCYAN; } 283 SkColor DebugColors::NonPaintedFillColor() { return SK_ColorCYAN; }
248 284
249 // Missing picture rects in magenta. 285 // Missing picture rects in magenta.
250 SkColor DebugColors::MissingPictureFillColor() { return SK_ColorMAGENTA; } 286 SkColor DebugColors::MissingPictureFillColor() { return SK_ColorMAGENTA; }
251 287
252 // Picture borders in transparent blue. 288 // Picture borders in transparent blue.
253 SkColor DebugColors::PictureBorderColor() { 289 SkColor DebugColors::PictureBorderColor() {
254 return SkColorSetARGB(100, 0, 0, 200); 290 return SkColorSetARGB(100, 0, 0, 200);
255 } 291 }
(...skipping 15 matching lines...) Expand all
271 SkColor DebugColors::MemoryDisplayTextColor() { 307 SkColor DebugColors::MemoryDisplayTextColor() {
272 return SkColorSetARGB(255, 220, 220, 220); 308 return SkColorSetARGB(255, 220, 220, 220);
273 } 309 }
274 310
275 // Paint time display in green (similar to paint times in the WebInspector) 311 // Paint time display in green (similar to paint times in the WebInspector)
276 SkColor DebugColors::PaintTimeDisplayTextAndGraphColor() { 312 SkColor DebugColors::PaintTimeDisplayTextAndGraphColor() {
277 return SkColorSetRGB(75, 155, 55); 313 return SkColorSetRGB(75, 155, 55);
278 } 314 }
279 315
280 } // namespace cc 316 } // namespace cc
OLDNEW
« no previous file with comments | « cc/debug/debug_colors.h ('k') | cc/debug/debug_rect_history.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698