| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "mojo/services/gfx/composition/cpp/formatting.h" | 5 #include "mojo/services/gfx/composition/cpp/formatting.h" |
| 6 | 6 |
| 7 #include <ostream> | 7 #include <ostream> |
| 8 | 8 |
| 9 namespace mojo { | 9 namespace mojo { |
| 10 namespace gfx { | 10 namespace gfx { |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 return os_; | 22 return os_; |
| 23 } | 23 } |
| 24 | 24 |
| 25 private: | 25 private: |
| 26 std::ostream& os_; | 26 std::ostream& os_; |
| 27 bool need_comma_ = false; | 27 bool need_comma_ = false; |
| 28 }; | 28 }; |
| 29 | 29 |
| 30 std::ostream& operator<<(std::ostream& os, | 30 std::ostream& operator<<(std::ostream& os, |
| 31 const mojo::gfx::composition::SceneToken& value) { | 31 const mojo::gfx::composition::SceneToken& value) { |
| 32 return os << "{value=" << value.value << "}"; | 32 return os << "<S" << value.value << ">"; |
| 33 } | 33 } |
| 34 | 34 |
| 35 std::ostream& operator<<(std::ostream& os, | 35 std::ostream& operator<<(std::ostream& os, |
| 36 const mojo::gfx::composition::SceneUpdate& value) { | 36 const mojo::gfx::composition::SceneUpdate& value) { |
| 37 os << "{"; | 37 os << "{"; |
| 38 Delimiter d(os); | 38 Delimiter d(os); |
| 39 if (value.clear_resources) { | 39 if (value.clear_resources) { |
| 40 d.Append() << "clear_resources=true"; | 40 d.Append() << "clear_resources=true"; |
| 41 } | 41 } |
| 42 if (value.clear_nodes) { | 42 if (value.clear_nodes) { |
| (...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 | 240 |
| 241 std::ostream& operator<<(std::ostream& os, | 241 std::ostream& operator<<(std::ostream& os, |
| 242 const mojo::gfx::composition::NodeHit& value) { | 242 const mojo::gfx::composition::NodeHit& value) { |
| 243 return os << "{node_id=" << value.node_id << ", transform=" << value.transform | 243 return os << "{node_id=" << value.node_id << ", transform=" << value.transform |
| 244 << "}"; | 244 << "}"; |
| 245 } | 245 } |
| 246 | 246 |
| 247 } // namespace composition | 247 } // namespace composition |
| 248 } // namespace gfx | 248 } // namespace gfx |
| 249 } // namespace mojo | 249 } // namespace mojo |
| OLD | NEW |