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

Side by Side Diff: ui/compositor/debug_utils.cc

Issue 2582823002: WIP: Surface Synchronization System
Patch Set: Only create ClientSurfaceEmbedder if window is visible. Trash it otherwise. Created 3 years, 10 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first. 5 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first.
6 6
7 #include "ui/compositor/debug_utils.h" 7 #include "ui/compositor/debug_utils.h"
8 8
9 #include <stddef.h> 9 #include <stddef.h>
10 10
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 *out << " textured"; 50 *out << " textured";
51 if (layer->fills_bounds_opaquely()) 51 if (layer->fills_bounds_opaquely())
52 *out << " opaque"; 52 *out << " opaque";
53 break; 53 break;
54 case ui::LAYER_SOLID_COLOR: 54 case ui::LAYER_SOLID_COLOR:
55 *out << " solid"; 55 *out << " solid";
56 break; 56 break;
57 case ui::LAYER_NINE_PATCH: 57 case ui::LAYER_NINE_PATCH:
58 *out << " nine_patch"; 58 *out << " nine_patch";
59 break; 59 break;
60 case ui::LAYER_SURFACE:
61 *out << " surface";
60 } 62 }
61 63
62 if (!layer->visible()) 64 if (!layer->visible())
63 *out << " !visible"; 65 *out << " !visible";
64 66
65 std::string property_indent_str(indent+3, ' '); 67 std::string property_indent_str(indent+3, ' ');
66 *out << '\n' << property_indent_str; 68 *out << '\n' << property_indent_str;
67 *out << "bounds: " << layer->bounds().x() << ',' << layer->bounds().y(); 69 *out << "bounds: " << layer->bounds().x() << ',' << layer->bounds().y();
68 *out << ' ' << layer->bounds().width() << 'x' << layer->bounds().height(); 70 *out << ' ' << layer->bounds().width() << 'x' << layer->bounds().height();
69 if (!layer->subpixel_position_offset().IsZero()) 71 if (!layer->subpixel_position_offset().IsZero())
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 113
112 void PrintLayerHierarchy(const Layer* layer, const gfx::Point& mouse_location) { 114 void PrintLayerHierarchy(const Layer* layer, const gfx::Point& mouse_location) {
113 std::ostringstream out; 115 std::ostringstream out;
114 out << "Layer hierarchy:\n"; 116 out << "Layer hierarchy:\n";
115 PrintLayerHierarchyImp(layer, 0, mouse_location, &out); 117 PrintLayerHierarchyImp(layer, 0, mouse_location, &out);
116 // Error so logs can be collected from end-users. 118 // Error so logs can be collected from end-users.
117 LOG(ERROR) << out.str(); 119 LOG(ERROR) << out.str();
118 } 120 }
119 121
120 } // namespace ui 122 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698