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

Unified Diff: chrome/browser/ui/cocoa/browser_window_layout.mm

Issue 2541583002: [Mac] Don't flip window controls in RTL for macOS < 10.12 (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/framed_browser_window.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/browser_window_layout.mm
diff --git a/chrome/browser/ui/cocoa/browser_window_layout.mm b/chrome/browser/ui/cocoa/browser_window_layout.mm
index 61ea945871ce2dcedcc63f1a8bc385dc96b50e4f..95819323bd8cf1055aa254077f5146262b118a74 100644
--- a/chrome/browser/ui/cocoa/browser_window_layout.mm
+++ b/chrome/browser/ui/cocoa/browser_window_layout.mm
@@ -265,8 +265,11 @@ const CGFloat kLocationBarRightOffset = 35;
layout.trailingIndent = width - maxX;
if (cocoa_l10n_util::ShouldDoExperimentalRTLLayout()) {
- layout.avatarFrame.origin.x =
- width - parameters_.avatarSize.width - layout.avatarFrame.origin.x;
+ if (cocoa_l10n_util::ShouldFlipWindowControlsInRTL())
+ layout.avatarFrame.origin.x =
+ width - parameters_.avatarSize.width - layout.avatarFrame.origin.x;
+ else
+ std::swap(layout.leadingIndent, layout.trailingIndent);
}
output_.tabStripLayout = layout;
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/framed_browser_window.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698