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/webui/chromeos/login/network_dropdown_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/network_dropdown_handler.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/browser/chromeos/cros/network_library.h" | |
11 #include "chrome/browser/chromeos/login/webui_login_display.h" | 10 #include "chrome/browser/chromeos/login/webui_login_display.h" |
12 #include "chrome/browser/ui/webui/chromeos/login/network_dropdown.h" | 11 #include "chrome/browser/ui/webui/chromeos/login/network_dropdown.h" |
13 #include "content/public/browser/web_ui.h" | 12 #include "content/public/browser/web_ui.h" |
14 #include "grit/generated_resources.h" | 13 #include "grit/generated_resources.h" |
15 #include "ui/base/l10n/l10n_util.h" | 14 #include "ui/base/l10n/l10n_util.h" |
16 | 15 |
17 namespace { | 16 namespace { |
18 | 17 |
19 // JS API callbacks names. | 18 // JS API callbacks names. |
20 const char kJsApiNetworkItemChosen[] = "networkItemChosen"; | 19 const char kJsApiNetworkItemChosen[] = "networkItemChosen"; |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 void NetworkDropdownHandler::HandleNetworkDropdownRefresh( | 114 void NetworkDropdownHandler::HandleNetworkDropdownRefresh( |
116 const base::ListValue* args) { | 115 const base::ListValue* args) { |
117 DCHECK(args->GetSize() == 0); | 116 DCHECK(args->GetSize() == 0); |
118 // Since language change is async, | 117 // Since language change is async, |
119 // we may in theory be on another screen during this call. | 118 // we may in theory be on another screen during this call. |
120 if (dropdown_.get()) | 119 if (dropdown_.get()) |
121 dropdown_->Refresh(); | 120 dropdown_->Refresh(); |
122 } | 121 } |
123 | 122 |
124 } // namespace chromeos | 123 } // namespace chromeos |
OLD | NEW |