Index: chrome/browser/chromeos/options/wifi_config_view.cc |
=================================================================== |
--- chrome/browser/chromeos/options/wifi_config_view.cc (revision 46522) |
+++ chrome/browser/chromeos/options/wifi_config_view.cc (working copy) |
@@ -1,4 +1,4 @@ |
-// Copyright (c) 2009 The Chromium Authors. All rights reserved. |
+// Copyright (c) 2010 The Chromium Authors. All rights reserved. |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
@@ -129,16 +129,16 @@ |
bool changed = false; |
bool auto_connect = autoconnect_checkbox_->checked(); |
- if (auto_connect != wifi_.auto_connect) { |
- wifi_.auto_connect = auto_connect; |
+ if (auto_connect != wifi_.auto_connect()) { |
+ wifi_.set_auto_connect(auto_connect); |
changed = true; |
} |
if (passphrase_textfield_) { |
const std::string& passphrase = |
UTF16ToUTF8(passphrase_textfield_->text()); |
- if (passphrase != wifi_.passphrase) { |
- wifi_.passphrase = passphrase; |
+ if (passphrase != wifi_.passphrase()) { |
+ wifi_.set_passphrase(passphrase); |
changed = true; |
} |
} |
@@ -190,7 +190,7 @@ |
ssid_textfield_->SetController(this); |
layout->AddView(ssid_textfield_); |
} else { |
- views::Label* label = new views::Label(ASCIIToWide(wifi_.ssid)); |
+ views::Label* label = new views::Label(ASCIIToWide(wifi_.name())); |
label->SetHorizontalAlignment(views::Label::ALIGN_LEFT); |
layout->AddView(label); |
} |
@@ -201,7 +201,7 @@ |
// in general, but very common. WPA Supplicant doesn't report the |
// EAP type because it's unknown until the process begins, and we'd |
// need some kind of callback. |
- if (wifi_.encrypted && wifi_.encryption == SECURITY_8021X) { |
+ if (wifi_.encrypted() && wifi_.encryption() == SECURITY_8021X) { |
layout->StartRow(0, column_view_set_id); |
layout->AddView(new views::Label(l10n_util::GetString( |
IDS_OPTIONS_SETTINGS_INTERNET_OPTIONS_CERT_IDENTITY))); |
@@ -221,10 +221,10 @@ |
} |
// Add passphrase if other_network or wifi is encrypted. |
- if (other_network_ || wifi_.encrypted) { |
+ if (other_network_ || wifi_.encrypted()) { |
layout->StartRow(0, column_view_set_id); |
int label_text_id; |
- if (wifi_.encryption == SECURITY_8021X) |
+ if (wifi_.encryption() == SECURITY_8021X) |
label_text_id = IDS_OPTIONS_SETTINGS_INTERNET_OPTIONS_CERT; |
else |
label_text_id = IDS_OPTIONS_SETTINGS_INTERNET_OPTIONS_PASSPHRASE; |
@@ -232,8 +232,8 @@ |
passphrase_textfield_ = new views::Textfield( |
views::Textfield::STYLE_PASSWORD); |
passphrase_textfield_->SetController(this); |
- if (!wifi_.passphrase.empty()) |
- passphrase_textfield_->SetText(UTF8ToUTF16(wifi_.passphrase)); |
+ if (!wifi_.passphrase().empty()) |
+ passphrase_textfield_->SetText(UTF8ToUTF16(wifi_.passphrase())); |
layout->AddView(passphrase_textfield_); |
// Password visible button. |
passphrase_visible_button_ = new views::ImageButton(this); |
@@ -250,7 +250,7 @@ |
autoconnect_checkbox_ = new views::Checkbox( |
l10n_util::GetString(IDS_OPTIONS_SETTINGS_INTERNET_OPTIONS_AUTO_CONNECT)); |
// For other network, default to autoconnect. |
- bool autoconnect = other_network_ || wifi_.auto_connect; |
+ bool autoconnect = other_network_ || wifi_.auto_connect(); |
autoconnect_checkbox_->SetChecked(autoconnect); |
layout->StartRow(0, column_view_set_id); |
layout->AddView(autoconnect_checkbox_, 3, 1); |