| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 #include "views/controls/button/text_button.h" | 5 #include "views/controls/button/text_button.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "app/gfx/canvas.h" | |
| 10 #include "app/throb_animation.h" | 9 #include "app/throb_animation.h" |
| 11 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
| 11 #include "gfx/canvas.h" |
| 12 #include "views/controls/button/button.h" | 12 #include "views/controls/button/button.h" |
| 13 #include "views/event.h" | 13 #include "views/event.h" |
| 14 #include "grit/app_resources.h" | 14 #include "grit/app_resources.h" |
| 15 | 15 |
| 16 namespace views { | 16 namespace views { |
| 17 | 17 |
| 18 // Padding between the icon and text. | 18 // Padding between the icon and text. |
| 19 static const int kIconTextPadding = 5; | 19 static const int kIconTextPadding = 5; |
| 20 | 20 |
| 21 // Preferred padding between text and edge | 21 // Preferred padding between text and edge |
| (...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 390 bool TextButton::OnMousePressed(const MouseEvent& e) { | 390 bool TextButton::OnMousePressed(const MouseEvent& e) { |
| 391 RequestFocus(); | 391 RequestFocus(); |
| 392 return true; | 392 return true; |
| 393 } | 393 } |
| 394 | 394 |
| 395 void TextButton::Paint(gfx::Canvas* canvas) { | 395 void TextButton::Paint(gfx::Canvas* canvas) { |
| 396 Paint(canvas, false); | 396 Paint(canvas, false); |
| 397 } | 397 } |
| 398 | 398 |
| 399 } // namespace views | 399 } // namespace views |
| OLD | NEW |