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

Unified Diff: google_apis/gaia/gaia_urls.cc

Issue 601643002: Use a distinct source parameter on gaia endpoints for the reconcilor. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@uber
Patch Set: Remove functions Created 6 years, 3 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
« no previous file with comments | « google_apis/gaia/gaia_urls.h ('k') | google_apis/gaia/merge_session_helper.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/gaia/gaia_urls.cc
diff --git a/google_apis/gaia/gaia_urls.cc b/google_apis/gaia/gaia_urls.cc
index acb4c19e38a46bb1b80bb41853aabebbfcae9ec8..15afe2c41ac2e8d2414ac2dd34b427f549f791b6 100644
--- a/google_apis/gaia/gaia_urls.cc
+++ b/google_apis/gaia/gaia_urls.cc
@@ -6,6 +6,7 @@
#include "base/command_line.h"
#include "base/logging.h"
+#include "base/strings/stringprintf.h"
#include "google_apis/gaia/gaia_switches.h"
#include "google_apis/google_api_keys.h"
@@ -194,10 +195,6 @@ const GURL& GaiaUrls::oauth1_login_url() const {
return oauth1_login_url_;
}
-const GURL& GaiaUrls::list_accounts_url() const {
- return list_accounts_url_;
-}
-
const GURL& GaiaUrls::embedded_signin_url() const {
return embedded_signin_url_;
}
@@ -206,10 +203,6 @@ const GURL& GaiaUrls::add_account_url() const {
return add_account_url_;
}
-const GURL& GaiaUrls::get_check_connection_info_url() const {
- return get_check_connection_info_url_;
-}
-
const std::string& GaiaUrls::oauth2_chrome_client_id() const {
return oauth2_chrome_client_id_;
}
@@ -245,3 +238,20 @@ const GURL& GaiaUrls::oauth2_revoke_url() const {
const GURL& GaiaUrls::gaia_login_form_realm() const {
return gaia_url_;
}
+
+GURL GaiaUrls::ListAccountsURLWithSource(const std::string& source) {
+ if (source.empty()) {
+ return list_accounts_url_;
+ } else {
+ std::string query = list_accounts_url_.query();
+ return list_accounts_url_.Resolve(
+ base::StringPrintf("?source=%s&%s", source.c_str(), query.c_str()));
+ }
+}
+
+GURL GaiaUrls::GetCheckConnectionInfoURLWithSource(const std::string& source) {
+ return source.empty()
+ ? get_check_connection_info_url_
+ : get_check_connection_info_url_.Resolve(
+ base::StringPrintf("?source=%s", source.c_str()));
+}
« no previous file with comments | « google_apis/gaia/gaia_urls.h ('k') | google_apis/gaia/merge_session_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698