diff options
author | satish@chromium.org <satish@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-06 21:24:02 +0000 |
---|---|---|
committer | satish@chromium.org <satish@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-06 21:24:02 +0000 |
commit | 560e503e6d6f128eca0f4c3675428eaf0c1c7e7e (patch) | |
tree | ef51f273d0d3df29df33b4e912b317cf3a0ecd91 /chrome/browser/notifications/desktop_notifications_unittest.cc | |
parent | 234900cd8aca4d8327005e68f364e261253c4d0b (diff) | |
download | chromium_src-560e503e6d6f128eca0f4c3675428eaf0c1c7e7e.zip chromium_src-560e503e6d6f128eca0f4c3675428eaf0c1c7e7e.tar.gz chromium_src-560e503e6d6f128eca0f4c3675428eaf0c1c7e7e.tar.bz2 |
Adds a GYP flag for desktop notifications (enabled by default) and stub out relevant code if set to 0.
In chrome/browser/task_manager I moved notifications related code to their own files and allow exclusion and stubbing via GYP. Similarly I have added stubs for other parts including a chrome/browser/notifications/notification_stubs.cc which takes care of classes within that directory.
I also created some static methods in DesktopNotificationService to wrap commonly used notification related code so that we reduce the amount of stubs required.
BUG=none
TEST=existing notification tests succeed
Review URL: http://codereview.chromium.org/7053041
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@88040 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/notifications/desktop_notifications_unittest.cc')
-rw-r--r-- | chrome/browser/notifications/desktop_notifications_unittest.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/chrome/browser/notifications/desktop_notifications_unittest.cc b/chrome/browser/notifications/desktop_notifications_unittest.cc index b3d72ff..6e73693 100644 --- a/chrome/browser/notifications/desktop_notifications_unittest.cc +++ b/chrome/browser/notifications/desktop_notifications_unittest.cc @@ -85,9 +85,8 @@ void DesktopNotificationsTest::SetUp() { browser::RegisterLocalState(&local_state_); profile_.reset(new TestingProfile()); balloon_collection_ = new MockBalloonCollection(); - ui_manager_.reset(new NotificationUIManager(&local_state_)); - ui_manager_->Initialize(balloon_collection_); - balloon_collection_->set_space_change_listener(ui_manager_.get()); + ui_manager_.reset(NotificationUIManager::Create(&local_state_, + balloon_collection_)); service_.reset(new DesktopNotificationService(profile(), ui_manager_.get())); log_output_.clear(); } |