Updating trunk VERSION from 2139.0 to 2140.0
[chromium-blink-merge.git] / ui / views / controls / button / radio_button.h
blobedbb2c694cd35ad70fcc5642fdfc4323f14c0be2
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
3 // found in the LICENSE file.
5 #ifndef UI_VIEWS_CONTROLS_BUTTON_RADIO_BUTTON_H_
6 #define UI_VIEWS_CONTROLS_BUTTON_RADIO_BUTTON_H_
8 #include "base/strings/string16.h"
9 #include "ui/views/controls/button/checkbox.h"
11 namespace views {
13 // A native themed class representing a radio button. This class does not use
14 // platform specific objects to replicate the native platforms looks and feel.
15 class VIEWS_EXPORT RadioButton : public Checkbox {
16 public:
17 // The button's class name.
18 static const char kViewClassName[];
20 RadioButton(const base::string16& label, int group_id);
21 virtual ~RadioButton();
23 // Overridden from View:
24 virtual const char* GetClassName() const OVERRIDE;
25 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE;
26 virtual View* GetSelectedViewForGroup(int group) OVERRIDE;
27 virtual bool IsGroupFocusTraversable() const OVERRIDE;
28 virtual void OnFocus() OVERRIDE;
30 // Overridden from Button:
31 virtual void NotifyClick(const ui::Event& event) OVERRIDE;
33 // Overridden from LabelButton:
34 virtual ui::NativeTheme::Part GetThemePart() const OVERRIDE;
36 // Overridden from Checkbox:
37 virtual void SetChecked(bool checked) OVERRIDE;
39 private:
40 DISALLOW_COPY_AND_ASSIGN(RadioButton);
43 } // namespace views
45 #endif // UI_VIEWS_CONTROLS_BUTTON_RADIO_BUTTON_H_