OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef CC_LAYERS_LAYER_CLIENT_H_ | 5 #ifndef CC_LAYERS_LAYER_CLIENT_H_ |
6 #define CC_LAYERS_LAYER_CLIENT_H_ | 6 #define CC_LAYERS_LAYER_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "cc/base/cc_export.h" | 11 #include "cc/base/cc_export.h" |
12 | 12 |
13 namespace base { | 13 namespace base { |
14 namespace debug { | 14 namespace trace_event { |
15 class ConvertableToTraceFormat; | 15 class ConvertableToTraceFormat; |
16 } | 16 } |
| 17 |
| 18 // This is added temporarily. Once the renaming of namespace usages |
| 19 // accross all folders are done, this will be removed. |
| 20 // TODO(ssid): crrev.com/837303004 |
| 21 namespace debug { |
| 22 using ::base::trace_event::ConvertableToTraceFormat; |
17 } | 23 } |
| 24 } // namespace base |
18 | 25 |
19 namespace cc { | 26 namespace cc { |
20 | 27 |
21 class CC_EXPORT LayerClient { | 28 class CC_EXPORT LayerClient { |
22 public: | 29 public: |
23 // Returns a pointer to a debug info object, if one has been computed. | 30 // Returns a pointer to a debug info object, if one has been computed. |
24 // If not, returns nullptr. | 31 // If not, returns nullptr. |
25 // If the returned pointer is non-nullptr, the caller takes | 32 // If the returned pointer is non-nullptr, the caller takes |
26 // ownership of the pointer. | 33 // ownership of the pointer. |
27 virtual scoped_refptr<base::debug::ConvertableToTraceFormat> | 34 virtual scoped_refptr<base::debug::ConvertableToTraceFormat> |
28 TakeDebugInfo() = 0; | 35 TakeDebugInfo() = 0; |
29 | 36 |
30 protected: | 37 protected: |
31 virtual ~LayerClient() {} | 38 virtual ~LayerClient() {} |
32 }; | 39 }; |
33 | 40 |
34 } // namespace cc | 41 } // namespace cc |
35 | 42 |
36 #endif // CC_LAYERS_LAYER_CLIENT_H_ | 43 #endif // CC_LAYERS_LAYER_CLIENT_H_ |
OLD | NEW |