OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ | 5 #ifndef COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ |
6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ | 6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/callback_list.h" | 9 #include "base/callback_list.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 scoped_refptr<base::SequencedTaskRunner> file_task_runner_; | 74 scoped_refptr<base::SequencedTaskRunner> file_task_runner_; |
75 | 75 |
76 // Holds the URL request context. Not owned. | 76 // Holds the URL request context. Not owned. |
77 net::URLRequestContextGetter* url_request_context_getter_; | 77 net::URLRequestContextGetter* url_request_context_getter_; |
78 | 78 |
79 scoped_ptr<net::URLFetcher> url_fetcher_; | 79 scoped_ptr<net::URLFetcher> url_fetcher_; |
80 scoped_ptr<SigninManager> signin_manager_; | 80 scoped_ptr<SigninManager> signin_manager_; |
81 scoped_ptr<OAuth2TokenService> token_service_; | 81 scoped_ptr<OAuth2TokenService> token_service_; |
82 scoped_ptr<OAuth2TokenService::Request> oauth_request_; | 82 scoped_ptr<OAuth2TokenService::Request> oauth_request_; |
83 | 83 |
| 84 bool waiting_for_refresh_token_; |
| 85 |
84 SnippetsAvailableCallbackList callback_list_; | 86 SnippetsAvailableCallbackList callback_list_; |
85 | 87 |
86 base::WeakPtrFactory<NTPSnippetsFetcher> weak_ptr_factory_; | 88 base::WeakPtrFactory<NTPSnippetsFetcher> weak_ptr_factory_; |
87 | 89 |
88 DISALLOW_COPY_AND_ASSIGN(NTPSnippetsFetcher); | 90 DISALLOW_COPY_AND_ASSIGN(NTPSnippetsFetcher); |
89 }; | 91 }; |
90 } // namespace ntp_snippets | 92 } // namespace ntp_snippets |
91 | 93 |
92 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ | 94 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_FETCHER_H_ |
OLD | NEW |