diff options
author | saintlou@chromium.org <saintlou@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-26 17:25:04 +0000 |
---|---|---|
committer | saintlou@chromium.org <saintlou@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-26 17:25:04 +0000 |
commit | 13c4ebf4808f7c20a09f4f64e6831473dffd27a7 (patch) | |
tree | d62d7e2f4f25a9241ea280f6f39fe85a50c22f5b /views/examples | |
parent | 2161d51a6b11a8063628aa11d3a688417abe6f5c (diff) | |
download | chromium_src-13c4ebf4808f7c20a09f4f64e6831473dffd27a7.zip chromium_src-13c4ebf4808f7c20a09f4f64e6831473dffd27a7.tar.gz chromium_src-13c4ebf4808f7c20a09f4f64e6831473dffd27a7.tar.bz2 |
Removing unused NativeButton code
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/7493004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@94114 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/examples')
-rw-r--r-- | views/examples/radio_button_example.cc | 17 | ||||
-rw-r--r-- | views/examples/radio_button_example.h | 3 |
2 files changed, 2 insertions, 18 deletions
diff --git a/views/examples/radio_button_example.cc b/views/examples/radio_button_example.cc index 252a25a..a8be3c0 100644 --- a/views/examples/radio_button_example.cc +++ b/views/examples/radio_button_example.cc @@ -27,13 +27,6 @@ void RadioButtonExample::CreateExampleView(views::View* container) { status_ = new views::TextButton(this, L"Show Status"); int group = 1; - for (size_t i = 0; i < arraysize(native_radio_buttons_); ++i) { - native_radio_buttons_[i] = new views::NativeRadioButton( - base::StringPrintf( L"Radio %d in group %d", i + 1, group), group); - native_radio_buttons_[i]->set_listener(this); - } - - ++group; for (size_t i = 0; i < arraysize(radio_buttons_); ++i) { radio_buttons_[i] = new views::RadioButton( base::StringPrintf( L"Radio %d in group %d", i + 1, group), group); @@ -46,10 +39,6 @@ void RadioButtonExample::CreateExampleView(views::View* container) { views::ColumnSet* column_set = layout->AddColumnSet(0); column_set->AddColumn(views::GridLayout::FILL, views::GridLayout::FILL, 1.0f, views::GridLayout::USE_PREF, 0, 0); - for (size_t i = 0; i < arraysize(native_radio_buttons_); ++i) { - layout->StartRow(0, 0); - layout->AddView(native_radio_buttons_[i]); - } for (size_t i = 0; i < arraysize(radio_buttons_); ++i) { layout->StartRow(0, 0); layout->AddView(radio_buttons_[i]); @@ -63,14 +52,10 @@ void RadioButtonExample::CreateExampleView(views::View* container) { void RadioButtonExample::ButtonPressed(views::Button* sender, const views::Event& event) { if (sender == select_) { - native_radio_buttons_[0]->SetChecked(true); radio_buttons_[2]->SetChecked(true); } else if (sender == status_) { // Show the state of radio buttons. - PrintStatus(L"Group1: 1:%ls, 2:%ls, 3:%ls Group2: 1:%ls, 2:%ls, 3:%ls", - IntToOnOff(native_radio_buttons_[0]->checked()), - IntToOnOff(native_radio_buttons_[1]->checked()), - IntToOnOff(native_radio_buttons_[2]->checked()), + PrintStatus(L"Group: 1:%ls, 2:%ls, 3:%ls", IntToOnOff(radio_buttons_[0]->checked()), IntToOnOff(radio_buttons_[1]->checked()), IntToOnOff(radio_buttons_[2]->checked())); diff --git a/views/examples/radio_button_example.h b/views/examples/radio_button_example.h index 4af37af..c42d176 100644 --- a/views/examples/radio_button_example.h +++ b/views/examples/radio_button_example.h @@ -34,8 +34,7 @@ class RadioButtonExample : public ExampleBase, virtual void ButtonPressed(views::Button* sender, const views::Event& event) OVERRIDE; - // Two groups of 3 radio buttons. - views::NativeRadioButton* native_radio_buttons_[3]; + // Group of 3 radio buttons. views::RadioButton* radio_buttons_[3]; // Control button to select radio buttons, and show the status of buttons. |