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

Side by Side Diff: chrome/browser/ui/app_list/start_page_service.h

Issue 970863003: app_list::StartPageService: Document and check nulls. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 | chrome/browser/ui/app_list/start_page_service_factory.h » ('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 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 CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_ 5 #ifndef CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_
6 #define CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_ 6 #define CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 48
49 // StartPageService collects data to be displayed in app list's start page 49 // StartPageService collects data to be displayed in app list's start page
50 // and hosts the start page contents. 50 // and hosts the start page contents.
51 class StartPageService : public KeyedService, 51 class StartPageService : public KeyedService,
52 public content::WebContentsObserver, 52 public content::WebContentsObserver,
53 public net::URLFetcherDelegate, 53 public net::URLFetcherDelegate,
54 public SpeechRecognizerDelegate { 54 public SpeechRecognizerDelegate {
55 public: 55 public:
56 typedef std::vector<scoped_refptr<const extensions::Extension> > 56 typedef std::vector<scoped_refptr<const extensions::Extension> >
57 ExtensionList; 57 ExtensionList;
58 // Gets the instance for the given profile. 58 // Gets the instance for the given profile. May return nullptr.
59 static StartPageService* Get(Profile* profile); 59 static StartPageService* Get(Profile* profile);
60 60
61 void AddObserver(StartPageObserver* observer); 61 void AddObserver(StartPageObserver* observer);
62 void RemoveObserver(StartPageObserver* observer); 62 void RemoveObserver(StartPageObserver* observer);
63 63
64 void Init(); 64 void Init();
65 65
66 // Loads the start page WebContents if it hasn't already been loaded. 66 // Loads the start page WebContents if it hasn't already been loaded.
67 void LoadContentsIfNeeded(); 67 void LoadContentsIfNeeded();
68 68
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 scoped_ptr<net::URLFetcher> doodle_fetcher_; 179 scoped_ptr<net::URLFetcher> doodle_fetcher_;
180 180
181 base::WeakPtrFactory<StartPageService> weak_factory_; 181 base::WeakPtrFactory<StartPageService> weak_factory_;
182 182
183 DISALLOW_COPY_AND_ASSIGN(StartPageService); 183 DISALLOW_COPY_AND_ASSIGN(StartPageService);
184 }; 184 };
185 185
186 } // namespace app_list 186 } // namespace app_list
187 187
188 #endif // CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_ 188 #endif // CHROME_BROWSER_UI_APP_LIST_START_PAGE_SERVICE_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/app_list/start_page_service_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698