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

Side by Side Diff: components/ntp_snippets/ntp_snippets_service.h

Issue 2130363002: [NTP Snippets] Remove deprecated prefs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | components/ntp_snippets/ntp_snippets_service.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_SERVICE_H_ 5 #ifndef COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_ 6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 // use |EnterState| instead. 244 // use |EnterState| instead.
245 void EnterStateEnabled(bool fetch_snippets); 245 void EnterStateEnabled(bool fetch_snippets);
246 246
247 // Disables the service. Do not call directly, use |EnterState| instead. 247 // Disables the service. Do not call directly, use |EnterState| instead.
248 void EnterStateDisabled(); 248 void EnterStateDisabled();
249 249
250 // Applies the effects of the transition to the SHUT_DOWN state. Do not call 250 // Applies the effects of the transition to the SHUT_DOWN state. Do not call
251 // directly, use |EnterState| instead. 251 // directly, use |EnterState| instead.
252 void EnterStateShutdown(); 252 void EnterStateShutdown();
253 253
254 void ClearDeprecatedPrefs();
255
256 State state_; 254 State state_;
257 255
258 PrefService* pref_service_; 256 PrefService* pref_service_;
259 257
260 suggestions::SuggestionsService* suggestions_service_; 258 suggestions::SuggestionsService* suggestions_service_;
261 259
262 // All current suggestions (i.e. not discarded ones). 260 // All current suggestions (i.e. not discarded ones).
263 NTPSnippet::PtrVector snippets_; 261 NTPSnippet::PtrVector snippets_;
264 262
265 // Suggestions that the user discarded. We keep these around until they expire 263 // Suggestions that the user discarded. We keep these around until they expire
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 // If the service might be enabled, DisabledReason::NONE will be provided. 315 // If the service might be enabled, DisabledReason::NONE will be provided.
318 virtual void NTPSnippetsServiceDisabledReasonChanged(DisabledReason) = 0; 316 virtual void NTPSnippetsServiceDisabledReasonChanged(DisabledReason) = 0;
319 317
320 protected: 318 protected:
321 virtual ~NTPSnippetsServiceObserver() {} 319 virtual ~NTPSnippetsServiceObserver() {}
322 }; 320 };
323 321
324 } // namespace ntp_snippets 322 } // namespace ntp_snippets
325 323
326 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_ 324 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
OLDNEW
« no previous file with comments | « no previous file | components/ntp_snippets/ntp_snippets_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698