Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(676)

Unified Diff: Source/core/frame/FrameView.cpp

Issue 150733002: Place inner frame scrollbars on the left side, if indicated by the frame-level text direction. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@issue_312435
Patch Set: Place inner frame scrollbars on the left side, if indicated by the frame-level text direction. Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« LayoutTests/TestExpectations ('K') | « Source/core/frame/FrameView.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 95949a17ce21191ed4eea0afd6e8b3e0e780bee1..9f1aaef118b42c813b72f6ef4ce728f9b7bc803e 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -1329,6 +1329,22 @@ LayoutRect FrameView::viewportConstrainedVisibleContentRect() const
return viewportRect;
}
+bool FrameView::shouldPlaceVerticalScrollbarOnLeft() const
+{
+ // Mainframe scrollbar placement should respect the embedding application RTL UI policy.
Julien - ping for review 2014/02/12 23:25:49 That looks like a FIXME related to crbug.com/24986
+ if (isMainFrame())
+ return false;
+
+ Document* document = m_frame->document();
+ if (!document)
+ return false;
+
+ if (!document->body() || !document->body()->renderer())
+ return false;
+
+ // Use the <body> text direction to dictate the frame scrollbar placement.
+ return document->body()->renderer()->style()->shouldPlaceBlockDirectionScrollbarOnLogicalLeft();
+}
IntSize FrameView::scrollOffsetForFixedPosition() const
{
« LayoutTests/TestExpectations ('K') | « Source/core/frame/FrameView.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698