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

Side by Side Diff: chrome/browser/extensions/api/media_galleries_private/media_galleries_private_api.cc

Issue 140613002: Cleanup: Replace &LazyInstance::Get() with LazyInstance::Pointer(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/extensions/api/media_galleries_private/media_galleries_ private_api.h" 5 #include "chrome/browser/extensions/api/media_galleries_private/media_galleries_ private_api.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 content::BrowserThread::FILE, FROM_HERE, 104 content::BrowserThread::FILE, FROM_HERE,
105 base::Bind(&HandleProfileShutdownOnFileThread, profile_)); 105 base::Bind(&HandleProfileShutdownOnFileThread, profile_));
106 } 106 }
107 107
108 static base::LazyInstance<ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI> > 108 static base::LazyInstance<ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI> >
109 g_factory = LAZY_INSTANCE_INITIALIZER; 109 g_factory = LAZY_INSTANCE_INITIALIZER;
110 110
111 // static 111 // static
112 ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI>* 112 ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI>*
113 MediaGalleriesPrivateAPI::GetFactoryInstance() { 113 MediaGalleriesPrivateAPI::GetFactoryInstance() {
114 return &g_factory.Get(); 114 return g_factory.Pointer();
115 } 115 }
116 116
117 // static 117 // static
118 MediaGalleriesPrivateAPI* MediaGalleriesPrivateAPI::Get(Profile* profile) { 118 MediaGalleriesPrivateAPI* MediaGalleriesPrivateAPI::Get(Profile* profile) {
119 return 119 return
120 ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI>::GetForProfile(profile); 120 ProfileKeyedAPIFactory<MediaGalleriesPrivateAPI>::GetForProfile(profile);
121 } 121 }
122 122
123 void MediaGalleriesPrivateAPI::OnListenerAdded( 123 void MediaGalleriesPrivateAPI::OnListenerAdded(
124 const EventListenerInfo& details) { 124 const EventListenerInfo& details) {
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 } 417 }
418 } 418 }
419 419
420 SetResult(result_list); 420 SetResult(result_list);
421 SendResponse(true); 421 SendResponse(true);
422 422
423 return true; 423 return true;
424 } 424 }
425 425
426 } // namespace extensions 426 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/mdns/mdns_api.cc ('k') | chrome/browser/extensions/api/messaging/incognito_connectability.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698