| 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/layout_test/blink_test_controller.h" | 5 #include "content/shell/browser/layout_test/blink_test_controller.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <iostream> | 9 #include <iostream> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 RenderViewHost* render_view_host = | 380 RenderViewHost* render_view_host = |
| 381 main_window_->web_contents()->GetRenderViewHost(); | 381 main_window_->web_contents()->GetRenderViewHost(); |
| 382 render_view_host->Send( | 382 render_view_host->Send( |
| 383 new ShellViewMsg_NotifyDone(render_view_host->GetRoutingID())); | 383 new ShellViewMsg_NotifyDone(render_view_host->GetRoutingID())); |
| 384 } | 384 } |
| 385 | 385 |
| 386 bool BlinkTestController::IsMainWindow(WebContents* web_contents) const { | 386 bool BlinkTestController::IsMainWindow(WebContents* web_contents) const { |
| 387 return main_window_ && web_contents == main_window_->web_contents(); | 387 return main_window_ && web_contents == main_window_->web_contents(); |
| 388 } | 388 } |
| 389 | 389 |
| 390 scoped_ptr<BluetoothChooser> BlinkTestController::RunBluetoothChooser( | 390 std::unique_ptr<BluetoothChooser> BlinkTestController::RunBluetoothChooser( |
| 391 RenderFrameHost* frame, | 391 RenderFrameHost* frame, |
| 392 const BluetoothChooser::EventHandler& event_handler) { | 392 const BluetoothChooser::EventHandler& event_handler) { |
| 393 if (bluetooth_chooser_factory_) { | 393 if (bluetooth_chooser_factory_) { |
| 394 return bluetooth_chooser_factory_->RunBluetoothChooser(frame, | 394 return bluetooth_chooser_factory_->RunBluetoothChooser(frame, |
| 395 event_handler); | 395 event_handler); |
| 396 } | 396 } |
| 397 return nullptr; | 397 return nullptr; |
| 398 } | 398 } |
| 399 | 399 |
| 400 bool BlinkTestController::OnMessageReceived(const IPC::Message& message) { | 400 bool BlinkTestController::OnMessageReceived(const IPC::Message& message) { |
| (...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 915 } else { | 915 } else { |
| 916 printer_->AddErrorMessage(base::StringPrintf( | 916 printer_->AddErrorMessage(base::StringPrintf( |
| 917 "FAIL: Unexpected sendBluetoothManualChooserEvent() event name '%s'.", | 917 "FAIL: Unexpected sendBluetoothManualChooserEvent() event name '%s'.", |
| 918 event_name.c_str())); | 918 event_name.c_str())); |
| 919 return; | 919 return; |
| 920 } | 920 } |
| 921 bluetooth_chooser_factory_->SendEvent(event, argument); | 921 bluetooth_chooser_factory_->SendEvent(event, argument); |
| 922 } | 922 } |
| 923 | 923 |
| 924 } // namespace content | 924 } // namespace content |
| OLD | NEW |