| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/chromeos/status/network_menu.h" | 5 #include "chrome/browser/chromeos/status/network_menu.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/stringprintf.h" | 10 #include "base/stringprintf.h" |
| 11 #include "base/utf_string_conversions.h" | 11 #include "base/utf_string_conversions.h" |
| 12 #include "chrome/browser/chromeos/cros/cros_library.h" | 12 #include "chrome/browser/chromeos/cros/cros_library.h" |
| 13 #include "chrome/browser/chromeos/dom_ui/network_menu_ui.h" | 13 #include "chrome/browser/chromeos/dom_ui/network_menu_ui.h" |
| 14 #include "chrome/browser/ui/browser.h" | 14 #include "chrome/browser/ui/browser.h" |
| 15 #include "chrome/browser/ui/browser_list.h" | 15 #include "chrome/browser/ui/browser_list.h" |
| 16 #include "chrome/common/chrome_switches.h" | 16 #include "chrome/common/chrome_switches.h" |
| 17 #include "chrome/common/url_constants.h" | 17 #include "chrome/common/url_constants.h" |
| 18 #include "chrome/browser/ui/views/window.h" | 18 #include "chrome/browser/ui/views/window.h" |
| 19 #include "gfx/canvas_skia.h" | |
| 20 #include "gfx/skbitmap_operations.h" | |
| 21 #include "grit/generated_resources.h" | 19 #include "grit/generated_resources.h" |
| 22 #include "grit/theme_resources.h" | 20 #include "grit/theme_resources.h" |
| 23 #include "net/base/escape.h" | 21 #include "net/base/escape.h" |
| 24 #include "ui/base/l10n/l10n_util.h" | 22 #include "ui/base/l10n/l10n_util.h" |
| 25 #include "ui/base/resource/resource_bundle.h" | 23 #include "ui/base/resource/resource_bundle.h" |
| 24 #include "ui/gfx/canvas_skia.h" |
| 25 #include "ui/gfx/skbitmap_operations.h" |
| 26 #include "views/controls/menu/menu_2.h" | 26 #include "views/controls/menu/menu_2.h" |
| 27 #include "views/window/window.h" | 27 #include "views/window/window.h" |
| 28 | 28 |
| 29 namespace { | 29 namespace { |
| 30 // Constants passed to Javascript: | 30 // Constants passed to Javascript: |
| 31 static const char* kNetworkTypeEthernet = "ethernet"; | 31 static const char* kNetworkTypeEthernet = "ethernet"; |
| 32 static const char* kNetworkTypeWifi = "wifi"; | 32 static const char* kNetworkTypeWifi = "wifi"; |
| 33 static const char* kNetworkTypeCellular = "cellular"; | 33 static const char* kNetworkTypeCellular = "cellular"; |
| 34 static const char* kNetworkTypeOther = "other"; | 34 static const char* kNetworkTypeOther = "other"; |
| 35 | 35 |
| (...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 768 chrome::kInternetOptionsSubPage, | 768 chrome::kInternetOptionsSubPage, |
| 769 chromeos::TYPE_WIFI); | 769 chromeos::TYPE_WIFI); |
| 770 browser->ShowOptionsTab(page); | 770 browser->ShowOptionsTab(page); |
| 771 } | 771 } |
| 772 } else { | 772 } else { |
| 773 ShowNetworkConfigView(new NetworkConfigView()); | 773 ShowNetworkConfigView(new NetworkConfigView()); |
| 774 } | 774 } |
| 775 } | 775 } |
| 776 | 776 |
| 777 } // namespace chromeos | 777 } // namespace chromeos |
| OLD | NEW |