| 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_screen_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/network_screen_handler.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 DCHECK(core_oobe_actor_); | 62 DCHECK(core_oobe_actor_); |
| 63 } | 63 } |
| 64 | 64 |
| 65 NetworkScreenHandler::~NetworkScreenHandler() { | 65 NetworkScreenHandler::~NetworkScreenHandler() { |
| 66 if (model_) | 66 if (model_) |
| 67 model_->OnViewDestroyed(this); | 67 model_->OnViewDestroyed(this); |
| 68 } | 68 } |
| 69 | 69 |
| 70 // NetworkScreenHandler, NetworkScreenActor implementation: -------------------- | 70 // NetworkScreenHandler, NetworkScreenActor implementation: -------------------- |
| 71 | 71 |
| 72 void NetworkScreenHandler::PrepareToShow() { | |
| 73 } | |
| 74 | |
| 75 void NetworkScreenHandler::Show() { | 72 void NetworkScreenHandler::Show() { |
| 76 if (!page_is_ready()) { | 73 if (!page_is_ready()) { |
| 77 show_on_init_ = true; | 74 show_on_init_ = true; |
| 78 return; | 75 return; |
| 79 } | 76 } |
| 80 | 77 |
| 81 PrefService* prefs = g_browser_process->local_state(); | 78 PrefService* prefs = g_browser_process->local_state(); |
| 82 if (prefs->GetBoolean(prefs::kFactoryResetRequested)) { | 79 if (prefs->GetBoolean(prefs::kFactoryResetRequested)) { |
| 83 if (core_oobe_actor_) | 80 if (core_oobe_actor_) |
| 84 core_oobe_actor_->ShowDeviceResetScreen(); | 81 core_oobe_actor_->ShowDeviceResetScreen(); |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 286 timezone_option->SetString("value", timezone_id); | 283 timezone_option->SetString("value", timezone_id); |
| 287 timezone_option->SetString("title", timezone_name); | 284 timezone_option->SetString("title", timezone_name); |
| 288 timezone_option->SetBoolean("selected", timezone_id == current_timezone_id); | 285 timezone_option->SetBoolean("selected", timezone_id == current_timezone_id); |
| 289 timezone_list->Append(std::move(timezone_option)); | 286 timezone_list->Append(std::move(timezone_option)); |
| 290 } | 287 } |
| 291 | 288 |
| 292 return timezone_list.release(); | 289 return timezone_list.release(); |
| 293 } | 290 } |
| 294 | 291 |
| 295 } // namespace chromeos | 292 } // namespace chromeos |
| OLD | NEW |