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

Unified Diff: chrome/test/webdriver/webdriver_session.cc

Issue 10388251: Support maximize window command. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Unit test in chromedriver_tests.py; nicer error reporting - a method to check whether the current v… Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/webdriver/webdriver_session.cc
diff --git a/chrome/test/webdriver/webdriver_session.cc b/chrome/test/webdriver/webdriver_session.cc
index 4e704c8c62baf17cf83c3a289084cb005979c6ab..13e4834e68ed6f0c74878c0b67b7868d42b5102d 100644
--- a/chrome/test/webdriver/webdriver_session.cc
+++ b/chrome/test/webdriver/webdriver_session.cc
@@ -665,7 +665,7 @@ Error* Session::SwitchToFrameWithIndex(int index) {
// tagName of the frameElement. If child frame N is from another domain, then
// the following will run afoul of the same origin policy:
// window.frames[N].frameElement;
- // Instead of indexing window.frames, we use a an XPath expression to index
+ // Instead of indexing window.frames, we use an XPath expression to index
// into the list of all IFRAME and FRAME elements on the page - if we find
// something, then that XPath expression can be used as the new frame's XPath.
std::string script =
@@ -790,6 +790,16 @@ Error* Session::SetWindowBounds(
return error;
}
+Error* Session::MaximizeWindow(const WebViewId& window) {
+ Error* error = NULL;
+ RunSessionTask(base::Bind(
+ &Automation::MaximizeView,
+ base::Unretained(automation_.get()),
+ window,
+ &error));
+ return error;
+}
+
Error* Session::GetAlertMessage(std::string* text) {
Error* error = NULL;
RunSessionTask(base::Bind(
« chrome/test/webdriver/test/chromedriver_tests.py ('K') | « chrome/test/webdriver/webdriver_session.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698