| OLD | NEW |
| 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 #ifndef VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ | 5 #ifndef VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ |
| 6 #define VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ | 6 #define VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 // the available bounds for the label will be cropped. | 38 // the available bounds for the label will be cropped. |
| 39 void SetMultiLine(bool multiline); | 39 void SetMultiLine(bool multiline); |
| 40 | 40 |
| 41 // Sets/Gets whether or not the checkbox is checked. | 41 // Sets/Gets whether or not the checkbox is checked. |
| 42 virtual void SetChecked(bool checked); | 42 virtual void SetChecked(bool checked); |
| 43 bool checked() const { return checked_; } | 43 bool checked() const { return checked_; } |
| 44 | 44 |
| 45 // Overridden from View: | 45 // Overridden from View: |
| 46 virtual gfx::Size GetPreferredSize() OVERRIDE; | 46 virtual gfx::Size GetPreferredSize() OVERRIDE; |
| 47 virtual int GetHeightForWidth(int w) OVERRIDE; | 47 virtual int GetHeightForWidth(int w) OVERRIDE; |
| 48 virtual void SetEnabled(bool enabled) OVERRIDE; | 48 virtual void OnEnabledChanged() OVERRIDE; |
| 49 virtual void Layout() OVERRIDE; | 49 virtual void Layout() OVERRIDE; |
| 50 virtual std::string GetClassName() const OVERRIDE; | 50 virtual std::string GetClassName() const OVERRIDE; |
| 51 virtual bool OnMousePressed(const MouseEvent& event) OVERRIDE; | 51 virtual bool OnMousePressed(const MouseEvent& event) OVERRIDE; |
| 52 virtual bool OnMouseDragged(const MouseEvent& event) OVERRIDE; | 52 virtual bool OnMouseDragged(const MouseEvent& event) OVERRIDE; |
| 53 virtual void OnMouseReleased(const MouseEvent& event) OVERRIDE; | 53 virtual void OnMouseReleased(const MouseEvent& event) OVERRIDE; |
| 54 virtual void OnMouseCaptureLost() OVERRIDE; | 54 virtual void OnMouseCaptureLost() OVERRIDE; |
| 55 virtual void OnMouseMoved(const MouseEvent& event) OVERRIDE; | 55 virtual void OnMouseMoved(const MouseEvent& event) OVERRIDE; |
| 56 virtual void OnMouseEntered(const MouseEvent& event) OVERRIDE; | 56 virtual void OnMouseEntered(const MouseEvent& event) OVERRIDE; |
| 57 virtual void OnMouseExited(const MouseEvent& event) OVERRIDE; | 57 virtual void OnMouseExited(const MouseEvent& event) OVERRIDE; |
| 58 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; | 58 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 | 129 |
| 130 // The button's class name. | 130 // The button's class name. |
| 131 static const char kViewClassName[]; | 131 static const char kViewClassName[]; |
| 132 | 132 |
| 133 DISALLOW_COPY_AND_ASSIGN(CheckboxNt); | 133 DISALLOW_COPY_AND_ASSIGN(CheckboxNt); |
| 134 }; | 134 }; |
| 135 | 135 |
| 136 } // namespace views | 136 } // namespace views |
| 137 | 137 |
| 138 #endif // VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ | 138 #endif // VIEWS_CONTROLS_BUTTON_CHECKBOX_H_ |
| OLD | NEW |