summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_init.cc
diff options
context:
space:
mode:
authorchocobo@chromium.org <chocobo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-01 17:54:36 +0000
committerchocobo@chromium.org <chocobo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-01 17:54:36 +0000
commit39216bee9402bb343519cdb4cd517dc5120531b4 (patch)
tree654b9f6087aef8f8c4b616201c496d16bb4af127 /chrome/browser/browser_init.cc
parent6aa2cf2f5587562974b60eb0a4aa847942d67a49 (diff)
downloadchromium_src-39216bee9402bb343519cdb4cd517dc5120531b4.zip
chromium_src-39216bee9402bb343519cdb4cd517dc5120531b4.tar.gz
chromium_src-39216bee9402bb343519cdb4cd517dc5120531b4.tar.bz2
Added notification for network message.
BUG=chromium-os:2556 TEST=manually connect to network with wrong password and see notification. Review URL: http://codereview.chromium.org/2074017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48641 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_init.cc')
-rw-r--r--chrome/browser/browser_init.cc14
1 files changed, 11 insertions, 3 deletions
diff --git a/chrome/browser/browser_init.cc b/chrome/browser/browser_init.cc
index 7e5b2fd..9213502 100644
--- a/chrome/browser/browser_init.cc
+++ b/chrome/browser/browser_init.cc
@@ -69,9 +69,11 @@
#include "chrome/browser/chromeos/browser_notification_observers.h"
#include "chrome/browser/chromeos/cros/cros_library.h"
#include "chrome/browser/chromeos/cros/mount_library.h"
-#include "chrome/browser/chromeos/cros/power_library.h"
+#include "chrome/browser/chromeos/cros/network_library.h"
+#include "chrome/browser/chromeos/cros/mount_library.h"
#include "chrome/browser/chromeos/gview_request_interceptor.h"
#include "chrome/browser/chromeos/low_battery_observer.h"
+#include "chrome/browser/chromeos/network_message_observer.h"
#include "chrome/browser/chromeos/system_key_event_listener.h"
#include "chrome/browser/chromeos/usb_mount_observer.h"
#include "chrome/browser/chromeos/wm_message_listener.h"
@@ -420,9 +422,15 @@ bool BrowserInit::LaunchBrowser(
// This observer is a singleton. It is never deleted but the pointer is kept
// in a global so that it isn't reported as a leak.
- static chromeos::LowBatteryObserver* observer =
+ static chromeos::LowBatteryObserver* low_battery_observer =
new chromeos::LowBatteryObserver(profile);
- chromeos::CrosLibrary::Get()->GetPowerLibrary()->AddObserver(observer);
+ chromeos::CrosLibrary::Get()->GetPowerLibrary()->AddObserver(
+ low_battery_observer);
+
+ static chromeos::NetworkMessageObserver* network_message_observer =
+ new chromeos::NetworkMessageObserver(profile);
+ chromeos::CrosLibrary::Get()->GetNetworkLibrary()->AddObserver(
+ network_message_observer);
// Creates the SystemKeyEventListener to listen for keypress messages
// regardless of what window has focus.