| 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 #ifndef CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ | 5 #ifndef CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ |
| 6 #define CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ | 6 #define CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 views::DialogDelegate::DialogButton* button); | 112 views::DialogDelegate::DialogButton* button); |
| 113 | 113 |
| 114 // Simulates a click on a dialog button. | 114 // Simulates a click on a dialog button. |
| 115 bool ClickAppModalDialogButton(views::DialogDelegate::DialogButton button); | 115 bool ClickAppModalDialogButton(views::DialogDelegate::DialogButton button); |
| 116 #endif // defined(OS_WIN) | 116 #endif // defined(OS_WIN) |
| 117 | 117 |
| 118 // Block the thread until a modal dialog is displayed. Returns true on | 118 // Block the thread until a modal dialog is displayed. Returns true on |
| 119 // success. | 119 // success. |
| 120 bool WaitForAppModalDialog(int wait_timeout); | 120 bool WaitForAppModalDialog(int wait_timeout); |
| 121 | 121 |
| 122 // Block the thread until one of the tabs in any window (including windows |
| 123 // opened after the call) displays given url. Returns true on success. |
| 124 bool WaitForURLDisplayed(GURL url, int wait_timeout); |
| 125 |
| 122 // Returns the BrowserProxy for the browser window at the given index, | 126 // Returns the BrowserProxy for the browser window at the given index, |
| 123 // transferring ownership of the pointer to the caller. | 127 // transferring ownership of the pointer to the caller. |
| 124 // On failure, returns NULL. | 128 // On failure, returns NULL. |
| 125 // | 129 // |
| 126 // Use GetBrowserWindowCount to see how many browser windows you can ask for. | 130 // Use GetBrowserWindowCount to see how many browser windows you can ask for. |
| 127 // Window numbers are 0-based. | 131 // Window numbers are 0-based. |
| 128 BrowserProxy* GetBrowserWindow(int window_index); | 132 BrowserProxy* GetBrowserWindow(int window_index); |
| 129 | 133 |
| 130 // Returns the BrowserProxy for the browser window which was last active, | 134 // Returns the BrowserProxy for the browser window which was last active, |
| 131 // transferring ownership of the pointer to the caller. | 135 // transferring ownership of the pointer to the caller. |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 | 218 |
| 215 AutomationRequest* current_request_; | 219 AutomationRequest* current_request_; |
| 216 | 220 |
| 217 // Delay to let the browser execute the command. | 221 // Delay to let the browser execute the command. |
| 218 base::TimeDelta command_execution_timeout_; | 222 base::TimeDelta command_execution_timeout_; |
| 219 | 223 |
| 220 DISALLOW_COPY_AND_ASSIGN(AutomationProxy); | 224 DISALLOW_COPY_AND_ASSIGN(AutomationProxy); |
| 221 }; | 225 }; |
| 222 | 226 |
| 223 #endif // CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ | 227 #endif // CHROME_TEST_AUTOMATION_AUTOMATION_PROXY_H__ |
| OLD | NEW |