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

Unified Diff: chrome/browser/notifications/notification_ui_manager.h

Issue 7053041: Add a Create method to DesktopNotificationHandler and stubs for the notification objects. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/notifications/notification_ui_manager.h
diff --git a/chrome/browser/notifications/notification_ui_manager.h b/chrome/browser/notifications/notification_ui_manager.h
index fb78473e436d536a7f0480e797064cf91ac7c62d..2c6d931d5e51b4a51bf660f2afeb8f627d0fba9e 100644
--- a/chrome/browser/notifications/notification_ui_manager.h
+++ b/chrome/browser/notifications/notification_ui_manager.h
@@ -30,7 +30,6 @@ class NotificationUIManager
: public BalloonCollection::BalloonSpaceChangeListener,
public NotificationObserver {
public:
- explicit NotificationUIManager(PrefService* local_state);
virtual ~NotificationUIManager();
// Creates an initialized UI manager with a new balloon collection
@@ -38,6 +37,12 @@ class NotificationUIManager
// Except for unit tests, this is the way to construct the object.
static NotificationUIManager* Create(PrefService* local_state);
+ // Creates an initialized UI manager with the given balloon collection
+ // and the listener relationship setup.
+ // Used primarily by unit tests.
+ static NotificationUIManager* Create(PrefService* local_state,
+ BalloonCollection* balloons);
+
// Registers preferences.
static void RegisterPrefs(PrefService* prefs);
@@ -75,6 +80,8 @@ class NotificationUIManager
void SetPositionPreference(BalloonCollection::PositionPreference preference);
private:
+ explicit NotificationUIManager(PrefService* local_state);
+
// NotificationObserver override.
virtual void Observe(NotificationType type,
const NotificationSource& source,

Powered by Google App Engine
This is Rietveld 408576698