Paint the scroll track with correct bounds in RTL.
This also fixes an issue I suspect has been present a long time, where the horizontal scroll arrows pointed the wrong way in RTL. (This is also visible in the "expected result" movie on the bug.) Bug: 1005767 Change-Id: I701c0b99e797855868110f17ce386cd0491d3b06 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1815878 Auto-Submit: Peter Kasting <pkasting@chromium.org> Commit-Queue: Robert Liao <robliao@chromium.org> Reviewed-by: Robert Liao <robliao@chromium.org> Cr-Commit-Position: refs/heads/master@{#698516}
This commit is contained in:

committed by
Commit Bot

parent
0f789b6043
commit
30abc136c9
@ -67,6 +67,7 @@ class ScrollBarThumb : public BaseScrollBarThumb {
|
||||
|
||||
ScrollBarButton::ScrollBarButton(ButtonListener* listener, Type type)
|
||||
: BaseScrollBarButton(listener), type_(type) {
|
||||
EnableCanvasFlippingForRTLUI(true);
|
||||
SetFocusBehavior(FocusBehavior::NEVER);
|
||||
}
|
||||
|
||||
@ -196,6 +197,8 @@ ui::NativeTheme::State ScrollBarThumb::GetNativeThemeState() const {
|
||||
// ScrollBarViews, public:
|
||||
|
||||
ScrollBarViews::ScrollBarViews(bool horizontal) : ScrollBar(horizontal) {
|
||||
EnableCanvasFlippingForRTLUI(true);
|
||||
|
||||
using Type = ScrollBarButton::Type;
|
||||
SetThumb(new ScrollBarThumb(this));
|
||||
if (horizontal) {
|
||||
|
Reference in New Issue
Block a user