Chromium Code Reviews| Index: ui/views/controls/scrollbar/base_scroll_bar.cc |
| diff --git a/ui/views/controls/scrollbar/base_scroll_bar.cc b/ui/views/controls/scrollbar/base_scroll_bar.cc |
| index 117fe345dffea247bef217e0c73e1210d7ea7b24..24c477499a4b34b8e4c9e00dd60737c3f11703fd 100644 |
| --- a/ui/views/controls/scrollbar/base_scroll_bar.cc |
| +++ b/ui/views/controls/scrollbar/base_scroll_bar.cc |
| @@ -128,6 +128,18 @@ void BaseScrollBar::OnThumbStateChanged(CustomButton::ButtonState old_state, |
| /////////////////////////////////////////////////////////////////////////////// |
| // BaseScrollBar, View implementation: |
| +void BaseScrollBar::Layout() { |
| + gfx::Rect thumb_bounds = GetTrackBounds(); |
|
tapted
2016/02/16 23:32:57
Yeah - I'm not sure what views/OWNERS will think a
spqchan
2016/02/17 00:05:29
Done.
|
| + if (IsHorizontal()) { |
| + thumb_bounds.set_x(thumb_->x()); |
| + thumb_bounds.set_width(thumb_->width()); |
| + } else { |
| + thumb_bounds.set_y(thumb_->y()); |
| + thumb_bounds.set_height(thumb_->height()); |
| + } |
| + thumb_->SetBoundsRect(thumb_bounds); |
| +} |
| + |
| bool BaseScrollBar::OnMousePressed(const ui::MouseEvent& event) { |
| if (event.IsOnlyLeftMouseButton()) |
| ProcessPressEvent(event); |