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
3 // found in the LICENSE file.
5 #include "content/shell/browser/layout_test/layout_test_javascript_dialog_manager.h"
7 #include "base/command_line.h"
8 #include "base/logging.h"
9 #include "base/strings/utf_string_conversions.h"
10 #include "content/public/browser/web_contents.h"
11 #include "content/shell/browser/blink_test_controller.h"
12 #include "content/shell/browser/shell_javascript_dialog.h"
13 #include "content/shell/common/shell_switches.h"
14 #include "net/base/net_util.h"
18 LayoutTestJavaScriptDialogManager::LayoutTestJavaScriptDialogManager() {
21 LayoutTestJavaScriptDialogManager::~LayoutTestJavaScriptDialogManager() {
24 void LayoutTestJavaScriptDialogManager::RunJavaScriptDialog(
25 WebContents
* web_contents
,
26 const GURL
& origin_url
,
27 const std::string
& accept_lang
,
28 JavaScriptMessageType javascript_message_type
,
29 const base::string16
& message_text
,
30 const base::string16
& default_prompt_text
,
31 const DialogClosedCallback
& callback
,
32 bool* did_suppress_message
) {
33 callback
.Run(true, base::string16());
37 void LayoutTestJavaScriptDialogManager::RunBeforeUnloadDialog(
38 WebContents
* web_contents
,
39 const base::string16
& message_text
,
41 const DialogClosedCallback
& callback
) {
42 callback
.Run(true, base::string16());
46 } // namespace content