OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/ui/views/network_profile_bubble.h" | 5 #include "chrome/browser/ui/views/network_profile_bubble.h" |
6 | 6 |
7 #include <wtsapi32.h> | 7 #include <wtsapi32.h> |
8 // Make sure we link the wtsapi lib file in. | 8 // Make sure we link the wtsapi lib file in. |
9 #pragma comment(lib, "wtsapi32.lib") | 9 #pragma comment(lib, "wtsapi32.lib") |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
13 #include "base/file_path.h" | 13 #include "base/file_path.h" |
14 #include "base/file_util.h" | 14 #include "base/file_util.h" |
15 #include "base/metrics/histogram.h" | 15 #include "base/metrics/histogram.h" |
| 16 #include "base/utf_string_conversions.h" |
16 #include "chrome/browser/browser_process.h" | 17 #include "chrome/browser/browser_process.h" |
17 #include "chrome/browser/prefs/pref_service.h" | 18 #include "chrome/browser/prefs/pref_service.h" |
18 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
19 #include "chrome/browser/ui/browser.h" | 20 #include "chrome/browser/ui/browser.h" |
20 #include "chrome/browser/ui/browser_list.h" | 21 #include "chrome/browser/ui/browser_list.h" |
21 #include "chrome/browser/ui/network_profile_bubble_prefs.h" | 22 #include "chrome/browser/ui/network_profile_bubble_prefs.h" |
22 #include "chrome/browser/ui/views/frame/browser_view.h" | 23 #include "chrome/browser/ui/views/frame/browser_view.h" |
23 #include "chrome/browser/ui/views/toolbar_view.h" | 24 #include "chrome/browser/ui/views/toolbar_view.h" |
24 #include "chrome/common/chrome_switches.h" | 25 #include "chrome/common/chrome_switches.h" |
25 #include "chrome/common/pref_names.h" | 26 #include "chrome/common/pref_names.h" |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 GetWidget()->Close(); | 299 GetWidget()->Close(); |
299 } | 300 } |
300 | 301 |
301 // static | 302 // static |
302 void NetworkProfileBubble::NotifyNetworkProfileDetected() { | 303 void NetworkProfileBubble::NotifyNetworkProfileDetected() { |
303 if (BrowserList::GetLastActive() != NULL) | 304 if (BrowserList::GetLastActive() != NULL) |
304 ShowNotification(BrowserList::GetLastActive()); | 305 ShowNotification(BrowserList::GetLastActive()); |
305 else | 306 else |
306 BrowserList::AddObserver(new BrowserListObserver()); | 307 BrowserList::AddObserver(new BrowserListObserver()); |
307 } | 308 } |
OLD | NEW |