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

Unified Diff: ui/views/bubble/bubble_dialog_delegate.cc

Issue 1866403005: Fix rtl shelf overflow bubble (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add unit test Created 4 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
Index: ui/views/bubble/bubble_dialog_delegate.cc
diff --git a/ui/views/bubble/bubble_dialog_delegate.cc b/ui/views/bubble/bubble_dialog_delegate.cc
index 0dfb629e7f5ea41c5cc0f26dd7a105e80aea143a..b639c4b6d7c97ea73f2d7a5b3eded97fb34833d1 100644
--- a/ui/views/bubble/bubble_dialog_delegate.cc
+++ b/ui/views/bubble/bubble_dialog_delegate.cc
@@ -106,9 +106,10 @@ NonClientFrameView* BubbleDialogDelegateView::CreateNonClientFrameView(
// the relayout that this call requires.
frame->SetTitleFontList(GetTitleFontList());
frame->SetFootnoteView(CreateFootnoteView());
+ frame->set_mirror_arrow_in_rtl(mirror_arrow_in_rtl_);
BubbleBorder::Arrow adjusted_arrow = arrow();
- if (base::i18n::IsRTL())
+ if (base::i18n::IsRTL() && mirror_arrow_in_rtl_)
adjusted_arrow = BubbleBorder::horizontal_mirror(adjusted_arrow);
frame->SetBubbleBorder(std::unique_ptr<BubbleBorder>(
new BubbleBorder(adjusted_arrow, shadow(), color())));
@@ -205,6 +206,7 @@ BubbleDialogDelegateView::BubbleDialogDelegateView(View* anchor_view,
anchor_view_storage_id_(ViewStorage::GetInstance()->CreateStorageID()),
anchor_widget_(NULL),
arrow_(arrow),
+ mirror_arrow_in_rtl_(true),
shadow_(BubbleBorder::SMALL_SHADOW),
color_explicitly_set_(false),
margins_(kPanelVertMargin,

Powered by Google App Engine
This is Rietveld 408576698