| 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 #include "content/shell/browser/shell.h" | 5 #include "content/shell/browser/shell.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 std::unique_ptr<BluetoothChooser> Shell::RunBluetoothChooser( | 454 std::unique_ptr<BluetoothChooser> Shell::RunBluetoothChooser( |
| 455 RenderFrameHost* frame, | 455 RenderFrameHost* frame, |
| 456 const BluetoothChooser::EventHandler& event_handler) { | 456 const BluetoothChooser::EventHandler& event_handler) { |
| 457 if (switches::IsRunLayoutTestSwitchPresent()) { | 457 if (switches::IsRunLayoutTestSwitchPresent()) { |
| 458 return BlinkTestController::Get()->RunBluetoothChooser(frame, | 458 return BlinkTestController::Get()->RunBluetoothChooser(frame, |
| 459 event_handler); | 459 event_handler); |
| 460 } | 460 } |
| 461 return nullptr; | 461 return nullptr; |
| 462 } | 462 } |
| 463 | 463 |
| 464 BluetoothAllowedDevicesMapBase* Shell::GetBluetoothDevicesMap( |
| 465 RenderFrameHost* frame) { |
| 466 if (switches::IsRunLayoutTestSwitchPresent()) { |
| 467 return BlinkTestController::Get()->GetBluetoothAllowedDevicesMap( |
| 468 web_contents()->GetBrowserContext()); |
| 469 } |
| 470 return nullptr; |
| 471 } |
| 472 |
| 464 bool Shell::DidAddMessageToConsole(WebContents* source, | 473 bool Shell::DidAddMessageToConsole(WebContents* source, |
| 465 int32_t level, | 474 int32_t level, |
| 466 const base::string16& message, | 475 const base::string16& message, |
| 467 int32_t line_no, | 476 int32_t line_no, |
| 468 const base::string16& source_id) { | 477 const base::string16& source_id) { |
| 469 return switches::IsRunLayoutTestSwitchPresent(); | 478 return switches::IsRunLayoutTestSwitchPresent(); |
| 470 } | 479 } |
| 471 | 480 |
| 472 void Shell::RendererUnresponsive( | 481 void Shell::RendererUnresponsive( |
| 473 WebContents* source, | 482 WebContents* source, |
| (...skipping 28 matching lines...) Expand all Loading... |
| 502 if (entry) | 511 if (entry) |
| 503 PlatformSetTitle(entry->GetTitle()); | 512 PlatformSetTitle(entry->GetTitle()); |
| 504 } | 513 } |
| 505 | 514 |
| 506 void Shell::OnDevToolsWebContentsDestroyed() { | 515 void Shell::OnDevToolsWebContentsDestroyed() { |
| 507 devtools_observer_.reset(); | 516 devtools_observer_.reset(); |
| 508 devtools_frontend_ = NULL; | 517 devtools_frontend_ = NULL; |
| 509 } | 518 } |
| 510 | 519 |
| 511 } // namespace content | 520 } // namespace content |
| OLD | NEW |