OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 <sstream> | 5 #include <sstream> |
6 | 6 |
7 #include "chrome/test/automation/automation_proxy.h" | 7 #include "chrome/test/automation/automation_proxy.h" |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/file_version_info.h" | 10 #include "base/file_version_info.h" |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
478 | 478 |
479 void AutomationProxy::InvalidateHandle(const IPC::Message& message) { | 479 void AutomationProxy::InvalidateHandle(const IPC::Message& message) { |
480 void* iter = NULL; | 480 void* iter = NULL; |
481 int handle; | 481 int handle; |
482 | 482 |
483 if (message.ReadInt(&iter, &handle)) { | 483 if (message.ReadInt(&iter, &handle)) { |
484 tracker_->InvalidateHandle(handle); | 484 tracker_->InvalidateHandle(handle); |
485 } | 485 } |
486 } | 486 } |
487 | 487 |
488 bool AutomationProxy::OpenNewBrowserWindow(bool show) { | 488 bool AutomationProxy::OpenNewBrowserWindow(BrowserProxy::Type type, |
489 return Send(new AutomationMsg_OpenNewBrowserWindow(0, show)); | 489 bool show) { |
| 490 return Send(new AutomationMsg_OpenNewBrowserWindow(0, static_cast<int>(type), |
| 491 show)); |
490 } | 492 } |
491 | 493 |
492 scoped_refptr<TabProxy> AutomationProxy::CreateExternalTab( | 494 scoped_refptr<TabProxy> AutomationProxy::CreateExternalTab( |
493 const IPC::ExternalTabSettings& settings, | 495 const IPC::ExternalTabSettings& settings, |
494 gfx::NativeWindow* external_tab_container, | 496 gfx::NativeWindow* external_tab_container, |
495 gfx::NativeWindow* tab) { | 497 gfx::NativeWindow* tab) { |
496 int handle = 0; | 498 int handle = 0; |
497 bool succeeded = | 499 bool succeeded = |
498 Send(new AutomationMsg_CreateExternalTab(0, settings, | 500 Send(new AutomationMsg_CreateExternalTab(0, settings, |
499 external_tab_container, | 501 external_tab_container, |
(...skipping 22 matching lines...) Expand all Loading... |
522 if (!p) { | 524 if (!p) { |
523 p = new T(this, tracker_.get(), handle); | 525 p = new T(this, tracker_.get(), handle); |
524 p->AddRef(); | 526 p->AddRef(); |
525 } | 527 } |
526 | 528 |
527 // Since there is no scoped_refptr::attach. | 529 // Since there is no scoped_refptr::attach. |
528 scoped_refptr<T> result; | 530 scoped_refptr<T> result; |
529 result.swap(&p); | 531 result.swap(&p); |
530 return result; | 532 return result; |
531 } | 533 } |
OLD | NEW |