| Index: ui/views/controls/button/radio_button.cc
|
| diff --git a/ui/views/controls/button/radio_button.cc b/ui/views/controls/button/radio_button.cc
|
| index 7f7aa1e1e66922c75641bbffda1b6bf6ed8b55cb..b05f85ff37da91fe73665aa2bc1e3a4953a6c44e 100644
|
| --- a/ui/views/controls/button/radio_button.cc
|
| +++ b/ui/views/controls/button/radio_button.cc
|
| @@ -5,7 +5,9 @@
|
| #include "ui/views/controls/button/radio_button.h"
|
|
|
| #include "base/logging.h"
|
| +#include "grit/ui_resources.h"
|
| #include "ui/base/accessibility/accessible_view_state.h"
|
| +#include "ui/base/resource/resource_bundle.h"
|
| #include "ui/views/widget/widget.h"
|
|
|
| namespace views {
|
| @@ -15,6 +17,11 @@ const char RadioButton::kViewClassName[] = "views/RadioButton";
|
|
|
| RadioButton::RadioButton(const string16& label, int group_id)
|
| : Checkbox(label) {
|
| + ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
|
| + SetStyle(STYLE_RADIO);
|
| + SetImage(STATE_NORMAL, *rb.GetImageSkiaNamed(IDR_RADIO));
|
| + SetImage(STATE_HOVERED, *rb.GetImageSkiaNamed(IDR_RADIO_HOVER));
|
| + SetImage(STATE_PRESSED, *rb.GetImageSkiaNamed(IDR_RADIO_PRESSED));
|
| SetGroup(group_id);
|
| set_focusable(true);
|
| }
|
| @@ -85,7 +92,7 @@ void RadioButton::OnFocus() {
|
| Checkbox::OnFocus();
|
| SetChecked(true);
|
| ui::MouseEvent event(ui::ET_MOUSE_PRESSED, gfx::Point(), gfx::Point(), 0);
|
| - TextButtonBase::NotifyClick(event);
|
| + LabelButton::NotifyClick(event);
|
| }
|
|
|
| void RadioButton::NotifyClick(const ui::Event& event) {
|
| @@ -94,7 +101,7 @@ void RadioButton::NotifyClick(const ui::Event& event) {
|
| if (!checked())
|
| SetChecked(true);
|
| RequestFocus();
|
| - TextButtonBase::NotifyClick(event);
|
| + LabelButton::NotifyClick(event);
|
| }
|
|
|
| ui::NativeTheme::Part RadioButton::GetThemePart() const {
|
|
|