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

Side by Side Diff: content/test/layouttest_support.cc

Issue 436133002: Migrate TestCommon to Chromium c++ style and remove un-used header. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updated for layout test Created 6 years, 4 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 | « content/shell/renderer/test_runner/web_test_proxy.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "content/public/test/layouttest_support.h" 5 #include "content/public/test/layouttest_support.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/lazy_instance.h" 8 #include "base/lazy_instance.h"
9 #include "content/browser/renderer_host/render_widget_host_impl.h" 9 #include "content/browser/renderer_host/render_widget_host_impl.h"
10 #include "content/common/gpu/image_transport_surface.h" 10 #include "content/common/gpu/image_transport_surface.h"
11 #include "content/public/common/page_state.h" 11 #include "content/public/common/page_state.h"
12 #include "content/renderer/compositor_bindings/web_layer_impl.h" 12 #include "content/renderer/compositor_bindings/web_layer_impl.h"
13 #include "content/renderer/history_entry.h" 13 #include "content/renderer/history_entry.h"
14 #include "content/renderer/history_serialization.h" 14 #include "content/renderer/history_serialization.h"
15 #include "content/renderer/render_frame_impl.h" 15 #include "content/renderer/render_frame_impl.h"
16 #include "content/renderer/render_thread_impl.h" 16 #include "content/renderer/render_thread_impl.h"
17 #include "content/renderer/render_view_impl.h" 17 #include "content/renderer/render_view_impl.h"
18 #include "content/renderer/renderer_webkitplatformsupport_impl.h" 18 #include "content/renderer/renderer_webkitplatformsupport_impl.h"
19 #include "content/shell/renderer/test_runner/TestCommon.h" 19 #include "content/shell/renderer/test_runner/test_common.h"
20 #include "content/shell/renderer/test_runner/web_frame_test_proxy.h" 20 #include "content/shell/renderer/test_runner/web_frame_test_proxy.h"
21 #include "content/shell/renderer/test_runner/web_test_proxy.h" 21 #include "content/shell/renderer/test_runner/web_test_proxy.h"
22 #include "third_party/WebKit/public/platform/WebBatteryStatus.h" 22 #include "third_party/WebKit/public/platform/WebBatteryStatus.h"
23 #include "third_party/WebKit/public/platform/WebDeviceMotionData.h" 23 #include "third_party/WebKit/public/platform/WebDeviceMotionData.h"
24 #include "third_party/WebKit/public/platform/WebDeviceOrientationData.h" 24 #include "third_party/WebKit/public/platform/WebDeviceOrientationData.h"
25 #include "third_party/WebKit/public/platform/WebGamepads.h" 25 #include "third_party/WebKit/public/platform/WebGamepads.h"
26 #include "third_party/WebKit/public/web/WebHistoryItem.h" 26 #include "third_party/WebKit/public/web/WebHistoryItem.h"
27 27
28 #if defined(OS_MACOSX) 28 #if defined(OS_MACOSX)
29 #include "content/browser/renderer_host/popup_menu_helper_mac.h" 29 #include "content/browser/renderer_host/popup_menu_helper_mac.h"
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 std::string result; 246 std::string result;
247 247
248 const blink::WebHistoryItem& item = node->item(); 248 const blink::WebHistoryItem& item = node->item();
249 if (is_current_index) { 249 if (is_current_index) {
250 result.append("curr->"); 250 result.append("curr->");
251 result.append(indent - 6, ' '); // 6 == "curr->".length() 251 result.append(indent - 6, ' '); // 6 == "curr->".length()
252 } else { 252 } else {
253 result.append(indent, ' '); 253 result.append(indent, ' ');
254 } 254 }
255 255
256 std::string url = normalizeLayoutTestURL(item.urlString().utf8()); 256 std::string url = NormalizeLayoutTestURL(item.urlString().utf8());
257 result.append(url); 257 result.append(url);
258 if (!item.target().isEmpty()) { 258 if (!item.target().isEmpty()) {
259 result.append(" (in frame \""); 259 result.append(" (in frame \"");
260 result.append(item.target().utf8()); 260 result.append(item.target().utf8());
261 result.append("\")"); 261 result.append("\")");
262 } 262 }
263 result.append("\n"); 263 result.append("\n");
264 264
265 std::vector<HistoryEntry::HistoryNode*> children = node->children(); 265 std::vector<HistoryEntry::HistoryNode*> children = node->children();
266 if (!children.empty()) { 266 if (!children.empty()) {
(...skipping 19 matching lines...) Expand all
286 } 286 }
287 result.append("===============================================\n"); 287 result.append("===============================================\n");
288 return result; 288 return result;
289 } 289 }
290 290
291 blink::WebLayer* InstantiateWebLayer(scoped_refptr<cc::TextureLayer> layer) { 291 blink::WebLayer* InstantiateWebLayer(scoped_refptr<cc::TextureLayer> layer) {
292 return new WebLayerImpl(layer); 292 return new WebLayerImpl(layer);
293 } 293 }
294 294
295 } // namespace content 295 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/renderer/test_runner/web_test_proxy.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698