| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // This file declares the C++ side of PyAuto, the python interface to | 5 // This file declares the C++ side of PyAuto, the python interface to |
| 6 // Chromium automation. It access Chromium's internals using Automation Proxy. | 6 // Chromium automation. It access Chromium's internals using Automation Proxy. |
| 7 | 7 |
| 8 #ifndef CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ | 8 #ifndef CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ |
| 9 #define CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ | 9 #define CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ |
| 10 #pragma once | 10 #pragma once |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 | 123 |
| 124 // Open a new browser window. Returns false on failure. | 124 // Open a new browser window. Returns false on failure. |
| 125 bool OpenNewBrowserWindow(bool show); | 125 bool OpenNewBrowserWindow(bool show); |
| 126 | 126 |
| 127 // Close a browser window. Returns false on failure. | 127 // Close a browser window. Returns false on failure. |
| 128 bool CloseBrowserWindow(int window_index); | 128 bool CloseBrowserWindow(int window_index); |
| 129 | 129 |
| 130 // Fetch the number of browser windows. Includes popups. | 130 // Fetch the number of browser windows. Includes popups. |
| 131 int GetBrowserWindowCount(); | 131 int GetBrowserWindowCount(); |
| 132 | 132 |
| 133 // Installs the extension. Returns the extension ID only if the extension | |
| 134 // was installed and loaded successfully. Otherwise, returns the empty | |
| 135 // string. Overinstalls will fail. | |
| 136 std::string InstallExtension(const std::string& extension_path, bool with_ui); | |
| 137 | |
| 138 // Returns bookmark bar visibility state. | 133 // Returns bookmark bar visibility state. |
| 139 bool GetBookmarkBarVisibility(); | 134 bool GetBookmarkBarVisibility(); |
| 140 | 135 |
| 141 // Returns true if the bookmark bar is visible in the detached state. | 136 // Returns true if the bookmark bar is visible in the detached state. |
| 142 bool IsBookmarkBarDetached(); | 137 bool IsBookmarkBarDetached(); |
| 143 | 138 |
| 144 // Returns bookmark bar animation state. Warning: timing issues may | 139 // Returns bookmark bar animation state. Warning: timing issues may |
| 145 // change this return value unexpectedly. | 140 // change this return value unexpectedly. |
| 146 bool IsBookmarkBarAnimating(); | 141 bool IsBookmarkBarAnimating(); |
| 147 | 142 |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 // This is necessary since python's unittest module creates instances of | 207 // This is necessary since python's unittest module creates instances of |
| 213 // TestCase at load time itself. | 208 // TestCase at load time itself. |
| 214 static MessageLoop* GetSharedMessageLoop(MessageLoop::Type msg_loop_type); | 209 static MessageLoop* GetSharedMessageLoop(MessageLoop::Type msg_loop_type); |
| 215 static MessageLoop* message_loop_; | 210 static MessageLoop* message_loop_; |
| 216 | 211 |
| 217 // Path to named channel id. | 212 // Path to named channel id. |
| 218 std::string named_channel_id_; | 213 std::string named_channel_id_; |
| 219 }; | 214 }; |
| 220 | 215 |
| 221 #endif // CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ | 216 #endif // CHROME_TEST_PYAUTOLIB_PYAUTOLIB_H_ |
| OLD | NEW |