diff --git a/dev/AutoSuggestBox/APITests/AutoSuggestBoxTests.cs b/dev/AutoSuggestBox/APITests/AutoSuggestBoxTests.cs index 0236a75c91..9dc67b2ffe 100644 --- a/dev/AutoSuggestBox/APITests/AutoSuggestBoxTests.cs +++ b/dev/AutoSuggestBox/APITests/AutoSuggestBoxTests.cs @@ -7,6 +7,7 @@ using Windows.UI.Xaml.Media; using System.Linq; using System.Collections.Generic; +using MUXControlsTestApp; #if USING_TAEF using WEX.TestExecution; @@ -64,9 +65,16 @@ public void VerifyAutoSuggestBoxCornerRadius() var textBox = TestUtilities.FindDescendents(autoSuggestBox).Where(e => e.Name == "TextBox").Single(); Verify.AreEqual(new CornerRadius(2, 2, 0, 0), textBox.CornerRadius); + var overlayCornerRadius = new CornerRadius(0, 0, 0, 0); + var radius = App.Current.Resources["OverlayCornerRadius"]; + if (radius != null) + { + overlayCornerRadius = (CornerRadius)radius; + } var popup = VisualTreeHelper.GetOpenPopups(Window.Current).Last(); var popupBorder = popup.Child as Border; - Verify.AreEqual(new CornerRadius(0, 0, 2, 2), popupBorder.CornerRadius); + + Verify.AreEqual(new CornerRadius(0, 0, overlayCornerRadius.BottomRight, overlayCornerRadius.BottomLeft), popupBorder.CornerRadius); }); } diff --git a/dev/AutoSuggestBox/AutoSuggestBoxHelper.cpp b/dev/AutoSuggestBox/AutoSuggestBoxHelper.cpp index 80b2f04947..6e0ed8a878 100644 --- a/dev/AutoSuggestBox/AutoSuggestBoxHelper.cpp +++ b/dev/AutoSuggestBox/AutoSuggestBoxHelper.cpp @@ -104,12 +104,11 @@ void AutoSuggestBoxHelper::OnAutoSuggestBoxLoaded(const winrt::IInspectable& sen void AutoSuggestBoxHelper::UpdateCornerRadius(const winrt::AutoSuggestBox& autoSuggestBox, bool isPopupOpen) { auto textBoxRadius = unbox_value(ResourceLookup(autoSuggestBox, box_value(c_controlCornerRadiusKey))); - auto popupRadius = textBoxRadius; + auto popupRadius = unbox_value(ResourceLookup(autoSuggestBox, box_value(c_overlayCornerRadiusKey))); if (winrt::IControl7 autoSuggextBoxControl7 = autoSuggestBox) { textBoxRadius = autoSuggextBoxControl7.CornerRadius(); - popupRadius = autoSuggextBoxControl7.CornerRadius(); } if (isPopupOpen) diff --git a/dev/AutoSuggestBox/AutoSuggestBox_themeresources.xaml b/dev/AutoSuggestBox/AutoSuggestBox_themeresources.xaml index 91f0dc2c2f..df3abbb784 100644 --- a/dev/AutoSuggestBox/AutoSuggestBox_themeresources.xaml +++ b/dev/AutoSuggestBox/AutoSuggestBox_themeresources.xaml @@ -414,8 +414,7 @@ BorderThickness="{ThemeResource AutoSuggestListBorderThemeThickness}" BorderBrush="{ThemeResource AutoSuggestBoxSuggestionsListBorderBrush}" Background="{ThemeResource AutoSuggestBoxSuggestionsListBackground}" - contract7Present:CornerRadius="{TemplateBinding CornerRadius}" - contract7NotPresent:CornerRadius="{ThemeResource OverlayCornerRadius}"> + CornerRadius="{ThemeResource OverlayCornerRadius}"> diff --git a/dev/CalendarDatePicker/CalendarDatePicker_themeresources.xaml b/dev/CalendarDatePicker/CalendarDatePicker_themeresources.xaml index 490a88d2b6..c5bfc9fdc1 100644 --- a/dev/CalendarDatePicker/CalendarDatePicker_themeresources.xaml +++ b/dev/CalendarDatePicker/CalendarDatePicker_themeresources.xaml @@ -215,7 +215,8 @@ DayOfWeekFormat="{TemplateBinding DayOfWeekFormat}" CalendarIdentifier="{TemplateBinding CalendarIdentifier}" IsOutOfScopeEnabled="{TemplateBinding IsOutOfScopeEnabled}" - IsGroupLabelVisible="{TemplateBinding IsGroupLabelVisible}" /> + IsGroupLabelVisible="{TemplateBinding IsGroupLabelVisible}" + contract7Present:CornerRadius="{ThemeResource OverlayCornerRadius}" /> diff --git a/dev/ComboBox/APITests/ComboBoxTests.cs b/dev/ComboBox/APITests/ComboBoxTests.cs index dc1f150016..1f7369e7ee 100644 --- a/dev/ComboBox/APITests/ComboBoxTests.cs +++ b/dev/ComboBox/APITests/ComboBoxTests.cs @@ -6,6 +6,7 @@ using Windows.UI.Xaml.Controls; using Windows.UI.Xaml.Media; using System.Linq; +using MUXControlsTestApp; #if USING_TAEF using WEX.TestExecution; @@ -49,9 +50,15 @@ public void VerifyComboBoxOverlayCornerRadius() var background = TestUtilities.FindDescendents(comboBox).Where(e => e.Name == "Background").Single(); Verify.AreEqual(new CornerRadius(2, 2, 2, 2), background.CornerRadius); + var overlayCornerRadius = new CornerRadius(0, 0, 0, 0); + var radius = App.Current.Resources["OverlayCornerRadius"]; + if (radius != null) + { + overlayCornerRadius = (CornerRadius)radius; + } var popup = VisualTreeHelper.GetOpenPopups(Window.Current).Last(); var popupBorder = TestUtilities.FindDescendents(popup).Where(e => e.Name=="PopupBorder").Single(); - Verify.AreEqual(new CornerRadius(2, 2, 2, 2), popupBorder.CornerRadius); + Verify.AreEqual(overlayCornerRadius, popupBorder.CornerRadius); }); } @@ -78,9 +85,15 @@ public void VerifyComboBoxEditModeCornerRadius() var editableText = TestUtilities.FindDescendents(comboBox).Where(e => e.Name == "EditableText").Single(); Verify.AreEqual(new CornerRadius(2, 2, 0, 0), editableText.CornerRadius); + var overlayCornerRadius = new CornerRadius(0, 0, 0, 0); + var radius = App.Current.Resources["OverlayCornerRadius"]; + if (radius != null) + { + overlayCornerRadius = (CornerRadius)radius; + } var popup = VisualTreeHelper.GetOpenPopups(Window.Current).Last(); var popupBorder = TestUtilities.FindDescendents(popup).Where(e => e.Name == "PopupBorder").Single(); - Verify.AreEqual(new CornerRadius(0, 0, 2, 2), popupBorder.CornerRadius); + Verify.AreEqual(new CornerRadius(0, 0, overlayCornerRadius.BottomRight, overlayCornerRadius.BottomLeft), popupBorder.CornerRadius); }); } diff --git a/dev/ComboBox/ComboBoxHelper.cpp b/dev/ComboBox/ComboBoxHelper.cpp index c6217d52f1..7cc89c6c6c 100644 --- a/dev/ComboBox/ComboBoxHelper.cpp +++ b/dev/ComboBox/ComboBoxHelper.cpp @@ -107,7 +107,7 @@ void ComboBoxHelper::UpdateCornerRadius(const winrt::ComboBox& comboBox, bool is auto cornerRadiusConverter = winrt::make_self(); auto popupRadiusFilter = isOpenDown ? winrt::CornerRadiusFilterKind::Bottom : winrt::CornerRadiusFilterKind::Top; - popupRadius = cornerRadiusConverter->Convert(textBoxRadius, popupRadiusFilter); + popupRadius = cornerRadiusConverter->Convert(popupRadius, popupRadiusFilter); auto textBoxRadiusFilter = isOpenDown ? winrt::CornerRadiusFilterKind::Top : winrt::CornerRadiusFilterKind::Bottom; textBoxRadius = cornerRadiusConverter->Convert(textBoxRadius, textBoxRadiusFilter); diff --git a/dev/ComboBox/ComboBox_themeresources.xaml b/dev/ComboBox/ComboBox_themeresources.xaml index aa91a5da54..f973341ba9 100644 --- a/dev/ComboBox/ComboBox_themeresources.xaml +++ b/dev/ComboBox/ComboBox_themeresources.xaml @@ -674,8 +674,7 @@ Margin="0,-1,0,-1" Padding="{ThemeResource ComboBoxDropdownBorderPadding}" HorizontalAlignment="Stretch" - contract7Present:CornerRadius="{TemplateBinding CornerRadius}" - contract7NotPresent:CornerRadius="{ThemeResource OverlayCornerRadius}"> + CornerRadius="{ThemeResource OverlayCornerRadius}"> - 0,0,0,0 - 0,0,0,0 + 2,2,2,2 + 4,4,4,4 - 0,0,0,0 - 0,0,0,0 + 2,2,2,2 + 4,4,4,4 - 0,0,0,0 - 0,0,0,0 + 2,2,2,2 + 4,4,4,4 diff --git a/dev/CommonStyles/MediaTransportControls_themeresources.xaml b/dev/CommonStyles/MediaTransportControls_themeresources.xaml index 7cec6713ef..5c7d5342e8 100644 --- a/dev/CommonStyles/MediaTransportControls_themeresources.xaml +++ b/dev/CommonStyles/MediaTransportControls_themeresources.xaml @@ -2,6 +2,8 @@ @@ -69,6 +71,7 @@ + @@ -231,9 +234,25 @@ - + - + @@ -264,8 +283,25 @@ - - + + diff --git a/dev/CommonStyles/ProgressBar_themeresources.xaml b/dev/CommonStyles/ProgressBar_themeresources.xaml index 8be3745008..2f8fc784d8 100644 --- a/dev/CommonStyles/ProgressBar_themeresources.xaml +++ b/dev/CommonStyles/ProgressBar_themeresources.xaml @@ -2,7 +2,8 @@ + xmlns:contract7Present="http://schemas.microsoft.com/winfx/2006/xaml/presentation?IsApiContractPresent(Windows.Foundation.UniversalApiContract,7)" + xmlns:contract7NotPresent="http://schemas.microsoft.com/winfx/2006/xaml/presentation?IsApiContractNotPresent(Windows.Foundation.UniversalApiContract,7)"> 0.6 @@ -42,6 +43,7 @@ + @@ -241,8 +243,22 @@ - - + + diff --git a/dev/CommonStyles/TestUI/CornerRadiusPage.xaml b/dev/CommonStyles/TestUI/CornerRadiusPage.xaml index 8798ac1892..8b0f5cf8b4 100644 --- a/dev/CommonStyles/TestUI/CornerRadiusPage.xaml +++ b/dev/CommonStyles/TestUI/CornerRadiusPage.xaml @@ -136,16 +136,16 @@ - - - - - - + + N/A + + 0,0,0,0 + 0,0,0,0 + @@ -162,6 +162,10 @@ + + 0,0,0,0 + 0,0,0,0 + @@ -178,6 +182,10 @@ + + 0,0,0,0 + 0,0,0,0 + @@ -186,6 +194,10 @@ + + 0,0,0,0 + 0,0,0,0 + @@ -194,6 +206,10 @@ + + 0,0,0,0 + 0,0,0,0 + @@ -216,24 +232,16 @@ - - - - - - - - - - - - - - + + N/A + + 0,0,0,0 + 0,0,0,0 +