OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef REMOTING_HOST_SETUP_GAIA_OAUTH_CLIENT_H_ | 5 #ifndef REMOTING_BASE_GAIA_OAUTH_CLIENT_H_ |
6 #define REMOTING_HOST_SETUP_GAIA_OAUTH_CLIENT_H_ | 6 #define REMOTING_BASE_GAIA_OAUTH_CLIENT_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "google_apis/gaia/gaia_oauth_client.h" | 12 #include "google_apis/gaia/gaia_oauth_client.h" |
13 #include "net/url_request/url_request_context_getter.h" | 13 #include "net/url_request/url_request_context_getter.h" |
14 | 14 |
15 #include "remoting/host/setup/oauth_client.h" | 15 #include "remoting/base/oauth_client.h" |
16 | 16 |
17 namespace remoting { | 17 namespace remoting { |
18 | 18 |
19 // A wrapper around gaia::GaiaOAuthClient that provides a more | 19 // A wrapper around gaia::GaiaOAuthClient that provides a more |
20 // convenient interface, with queueing of requests and a callback | 20 // convenient interface, with queueing of requests and a callback |
21 // rather than a delegate. | 21 // rather than a delegate. |
22 class GaiaOAuthClient : public OAuthClient, | 22 class GaiaOAuthClient : public OAuthClient, |
23 public gaia::GaiaOAuthClient::Delegate { | 23 public gaia::GaiaOAuthClient::Delegate { |
24 public: | 24 public: |
25 GaiaOAuthClient( | 25 GaiaOAuthClient( |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 gaia::GaiaOAuthClient gaia_oauth_client_; | 71 gaia::GaiaOAuthClient gaia_oauth_client_; |
72 std::string refresh_token_; | 72 std::string refresh_token_; |
73 bool need_user_email_; | 73 bool need_user_email_; |
74 CompletionCallback on_done_; | 74 CompletionCallback on_done_; |
75 | 75 |
76 DISALLOW_COPY_AND_ASSIGN(GaiaOAuthClient); | 76 DISALLOW_COPY_AND_ASSIGN(GaiaOAuthClient); |
77 }; | 77 }; |
78 | 78 |
79 } // namespace remoting | 79 } // namespace remoting |
80 | 80 |
81 #endif // REMOTING_HOST_SETUP_GAIA_OAUTH_CLIENT_H_ | 81 #endif // REMOTING_BASE_GAIA_OAUTH_CLIENT_H_ |
OLD | NEW |