OLD | NEW |
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 "android_webview/browser/browser_view_renderer.h" | 5 #include "android_webview/browser/browser_view_renderer.h" |
6 | 6 |
7 #include "android_webview/browser/browser_view_renderer_client.h" | 7 #include "android_webview/browser/browser_view_renderer_client.h" |
8 #include "android_webview/browser/shared_renderer_state.h" | 8 #include "android_webview/browser/shared_renderer_state.h" |
9 #include "android_webview/common/aw_switches.h" | 9 #include "android_webview/common/aw_switches.h" |
10 #include "android_webview/public/browser/draw_gl.h" | 10 #include "android_webview/public/browser/draw_gl.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 size_t g_tile_area; | 53 size_t g_tile_area; |
54 | 54 |
55 class TracedValue : public base::debug::ConvertableToTraceFormat { | 55 class TracedValue : public base::debug::ConvertableToTraceFormat { |
56 public: | 56 public: |
57 explicit TracedValue(base::Value* value) : value_(value) {} | 57 explicit TracedValue(base::Value* value) : value_(value) {} |
58 static scoped_refptr<base::debug::ConvertableToTraceFormat> FromValue( | 58 static scoped_refptr<base::debug::ConvertableToTraceFormat> FromValue( |
59 base::Value* value) { | 59 base::Value* value) { |
60 return scoped_refptr<base::debug::ConvertableToTraceFormat>( | 60 return scoped_refptr<base::debug::ConvertableToTraceFormat>( |
61 new TracedValue(value)); | 61 new TracedValue(value)); |
62 } | 62 } |
63 virtual void AppendAsTraceFormat(std::string* out) const OVERRIDE { | 63 virtual void AppendAsTraceFormat(std::string* out) const override { |
64 std::string tmp; | 64 std::string tmp; |
65 base::JSONWriter::Write(value_.get(), &tmp); | 65 base::JSONWriter::Write(value_.get(), &tmp); |
66 *out += tmp; | 66 *out += tmp; |
67 } | 67 } |
68 | 68 |
69 private: | 69 private: |
70 virtual ~TracedValue() {} | 70 virtual ~TracedValue() {} |
71 scoped_ptr<base::Value> value_; | 71 scoped_ptr<base::Value> value_; |
72 | 72 |
73 DISALLOW_COPY_AND_ASSIGN(TracedValue); | 73 DISALLOW_COPY_AND_ASSIGN(TracedValue); |
(...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
805 base::StringAppendF(&str, | 805 base::StringAppendF(&str, |
806 "surface width height: [%d %d] ", | 806 "surface width height: [%d %d] ", |
807 draw_info->width, | 807 draw_info->width, |
808 draw_info->height); | 808 draw_info->height); |
809 base::StringAppendF(&str, "is_layer: %d ", draw_info->is_layer); | 809 base::StringAppendF(&str, "is_layer: %d ", draw_info->is_layer); |
810 } | 810 } |
811 return str; | 811 return str; |
812 } | 812 } |
813 | 813 |
814 } // namespace android_webview | 814 } // namespace android_webview |
OLD | NEW |