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

Side by Side Diff: chrome/test/webdriver/webdriver_automation.cc

Issue 10834004: Correct const accessors in base/values.(h|cc) (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Reverting webdriver:Command::parameters_ to const Created 8 years, 5 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
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 #include "chrome/test/webdriver/webdriver_automation.h" 5 #include "chrome/test/webdriver/webdriver_automation.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #endif 9 #endif
10 10
(...skipping 1092 matching lines...) Expand 10 before | Expand all | Expand 10 after
1103 return; 1103 return;
1104 1104
1105 if (geolocation_.get()) { 1105 if (geolocation_.get()) {
1106 geolocation->reset(geolocation_->DeepCopy()); 1106 geolocation->reset(geolocation_->DeepCopy());
1107 } else { 1107 } else {
1108 *error = new Error(kUnknownError, 1108 *error = new Error(kUnknownError,
1109 "Location must be set before it can be retrieved"); 1109 "Location must be set before it can be retrieved");
1110 } 1110 }
1111 } 1111 }
1112 1112
1113 void Automation::OverrideGeolocation(DictionaryValue* geolocation, 1113 void Automation::OverrideGeolocation(const DictionaryValue* geolocation,
1114 Error** error) { 1114 Error** error) {
1115 *error = CheckGeolocationSupported(); 1115 *error = CheckGeolocationSupported();
1116 if (*error) 1116 if (*error)
1117 return; 1117 return;
1118 1118
1119 automation::Error auto_error; 1119 automation::Error auto_error;
1120 if (SendOverrideGeolocationJSONRequest( 1120 if (SendOverrideGeolocationJSONRequest(
1121 automation(), geolocation, &auto_error)) { 1121 automation(), geolocation, &auto_error)) {
1122 geolocation_.reset(geolocation->DeepCopy()); 1122 geolocation_.reset(geolocation->DeepCopy());
1123 } else { 1123 } else {
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
1192 } 1192 }
1193 1193
1194 Error* Automation::CheckMaximizeSupported() { 1194 Error* Automation::CheckMaximizeSupported() {
1195 const char* message = 1195 const char* message =
1196 "Maximize automation interface is not supported for this version of " 1196 "Maximize automation interface is not supported for this version of "
1197 "Chrome."; 1197 "Chrome.";
1198 return CheckVersion(1160, message); 1198 return CheckVersion(1160, message);
1199 } 1199 }
1200 1200
1201 } // namespace webdriver 1201 } // namespace webdriver
OLDNEW
« no previous file with comments | « chrome/test/webdriver/webdriver_automation.h ('k') | chrome/test/webdriver/webdriver_capabilities_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698