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 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 | 213 |
214 void AutomationProxy::SignalNewTabUITab(int load_time) { | 214 void AutomationProxy::SignalNewTabUITab(int load_time) { |
215 new_tab_ui_load_time_ = load_time; | 215 new_tab_ui_load_time_ = load_time; |
216 new_tab_ui_load_complete_.Signal(); | 216 new_tab_ui_load_complete_.Signal(); |
217 } | 217 } |
218 | 218 |
219 bool AutomationProxy::SavePackageShouldPromptUser(bool should_prompt) { | 219 bool AutomationProxy::SavePackageShouldPromptUser(bool should_prompt) { |
220 return Send(new AutomationMsg_SavePackageShouldPromptUser(0, should_prompt)); | 220 return Send(new AutomationMsg_SavePackageShouldPromptUser(0, should_prompt)); |
221 } | 221 } |
222 | 222 |
223 bool AutomationProxy::SetEnableExtensionAutomation( | |
224 const std::vector<std::string>& functions_enabled) { | |
225 return Send( | |
226 new AutomationMsg_SetEnableExtensionAutomation(0, functions_enabled)); | |
227 } | |
228 | |
229 bool AutomationProxy::GetBrowserWindowCount(int* num_windows) { | 223 bool AutomationProxy::GetBrowserWindowCount(int* num_windows) { |
230 if (!num_windows) { | 224 if (!num_windows) { |
231 NOTREACHED(); | 225 NOTREACHED(); |
232 return false; | 226 return false; |
233 } | 227 } |
234 | 228 |
235 bool succeeded = SendWithTimeout( | 229 bool succeeded = SendWithTimeout( |
236 new AutomationMsg_BrowserWindowCount(0, num_windows), | 230 new AutomationMsg_BrowserWindowCount(0, num_windows), |
237 command_execution_timeout_ms(), NULL); | 231 command_execution_timeout_ms(), NULL); |
238 | 232 |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
526 if (!p) { | 520 if (!p) { |
527 p = new T(this, tracker_.get(), handle); | 521 p = new T(this, tracker_.get(), handle); |
528 p->AddRef(); | 522 p->AddRef(); |
529 } | 523 } |
530 | 524 |
531 // Since there is no scoped_refptr::attach. | 525 // Since there is no scoped_refptr::attach. |
532 scoped_refptr<T> result; | 526 scoped_refptr<T> result; |
533 result.swap(&p); | 527 result.swap(&p); |
534 return result; | 528 return result; |
535 } | 529 } |
OLD | NEW |