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

Side by Side Diff: components/test_runner/test_runner_for_specific_view.cc

Issue 2393513004: Convert app banners to use Mojo. (Closed)
Patch Set: Add TODO Created 4 years, 1 month 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "components/test_runner/test_runner_for_specific_view.h" 5 #include "components/test_runner/test_runner_for_specific_view.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <limits> 8 #include <limits>
9 #include <utility> 9 #include <utility>
10 10
11 #include "base/command_line.h" 11 #include "base/command_line.h"
12 #include "base/logging.h" 12 #include "base/logging.h"
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "base/strings/string_number_conversions.h" 14 #include "base/strings/string_number_conversions.h"
15 #include "base/strings/stringprintf.h" 15 #include "base/strings/stringprintf.h"
16 #include "build/build_config.h" 16 #include "build/build_config.h"
17 #include "components/test_runner/app_banner_client.h"
18 #include "components/test_runner/layout_and_paint_async_then.h" 17 #include "components/test_runner/layout_and_paint_async_then.h"
19 #include "components/test_runner/layout_dump.h" 18 #include "components/test_runner/layout_dump.h"
20 #include "components/test_runner/mock_content_settings_client.h" 19 #include "components/test_runner/mock_content_settings_client.h"
21 #include "components/test_runner/mock_credential_manager_client.h" 20 #include "components/test_runner/mock_credential_manager_client.h"
22 #include "components/test_runner/mock_screen_orientation_client.h" 21 #include "components/test_runner/mock_screen_orientation_client.h"
23 #include "components/test_runner/mock_web_speech_recognizer.h" 22 #include "components/test_runner/mock_web_speech_recognizer.h"
24 #include "components/test_runner/mock_web_user_media_client.h" 23 #include "components/test_runner/mock_web_user_media_client.h"
25 #include "components/test_runner/pixel_dump.h" 24 #include "components/test_runner/pixel_dump.h"
26 #include "components/test_runner/spell_check_client.h" 25 #include "components/test_runner/spell_check_client.h"
27 #include "components/test_runner/test_common.h" 26 #include "components/test_runner/test_common.h"
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 } 387 }
389 388
390 void TestRunnerForSpecificView::SetColorProfile( 389 void TestRunnerForSpecificView::SetColorProfile(
391 const std::string& name, 390 const std::string& name,
392 v8::Local<v8::Function> callback) { 391 v8::Local<v8::Function> callback) {
393 delegate()->SetDeviceColorProfile(name); 392 delegate()->SetDeviceColorProfile(name);
394 PostV8Callback(callback); 393 PostV8Callback(callback);
395 } 394 }
396 395
397 void TestRunnerForSpecificView::DispatchBeforeInstallPromptEvent( 396 void TestRunnerForSpecificView::DispatchBeforeInstallPromptEvent(
398 int request_id,
399 const std::vector<std::string>& event_platforms, 397 const std::vector<std::string>& event_platforms,
400 v8::Local<v8::Function> callback) { 398 v8::Local<v8::Function> callback) {
401 delegate()->DispatchBeforeInstallPromptEvent( 399 delegate()->DispatchBeforeInstallPromptEvent(
402 request_id, event_platforms, 400 event_platforms,
403 base::Bind( 401 base::Bind(
404 &TestRunnerForSpecificView::DispatchBeforeInstallPromptCallback, 402 &TestRunnerForSpecificView::DispatchBeforeInstallPromptCallback,
405 weak_factory_.GetWeakPtr(), 403 weak_factory_.GetWeakPtr(),
406 base::Passed(v8::UniquePersistent<v8::Function>( 404 base::Passed(v8::UniquePersistent<v8::Function>(
407 blink::mainThreadIsolate(), callback)))); 405 blink::mainThreadIsolate(), callback))));
408 } 406 }
409 407
410 void TestRunnerForSpecificView::DispatchBeforeInstallPromptCallback( 408 void TestRunnerForSpecificView::DispatchBeforeInstallPromptCallback(
411 v8::UniquePersistent<v8::Function> callback, 409 v8::UniquePersistent<v8::Function> callback,
412 bool canceled) { 410 bool canceled) {
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 691
694 blink::WebView* TestRunnerForSpecificView::web_view() { 692 blink::WebView* TestRunnerForSpecificView::web_view() {
695 return web_view_test_proxy_base_->web_view(); 693 return web_view_test_proxy_base_->web_view();
696 } 694 }
697 695
698 WebTestDelegate* TestRunnerForSpecificView::delegate() { 696 WebTestDelegate* TestRunnerForSpecificView::delegate() {
699 return web_view_test_proxy_base_->delegate(); 697 return web_view_test_proxy_base_->delegate();
700 } 698 }
701 699
702 } // namespace test_runner 700 } // namespace test_runner
OLDNEW
« no previous file with comments | « components/test_runner/test_runner_for_specific_view.h ('k') | components/test_runner/web_test_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698