Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(375)

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/network_screen_handler.cc

Issue 7058048: [cros] Layout for OOBE WebUI. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: refactoring Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/ui/webui/chromeos/login/network_screen_handler.h" 5 #include "chrome/browser/ui/webui/chromeos/login/network_screen_handler.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "grit/chromium_strings.h" 9 #include "grit/chromium_strings.h"
10 #include "grit/generated_resources.h" 10 #include "grit/generated_resources.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 62
63 void NetworkScreenHandler::EnableContinue(bool enabled) { 63 void NetworkScreenHandler::EnableContinue(bool enabled) {
64 // scoped_ptr<Value> enabled_value(Value::CreateBooleanValue(enabled)); 64 // scoped_ptr<Value> enabled_value(Value::CreateBooleanValue(enabled));
65 // web_ui_->CallJavascriptFunction("cr.ui.Oobe.enableContinue", 65 // web_ui_->CallJavascriptFunction("cr.ui.Oobe.enableContinue",
66 // *enabled_value); 66 // *enabled_value);
67 } 67 }
68 68
69 void NetworkScreenHandler::GetLocalizedSettings( 69 void NetworkScreenHandler::GetLocalizedSettings(
70 DictionaryValue* localized_strings) { 70 DictionaryValue* localized_strings) {
71 localized_strings->SetString("networkScreenTitle", 71 localized_strings->SetString("networkScreenTitle",
72 l10n_util::GetStringFUTF16( 72 l10n_util::GetStringUTF16(IDS_WELCOME_SCREEN_TITLE));
73 IDS_WELCOME_SCREEN_TITLE,
74 l10n_util::GetStringUTF16(IDS_SHORT_PRODUCT_NAME)));
75 localized_strings->SetString("selectLanguage", 73 localized_strings->SetString("selectLanguage",
76 l10n_util::GetStringUTF16(IDS_LANGUAGE_SELECTION_SELECT)); 74 l10n_util::GetStringUTF16(IDS_LANGUAGE_SELECTION_SELECT));
77 localized_strings->SetString("selectKeyboard", 75 localized_strings->SetString("selectKeyboard",
78 l10n_util::GetStringUTF16(IDS_KEYBOARD_SELECTION_SELECT)); 76 l10n_util::GetStringUTF16(IDS_KEYBOARD_SELECTION_SELECT));
79 localized_strings->SetString("selectNetwork", 77 localized_strings->SetString("selectNetwork",
80 l10n_util::GetStringUTF16(IDS_NETWORK_SELECTION_SELECT)); 78 l10n_util::GetStringUTF16(IDS_NETWORK_SELECTION_SELECT));
81 localized_strings->SetString("proxySettings", 79 localized_strings->SetString("proxySettings",
82 l10n_util::GetStringUTF16(IDS_OPTIONS_PROXIES_CONFIGURE_BUTTON)); 80 l10n_util::GetStringUTF16(IDS_OPTIONS_PROXIES_CONFIGURE_BUTTON));
83 localized_strings->SetString("continueButton", 81 localized_strings->SetString("continueButton",
84 l10n_util::GetStringUTF16(IDS_NETWORK_SELECTION_CONTINUE_BUTTON)); 82 l10n_util::GetStringUTF16(IDS_NETWORK_SELECTION_CONTINUE_BUTTON));
85 } 83 }
86 84
87 void NetworkScreenHandler::Initialize() { 85 void NetworkScreenHandler::Initialize() {
88 // TODO(avayvod): Set necessary data. 86 // TODO(avayvod): Set necessary data.
89 // TODO(avayvod): Initialize languages, keyboards and networks lists. 87 // TODO(avayvod): Initialize languages, keyboards and networks lists.
90 } 88 }
91 89
92 void NetworkScreenHandler::RegisterMessages() { 90 void NetworkScreenHandler::RegisterMessages() {
93 web_ui_->RegisterMessageCallback("networkOnExit", 91 web_ui_->RegisterMessageCallback("networkOnExit",
94 NewCallback(this, &NetworkScreenHandler::OnExit)); 92 NewCallback(this, &NetworkScreenHandler::OnExit));
95 } 93 }
96 94
97 void NetworkScreenHandler::OnExit(const ListValue* args) { 95 void NetworkScreenHandler::OnExit(const ListValue* args) {
98 ClearErrors(); 96 ClearErrors();
99 screen_->OnContinuePressed(); 97 screen_->OnContinuePressed();
100 } 98 }
101 99
102 } // namespace chromeos 100 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chromeos/login/eula_screen_handler.cc ('k') | chrome/browser/ui/webui/chromeos/login/oobe_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698