Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Side by Side Diff: chrome/test/pyautolib/pyautolib.i

Issue 10828245: Final set of conversions of automation calls to the JSON interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/test/pyautolib/pyautolib.cc ('k') | chrome/test/reliability/automated_ui_test_base.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // Swig Interface for PyAuto. 5 // Swig Interface for PyAuto.
6 // PyAuto makes the Automation Proxy interface available in Python 6 // PyAuto makes the Automation Proxy interface available in Python
7 // 7 //
8 // Running swig as: 8 // Running swig as:
9 // swig -python -c++ chrome/test/pyautolib/pyautolib.i 9 // swig -python -c++ chrome/test/pyautolib/pyautolib.i
10 // would generate pyautolib.py, pyautolib_wrap.cxx 10 // would generate pyautolib.py, pyautolib_wrap.cxx
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 bool get_clear_profile() const; 168 bool get_clear_profile() const;
169 %feature("docstring", "If False, sets the flag so that the profile is " 169 %feature("docstring", "If False, sets the flag so that the profile is "
170 "not cleared on next startup. Useful for persisting profile " 170 "not cleared on next startup. Useful for persisting profile "
171 "across restarts. By default the state is True, to clear profile.") 171 "across restarts. By default the state is True, to clear profile.")
172 set_clear_profile; 172 set_clear_profile;
173 void set_clear_profile(bool clear_profile); 173 void set_clear_profile(bool clear_profile);
174 174
175 %feature("docstring", "Get the path to profile directory.") user_data_dir; 175 %feature("docstring", "Get the path to profile directory.") user_data_dir;
176 FilePath user_data_dir() const; 176 FilePath user_data_dir() const;
177 177
178 %feature("docstring", "Determine if the bookmark bar is visible. "
179 "If the NTP is visible, only return true if attached "
180 "(to the chrome).") GetBookmarkBarVisibility;
181 bool GetBookmarkBarVisibility();
182
183 %feature("docstring", "Determine if the bookmark bar is detached. "
184 "This usually is only true on the NTP.") IsBookmarkBarDetached;
185 bool IsBookmarkBarDetached();
186
187 %feature("docstring", "Wait for the bookmark bar animation to complete. "
188 "|wait_for_open| specifies which kind of change we wait for.")
189 WaitForBookmarkBarVisibilityChange;
190 bool WaitForBookmarkBarVisibilityChange(bool wait_for_open,
191 int window_index=0);
192
193 %feature("docstring", "Get the bookmarks as a JSON string. Internal method.")
194 _GetBookmarksAsJSON;
195 std::string _GetBookmarksAsJSON(int window_index=0);
196
197 %feature("docstring", "Add a bookmark folder with the given index in the "
198 " parent. |title| is the title/name of the folder.")
199 AddBookmarkGroup;
200 bool AddBookmarkGroup(std::wstring parent_id,
201 int index, std::wstring title,
202 int window_index=0);
203
204 %feature("docstring", "Add a bookmark with the given title and URL.")
205 AddBookmarkURL;
206 bool AddBookmarkURL(std::wstring parent_id,
207 int index,
208 std::wstring title,
209 const std::wstring url,
210 int window_index=0);
211
212 %feature("docstring", "Move a bookmark to a new parent.") ReparentBookmark;
213 bool ReparentBookmark(std::wstring id,
214 std::wstring new_parent_id,
215 int index,
216 int window_index=0);
217
218 %feature("docstring", "Set the title of a bookmark.") SetBookmarkTitle;
219 bool SetBookmarkTitle(std::wstring id,
220 std::wstring title,
221 int window_index=0);
222
223 %feature("docstring", "Set the URL of a bookmark.") SetBookmarkURL;
224 bool SetBookmarkURL(std::wstring id,
225 const std::wstring url,
226 int window_index=0);
227
228 %feature("docstring", "Remove (delete) a bookmark.") RemoveBookmark;
229 bool RemoveBookmark(std::wstring id, int window_index=0);
230
231 // Meta-method 178 // Meta-method
232 %feature("docstring", "Send a sync JSON request to Chrome. " 179 %feature("docstring", "Send a sync JSON request to Chrome. "
233 "Returns a JSON dict as a response. " 180 "Returns a JSON dict as a response. "
234 "Given timeout in milliseconds." 181 "Given timeout in milliseconds."
235 "Internal method.") 182 "Internal method.")
236 _SendJSONRequest; 183 _SendJSONRequest;
237 std::string _SendJSONRequest(int window_index, 184 std::string _SendJSONRequest(int window_index,
238 const std::string& request, 185 const std::string& request,
239 int timeout); 186 int timeout);
240 187
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 // Initialize a new HTTPSOptions that will use the specified certificate. 260 // Initialize a new HTTPSOptions that will use the specified certificate.
314 explicit HTTPSOptions(ServerCertificate cert); 261 explicit HTTPSOptions(ServerCertificate cert);
315 }; 262 };
316 263
317 %{ 264 %{
318 typedef net::TestServer::HTTPSOptions HTTPSOptions; 265 typedef net::TestServer::HTTPSOptions HTTPSOptions;
319 %} 266 %}
320 267
321 %pointer_class(int, int_ptr); 268 %pointer_class(int, int_ptr);
322 %pointer_class(uint32, uint32_ptr); 269 %pointer_class(uint32, uint32_ptr);
OLDNEW
« no previous file with comments | « chrome/test/pyautolib/pyautolib.cc ('k') | chrome/test/reliability/automated_ui_test_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698