From baf77db493e29c0e880e37dd686dde693cddc015 Mon Sep 17 00:00:00 2001 From: daniel mayost Date: Sat, 12 Mar 2022 20:02:19 +0200 Subject: [PATCH] Merge branch 'master' into feature/flowDirectionImpl --- samples/ControlCatalog/Pages/ScreenPage.cs | 2 ++ src/Avalonia.Controls/Control.cs | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/samples/ControlCatalog/Pages/ScreenPage.cs b/samples/ControlCatalog/Pages/ScreenPage.cs index caad8b0854..1fc37d903d 100644 --- a/samples/ControlCatalog/Pages/ScreenPage.cs +++ b/samples/ControlCatalog/Pages/ScreenPage.cs @@ -78,5 +78,7 @@ namespace ControlCatalog.Pages return new FormattedText(textToFormat, CultureInfo.CurrentCulture, FlowDirection.LeftToRight, Typeface.Default, 12, Brushes.Green); } + + protected override bool ShouldBeMirroredIfRightToLeft() => false; } } diff --git a/src/Avalonia.Controls/Control.cs b/src/Avalonia.Controls/Control.cs index 265f46be5e..16d6c3f4c5 100644 --- a/src/Avalonia.Controls/Control.cs +++ b/src/Avalonia.Controls/Control.cs @@ -346,7 +346,7 @@ namespace Avalonia.Controls if (shouldBeMirroredIfRightToLeft) { shouldMirror = ShuoldApplyMirrorTransform(parentFD, thisFD); - if (this is PopupRoot && thisFD == FlowDirection.RightToLeft) + if (Parent is Popup && thisFD == FlowDirection.RightToLeft) { shouldMirror = true; }