| 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 "chrome/views/controls/scrollbar/bitmap_scroll_bar.h" | 5 #include "chrome/views/controls/scrollbar/bitmap_scroll_bar.h" |
| 6 | 6 |
| 7 #include "app/l10n_util.h" |
| 7 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 8 #include "chrome/common/gfx/chrome_canvas.h" | 9 #include "chrome/common/gfx/chrome_canvas.h" |
| 9 #include "chrome/common/l10n_util.h" | |
| 10 #include "chrome/views/controls/menu/menu.h" | 10 #include "chrome/views/controls/menu/menu.h" |
| 11 #include "chrome/views/controls/scroll_view.h" | 11 #include "chrome/views/controls/scroll_view.h" |
| 12 #include "chrome/views/widget/widget.h" | 12 #include "chrome/views/widget/widget.h" |
| 13 #include "grit/generated_resources.h" | 13 #include "grit/generated_resources.h" |
| 14 #include "skia/include/SkBitmap.h" | 14 #include "skia/include/SkBitmap.h" |
| 15 | 15 |
| 16 #undef min | 16 #undef min |
| 17 #undef max | 17 #undef max |
| 18 | 18 |
| 19 namespace views { | 19 namespace views { |
| (...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 694 thumb_position = thumb_position - (thumb_->GetSize() / 2); | 694 thumb_position = thumb_position - (thumb_->GetSize() / 2); |
| 695 return (thumb_position * contents_size_) / GetTrackSize(); | 695 return (thumb_position * contents_size_) / GetTrackSize(); |
| 696 } | 696 } |
| 697 | 697 |
| 698 void BitmapScrollBar::SetThumbTrackState(CustomButton::ButtonState state) { | 698 void BitmapScrollBar::SetThumbTrackState(CustomButton::ButtonState state) { |
| 699 thumb_track_state_ = state; | 699 thumb_track_state_ = state; |
| 700 SchedulePaint(); | 700 SchedulePaint(); |
| 701 } | 701 } |
| 702 | 702 |
| 703 } // namespace views | 703 } // namespace views |
| OLD | NEW |