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

Side by Side Diff: chrome/browser/notifications/notification_display_service_factory.cc

Issue 1814923002: Nuke NotificationUIManager from PlatformNotificationServiceImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@profile_manager_load
Patch Set: Rebase Created 4 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "base/memory/singleton.h"
6 #include "chrome/browser/notifications/notification_display_service_factory.h"
7 #include "chrome/browser/profiles/profile.h"
8
9 // static
10 NotificationDisplayService* NotificationDisplayServiceFactory::GetForProfile(
11 Profile* profile) {
12 return static_cast<NotificationDisplayService*>(
13 GetInstance()->GetServiceForBrowserContext(profile, true));
14 }
15
16 // static
17 NotificationDisplayServiceFactory*
18 NotificationDisplayServiceFactory::GetInstance() {
19 return base::Singleton<NotificationDisplayServiceFactory>::get();
20 }
21
22 KeyedService* NotificationDisplayServiceFactory::BuildServiceInstanceFor(
23 content::BrowserContext* context) const {
24 return NotificationDisplayService::Create(
25 Profile::FromBrowserContext(context));
26 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698