summaryrefslogtreecommitdiffstats
path: root/chrome/browser/profile.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/profile.cc')
-rw-r--r--chrome/browser/profile.cc16
1 files changed, 16 insertions, 0 deletions
diff --git a/chrome/browser/profile.cc b/chrome/browser/profile.cc
index 4508644..87c9713 100644
--- a/chrome/browser/profile.cc
+++ b/chrome/browser/profile.cc
@@ -27,6 +27,7 @@
#include "chrome/browser/in_process_webkit/webkit_context.h"
#include "chrome/browser/net/chrome_url_request_context.h"
#include "chrome/browser/net/ssl_config_service_manager.h"
+#include "chrome/browser/notifications/desktop_notification_service.h"
#include "chrome/browser/password_manager/password_store_default.h"
#include "chrome/browser/privacy_blacklist/blacklist.h"
#include "chrome/browser/profile_manager.h"
@@ -459,6 +460,10 @@ class OffTheRecordProfileImpl : public Profile,
return profile_->GetBookmarkModel();
}
+ virtual DesktopNotificationService* GetDesktopNotificationService() {
+ return profile_->GetDesktopNotificationService();
+ }
+
virtual ProfileSyncService* GetProfileSyncService() {
return NULL;
}
@@ -1344,6 +1349,17 @@ WebKitContext* ProfileImpl::GetWebKitContext() {
return webkit_context_.get();
}
+DesktopNotificationService* ProfileImpl::GetDesktopNotificationService() {
+ DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI));
+ if (!desktop_notification_service_.get()) {
+ // TODO(johnnyg): hook this up with notification UI manager.
+ desktop_notification_service_.reset(new DesktopNotificationService(
+ this, NULL));
+ }
+
+ return desktop_notification_service_.get();
+}
+
void ProfileImpl::MarkAsCleanShutdown() {
if (prefs_.get()) {
// The session cleanly exited, set kSessionExitedCleanly appropriately.