| OLD | NEW |
| 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 "chrome/test/automation/automation_proxy.h" | 5 #include "chrome/test/automation/automation_proxy.h" |
| 6 | 6 |
| 7 #include <sstream> | 7 #include <sstream> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 371 } | 371 } |
| 372 | 372 |
| 373 bool AutomationProxy::OpenNewBrowserWindow(Browser::Type type, bool show) { | 373 bool AutomationProxy::OpenNewBrowserWindow(Browser::Type type, bool show) { |
| 374 return Send( | 374 return Send( |
| 375 new AutomationMsg_OpenNewBrowserWindowOfType(static_cast<int>(type), | 375 new AutomationMsg_OpenNewBrowserWindowOfType(static_cast<int>(type), |
| 376 show)); | 376 show)); |
| 377 } | 377 } |
| 378 | 378 |
| 379 scoped_refptr<TabProxy> AutomationProxy::CreateExternalTab( | 379 scoped_refptr<TabProxy> AutomationProxy::CreateExternalTab( |
| 380 const ExternalTabSettings& settings, | 380 const ExternalTabSettings& settings, |
| 381 gfx::AcceleratedWidget* external_tab_container, | 381 gfx::NativeWindow* external_tab_container, |
| 382 gfx::AcceleratedWidget* tab) { | 382 gfx::NativeWindow* tab) { |
| 383 int handle = 0; | 383 int handle = 0; |
| 384 int session_id = 0; | 384 int session_id = 0; |
| 385 bool succeeded = | 385 bool succeeded = |
| 386 Send(new AutomationMsg_CreateExternalTab(settings, | 386 Send(new AutomationMsg_CreateExternalTab(settings, |
| 387 external_tab_container, | 387 external_tab_container, |
| 388 tab, | 388 tab, |
| 389 &handle, | 389 &handle, |
| 390 &session_id)); | 390 &session_id)); |
| 391 if (!succeeded) { | 391 if (!succeeded) { |
| 392 return NULL; | 392 return NULL; |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 467 } | 467 } |
| 468 | 468 |
| 469 bool AutomationProxy::SendJSONRequest(const std::string& request, | 469 bool AutomationProxy::SendJSONRequest(const std::string& request, |
| 470 int timeout_ms, | 470 int timeout_ms, |
| 471 std::string* response) { | 471 std::string* response) { |
| 472 bool result = false; | 472 bool result = false; |
| 473 if (!SendAutomationJSONRequest(this, request, timeout_ms, response, &result)) | 473 if (!SendAutomationJSONRequest(this, request, timeout_ms, response, &result)) |
| 474 return false; | 474 return false; |
| 475 return result; | 475 return result; |
| 476 } | 476 } |
| OLD | NEW |