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

Unified Diff: chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm

Issue 2714193004: [Mac RTL] Fix the RTLness of the website settings bubble header. (Closed)
Patch Set: rebase Created 3 years, 8 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm
diff --git a/chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm b/chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm
index 4f50b6dacdb108c9616c69e78856bd9939a00038..8885b7b127a4cd524b5985d6fffae8efd853577d 100644
--- a/chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm
+++ b/chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm
@@ -357,6 +357,11 @@ bool IsInternalURL(const GURL& url) {
[connectionHelpButton_ setTarget:self];
[connectionHelpButton_ setAction:@selector(openConnectionHelp:)];
+ if (base::i18n::IsRTL()) {
+ securitySummaryField_.alignment = NSRightTextAlignment;
+ securityDetailsField_.alignment = NSRightTextAlignment;
+ }
+
return securitySectionView.get();
}
@@ -508,9 +513,13 @@ bool IsInternalURL(const GURL& url) {
yPos = [self setYPositionOfView:securityDetailsField_
to:yPos + kSecurityParagraphSpacing];
- [connectionHelpButton_ setFrameOrigin:NSMakePoint(kSectionHorizontalPadding -
- kLinkButtonXAdjustment,
- yPos)];
+ NSPoint helpOrigin =
+ NSMakePoint(kSectionHorizontalPadding - kLinkButtonXAdjustment, yPos);
+ if (base::i18n::IsRTL()) {
+ helpOrigin.x = NSWidth([contentView_ frame]) - helpOrigin.x -
+ NSWidth(connectionHelpButton_.frame);
+ }
+ [connectionHelpButton_ setFrameOrigin:helpOrigin];
yPos = NSMaxY([connectionHelpButton_ frame]);
if (resetDecisionsButton_) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698