diff --git a/src/Controls/src/Core/Button/Button.cs b/src/Controls/src/Core/Button/Button.cs index 3ccba944ec54..0ecc7fbb90c4 100644 --- a/src/Controls/src/Core/Button/Button.cs +++ b/src/Controls/src/Core/Button/Button.cs @@ -598,7 +598,7 @@ public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo c int spacingIndex = spacingFirst ? 0 : (parts.Length == 2 ? 1 : -1); if (spacingIndex > -1) - spacing = double.Parse(parts[spacingIndex]); + spacing = double.Parse(parts[spacingIndex], CultureInfo.InvariantCulture); if (positionIndex > -1) position = (ButtonContentLayout.ImagePosition)Enum.Parse(typeof(ButtonContentLayout.ImagePosition), parts[positionIndex], true); diff --git a/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/UIContainerCell.cs b/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/UIContainerCell.cs index ad0ec77225cd..51a6c3707f6f 100644 --- a/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/UIContainerCell.cs +++ b/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/UIContainerCell.cs @@ -31,6 +31,17 @@ internal UIContainerCell(string cellId, View view, Shell shell, object context) var platformView = view.ToPlatform(); ContentView.AddSubview(platformView); platformView.AccessibilityTraits |= UIAccessibilityTrait.Button; + platformView.TranslatesAutoresizingMaskIntoConstraints = false; + + var margin = view.Margin; + var constraints = new NSLayoutConstraint[] + { + platformView.LeadingAnchor.ConstraintEqualTo(ContentView.LeadingAnchor, (nfloat)margin.Left), + platformView.TrailingAnchor.ConstraintEqualTo(ContentView.TrailingAnchor, (nfloat)(-margin.Right)), + platformView.TopAnchor.ConstraintEqualTo(ContentView.TopAnchor, (nfloat)margin.Top), + platformView.BottomAnchor.ConstraintEqualTo(ContentView.BottomAnchor, (nfloat)(-margin.Bottom)) + }; + NSLayoutConstraint.ActivateConstraints(constraints); _renderer.PlatformView.ClipsToBounds = true; ContentView.ClipsToBounds = true; diff --git a/src/Controls/src/Core/Compatibility/iOS/Extensions/ToolbarItemExtensions.cs b/src/Controls/src/Core/Compatibility/iOS/Extensions/ToolbarItemExtensions.cs index 255278a1b4a4..ef181fd68d9f 100644 --- a/src/Controls/src/Core/Compatibility/iOS/Extensions/ToolbarItemExtensions.cs +++ b/src/Controls/src/Core/Compatibility/iOS/Extensions/ToolbarItemExtensions.cs @@ -112,7 +112,9 @@ void UpdateIconAndStyle(ToolbarItem item) } item.IconImageSource.LoadImage(mauiContext, result => { - Image = result?.Value; + Image = item.IconImageSource is not FontImageSource + ? result?.Value.ImageWithRenderingMode(UIImageRenderingMode.AlwaysOriginal) + : result?.Value; Style = UIBarButtonItemStyle.Plain; }); } diff --git a/src/Controls/src/Core/Handlers/Items/CarouselViewHandler.Android.cs b/src/Controls/src/Core/Handlers/Items/CarouselViewHandler.Android.cs index abe5e4b40480..6fa39583b485 100644 --- a/src/Controls/src/Core/Handlers/Items/CarouselViewHandler.Android.cs +++ b/src/Controls/src/Core/Handlers/Items/CarouselViewHandler.Android.cs @@ -95,7 +95,7 @@ double GetItemWidth() if (double.IsInfinity(width)) return width; - itemWidth = (int)(width - Context?.ToPixels(VirtualView.PeekAreaInsets.Left) - Context?.ToPixels(VirtualView.PeekAreaInsets.Right) - Context?.ToPixels(listItemsLayout.ItemSpacing)); + itemWidth = (int)(width - Context?.ToPixels(VirtualView.PeekAreaInsets.Left) - Context?.ToPixels(VirtualView.PeekAreaInsets.Right)); } return itemWidth; @@ -112,7 +112,7 @@ double GetItemHeight() if (double.IsInfinity(height)) return height; - itemHeight = (int)(height - Context?.ToPixels(VirtualView.PeekAreaInsets.Top) - Context?.ToPixels(VirtualView.PeekAreaInsets.Bottom) - Context?.ToPixels(listItemsLayout.ItemSpacing)); + itemHeight = (int)(height - Context?.ToPixels(VirtualView.PeekAreaInsets.Top) - Context?.ToPixels(VirtualView.PeekAreaInsets.Bottom)); } return itemHeight; diff --git a/src/Controls/src/Core/Handlers/Items/SelectableItemsViewHandler.Windows.cs b/src/Controls/src/Core/Handlers/Items/SelectableItemsViewHandler.Windows.cs index 9ae6c49cc3a0..6ba7d01d4dbc 100644 --- a/src/Controls/src/Core/Handlers/Items/SelectableItemsViewHandler.Windows.cs +++ b/src/Controls/src/Core/Handlers/Items/SelectableItemsViewHandler.Windows.cs @@ -14,6 +14,7 @@ namespace Microsoft.Maui.Controls.Handlers.Items public partial class SelectableItemsViewHandler : StructuredItemsViewHandler where TItemsView : SelectableItemsView { bool _ignorePlatformSelectionChange; + bool _ignoreVirtualSelectionChange; protected override void ConnectHandler(ListViewBase platformView) { @@ -132,6 +133,13 @@ void UpdatePlatformSelection() void VirtualSelectionChanged(object sender, SelectionChangedEventArgs e) { + // When the selection changes within the SelectionChanged event, the new selection isn't immediately reflected in the view. + // After the virtual selection is correctly updated, the flag is reset to enable future updates + if (_ignoreVirtualSelectionChange) + { + _ignoreVirtualSelectionChange = false; + return; + } UpdatePlatformSelection(); } @@ -172,10 +180,10 @@ void UpdateVirtualSingleSelection() if (ItemsView != null) { - ItemsView.SelectionChanged -= VirtualSelectionChanged; + _ignoreVirtualSelectionChange = true; ItemsView.SelectedItem = selectedItem; - ItemsView.SelectionChanged += VirtualSelectionChanged; + _ignoreVirtualSelectionChange = false; } } diff --git a/src/Controls/src/Core/IndicatorView/IndicatorStackLayout.cs b/src/Controls/src/Core/IndicatorView/IndicatorStackLayout.cs index 2c6f802ff09e..cc14cea74c5f 100644 --- a/src/Controls/src/Core/IndicatorView/IndicatorStackLayout.cs +++ b/src/Controls/src/Core/IndicatorView/IndicatorStackLayout.cs @@ -98,19 +98,30 @@ internal void ResetIndicatorCount(int oldCount) } } + protected override void OnInsert(int index, IView view) + { + base.OnInsert(index, view); + ResetIndicatorStylesNonBatch(); + } + + protected override void OnRemove(int index, IView view) + { + base.OnRemove(index, view); + ResetIndicatorStylesNonBatch(); + } + void ResetIndicatorStylesNonBatch() { var indicatorCount = _indicatorView.Count; var childrenCount = Children.Count; + var maxVisible = _indicatorView.MaximumVisible; + var position = _indicatorView.Position; + var selectedIndex = position >= maxVisible ? maxVisible - 1 : position; for (int index = 0; index < childrenCount; index++) { - var maxVisible = _indicatorView.MaximumVisible; - var position = _indicatorView.Position; - var selectedIndex = position >= maxVisible ? maxVisible - 1 : position; bool isSelected = index == selectedIndex; - var visualElement = Children[index] as VisualElement; - if (visualElement is null) + if (Children[index] is not VisualElement visualElement) { return; } diff --git a/src/Controls/src/Core/Label/Label.iOS.cs b/src/Controls/src/Core/Label/Label.iOS.cs index 210da6315564..acecf544543f 100644 --- a/src/Controls/src/Core/Label/Label.iOS.cs +++ b/src/Controls/src/Core/Label/Label.iOS.cs @@ -36,19 +36,17 @@ public static void MapMaxLines(ILabelHandler handler, Label label) handler.PlatformView?.UpdateMaxLines(label); } - static void MapFormatting(ILabelHandler handler, Label label) + internal static void MapFormatting(ILabelHandler handler, Label label) { - // we need to re-apply color and font for HTML labels - if (!label.HasFormattedTextSpans && label.TextType == TextType.Html) + if (IsPlainText(label)) + { + LabelHandler.MapFormatting(handler, label); + } + else if (!label.HasFormattedTextSpans && label.TextType == TextType.Html) // we need to re-apply color and font for HTML labels { handler.UpdateValue(nameof(ILabel.TextColor)); handler.UpdateValue(nameof(ILabel.Font)); } - - if (!IsPlainText(label)) - return; - - LabelHandler.MapFormatting(handler, label); } void RecalculateSpanPositions(Size size) diff --git a/src/Controls/src/Core/Platform/iOS/Extensions/LabelExtensions.cs b/src/Controls/src/Core/Platform/iOS/Extensions/LabelExtensions.cs index f0a94c7b2ff4..4e22c982db10 100644 --- a/src/Controls/src/Core/Platform/iOS/Extensions/LabelExtensions.cs +++ b/src/Controls/src/Core/Platform/iOS/Extensions/LabelExtensions.cs @@ -14,7 +14,22 @@ public static void UpdateText(this UILabel platformLabel, Label label) switch (label.TextType) { case TextType.Html: - platformLabel.UpdateTextHtml(label); + // NOTE: Setting HTML text this will crash with some sort of consistency error. + // https://github.com/dotnet/maui/issues/25946 + // Here we have to dispatch back the the main queue to avoid the crash. + // This is observed with CarouselView 1 but not with 2, so hopefully this + // will be just disappear once we switch. + CoreFoundation.DispatchQueue.MainQueue.DispatchAsync(() => + { + platformLabel.UpdateTextHtml(label); + + if (label.Handler is LabelHandler labelHandler) + Label.MapFormatting(labelHandler, label); + + // NOTE: Because we are updating text outside the normal layout + // pass, we need to invalidate the measure for the next pass. + label.InvalidateMeasure(); + }); break; default: diff --git a/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.cs b/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.cs index d779e6798e29..d1f265ac44af 100644 --- a/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.cs +++ b/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.cs @@ -333,6 +333,10 @@ await AttachAndRun(layout, async (handler) => label.TextType = TextType.Html; + // We need to delay here because platformLabel.UpdateTextHtml(label) and label.InvalidateMeasure() + // are dispatched asynchronously to the main thread and may not complete immediately. + // https://github.com/dotnet/maui/pull/26153 + await Task.Delay(100); await platformView.AssertDoesNotContainColor(Colors.Red, MauiContext); }); } @@ -517,9 +521,13 @@ public async Task FontStuffAppliesEvenInHtmlMode() Text = "

Test

" }; - await InvokeOnMainThreadAsync(() => + await InvokeOnMainThreadAsync(async () => { var handler = CreateHandler(label); + // We need to delay here because platformLabel.UpdateTextHtml(label) and label.InvalidateMeasure() + // are dispatched asynchronously to the main thread and may not complete immediately. + // https://github.com/dotnet/maui/pull/26153 + await Task.Delay(100); AssertEquivalentFont(handler, label.ToFont()); }); } @@ -715,9 +723,13 @@ public async Task FontStuffAfterTextTypeIsCorrect() Text = "

Test

" }; - await InvokeOnMainThreadAsync(() => + await InvokeOnMainThreadAsync(async () => { var handler = CreateHandler(label); + // We need to delay here because platformLabel.UpdateTextHtml(label) and label.InvalidateMeasure() + // are dispatched asynchronously to the main thread and may not complete immediately. + // https://github.com/dotnet/maui/pull/26153 + await Task.Delay(100); label.FontFamily = "Baskerville"; label.FontSize = 64; AssertEquivalentFont(handler, label.ToFont()); diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CarouselViewShouldRenderCorrectly.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CarouselViewShouldRenderCorrectly.png index bf3e23f5eedd..38d36f30bb96 100644 Binary files a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CarouselViewShouldRenderCorrectly.png and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CarouselViewShouldRenderCorrectly.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_ChangeColor_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_ChangeColor_VerifyVisualState.png new file mode 100644 index 000000000000..cd79afb1dbe4 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_ChangeColor_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_SetIsCheckedAndColor_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_SetIsCheckedAndColor_VerifyVisualState.png new file mode 100644 index 000000000000..9512f06aeff9 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/CheckBox_SetIsCheckedAndColor_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithDownsize.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithDownsize.png new file mode 100644 index 000000000000..66dc952c1bce Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithDownsize.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeBleed.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeBleed.png new file mode 100644 index 000000000000..07c9e2ac71ce Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeBleed.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeFit.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeFit.png new file mode 100644 index 000000000000..787f1027cfba Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeFit.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeStretch.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeStretch.png new file mode 100644 index 000000000000..6c42fde28074 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ImagePaintWithResizeModeStretch.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/IndicatorWithTemplateShouldBeVisible.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/IndicatorWithTemplateShouldBeVisible.png new file mode 100644 index 000000000000..bf5ca8fc40b6 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/IndicatorWithTemplateShouldBeVisible.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ProgrammaticallyOpenedSwipeViewShouldBeVisible.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ProgrammaticallyOpenedSwipeViewShouldBeVisible.png new file mode 100644 index 000000000000..bfd51c2774b9 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ProgrammaticallyOpenedSwipeViewShouldBeVisible.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Default_Configuration_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Default_Configuration_VerifyVisualState.png new file mode 100644 index 000000000000..7b347219b7ac Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Default_Configuration_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Initial_Configuration_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Initial_Configuration_VerifyVisualState.png new file mode 100644 index 000000000000..7cf311715f76 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_Checking_Initial_Configuration_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_FlowDirectionAndContent_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_FlowDirectionAndContent_VerifyVisualState.png new file mode 100644 index 000000000000..0204567f86c6 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_FlowDirectionAndContent_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndCharacterSpacing_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndCharacterSpacing_VerifyVisualState.png new file mode 100644 index 000000000000..fca4c05e893e Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndCharacterSpacing_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontAttributes_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontAttributes_VerifyVisualState.png new file mode 100644 index 000000000000..3211ef3a01f6 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontAttributes_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontSize_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontSize_VerifyVisualState.png new file mode 100644 index 000000000000..ad0adc862045 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndFontSize_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndTextColor_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndTextColor_VerifyVisualState.png new file mode 100644 index 000000000000..f9b1ab0ca841 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetContentAndTextColor_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontAttributesAndTextColor_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontAttributesAndTextColor_VerifyVisualState.png new file mode 100644 index 000000000000..4f05c29b4639 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontAttributesAndTextColor_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontAttributes_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontAttributes_VerifyVisualState.png new file mode 100644 index 000000000000..f44b4f510ea8 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontAttributes_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontSize_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontSize_VerifyVisualState.png new file mode 100644 index 000000000000..749bfa6f47f1 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontFamilyAndFontSize_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontSizeAndFontAttributes_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontSizeAndFontAttributes_VerifyVisualState.png new file mode 100644 index 000000000000..706129dfbf39 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/RadioButton_SetFontSizeAndFontAttributes_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldFlyoutTextWrapsInLandscape.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldFlyoutTextWrapsInLandscape.png new file mode 100644 index 000000000000..38b7a2626648 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldFlyoutTextWrapsInLandscape.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldUpdateButtonShadowWithTransparentColor.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldUpdateButtonShadowWithTransparentColor.png new file mode 100644 index 000000000000..0b0a20f21c8d Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ShouldUpdateButtonShadowWithTransparentColor.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/Stepper_ChangeFlowDirection_RTL_VerifyVisualState.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/Stepper_ChangeFlowDirection_RTL_VerifyVisualState.png new file mode 100644 index 000000000000..4834c3caed21 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/Stepper_ChangeFlowDirection_RTL_VerifyVisualState.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ToolbarItemShouldBeCorrectlyRendered.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ToolbarItemShouldBeCorrectlyRendered.png new file mode 100644 index 000000000000..62ea74d6633c Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/ToolbarItemShouldBeCorrectlyRendered.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenMultipleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenMultipleModePreSelection.png new file mode 100644 index 000000000000..e1a23819b20c Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenMultipleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenSingleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenSingleModePreSelection.png new file mode 100644 index 000000000000..22a205f2aa3f Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsGroupedListWhenSingleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenMultipleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenMultipleModePreSelection.png new file mode 100644 index 000000000000..91d06346ede6 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenMultipleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenSingleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenSingleModePreSelection.png new file mode 100644 index 000000000000..204b4d616904 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyModelItemsObservableCollectionWhenSingleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySelectedItemClearsOnNullAssignment.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySelectedItemClearsOnNullAssignment.png new file mode 100644 index 000000000000..644f90fdc78d Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySelectedItemClearsOnNullAssignment.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySpacingAffectsItemSize.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySpacingAffectsItemSize.png new file mode 100644 index 000000000000..3939d43e4e45 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifySpacingAffectsItemSize.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsGroupedListWhenMultipleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsGroupedListWhenMultipleModePreSelection.png new file mode 100644 index 000000000000..38e9b4139695 Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsGroupedListWhenMultipleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenMultipleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenMultipleModePreSelection.png new file mode 100644 index 000000000000..e34539333e2a Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenMultipleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenSingleModePreSelection.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenSingleModePreSelection.png new file mode 100644 index 000000000000..c023d615bc8b Binary files /dev/null and b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/VerifyStringItemsObservableCollectionWhenSingleModePreSelection.png differ diff --git a/src/Controls/tests/TestCases.HostApp/Controls.TestCases.HostApp.csproj b/src/Controls/tests/TestCases.HostApp/Controls.TestCases.HostApp.csproj index 206ed3229951..fc240a71fd19 100644 --- a/src/Controls/tests/TestCases.HostApp/Controls.TestCases.HostApp.csproj +++ b/src/Controls/tests/TestCases.HostApp/Controls.TestCases.HostApp.csproj @@ -66,6 +66,7 @@ + diff --git a/src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs b/src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs index b40536976087..568fb3b1f1dc 100644 --- a/src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs +++ b/src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs @@ -68,17 +68,20 @@ public override string ToString() new GalleryPageFactory(() => new ListViewCoreGalleryPage(), "ListView Gallery"), new GalleryPageFactory(() => new PickerCoreGalleryPage(), "Picker Gallery"), new GalleryPageFactory(() => new ProgressBarCoreGalleryPage(), "Progress Bar Gallery"), + new GalleryPageFactory(() => new RadioButtonControlPage(), "RadioButton Feature Matrix"), new GalleryPageFactory(() => new RadioButtonCoreGalleryPage(), "RadioButton Gallery"), new GalleryPageFactory(() => new ScrollViewCoreGalleryPage(), "ScrollView Gallery"), new GalleryPageFactory(() => new ShadowFeaturePage(), "Shadow Feature Matrix"), new GalleryPageFactory(() => new SearchBarCoreGalleryPage(), "Search Bar Gallery"), new GalleryPageFactory(() => new SliderCoreGalleryPage(), "Slider Gallery"), + new GalleryPageFactory(() => new StepperControlPage(), "Stepper Feature Matrix"), new GalleryPageFactory(() => new StepperCoreGalleryPage(), "Stepper Gallery"), new GalleryPageFactory(() => new SwitchCoreGalleryPage(), "Switch Gallery"), new GalleryPageFactory(() => new SwipeViewCoreGalleryPage(), "SwipeView Gallery"), new GalleryPageFactory(() => new TimePickerCoreGalleryPage(), "Time Picker Gallery"), new GalleryPageFactory(() => new WebViewCoreGalleryPage(), "WebView Gallery"), new GalleryPageFactory(() => new SliderControlPage(), "Slider Feature Matrix"), + new GalleryPageFactory(() => new CheckBoxControlPage(), "CheckBox Feature Matrix"), new GalleryPageFactory(() => new CollectionViewFeaturePage(), "CollectionView Feature Matrix"), new GalleryPageFactory(() => new LabelControlPage(), "Label Feature Matrix"), new GalleryPageFactory(() => new CarouselViewFeaturePage(), "CarouselView Feature Matrix"), diff --git a/src/Controls/tests/TestCases.HostApp/FeatureMatrix/CheckBox/CheckBoxControlPage.xaml b/src/Controls/tests/TestCases.HostApp/FeatureMatrix/CheckBox/CheckBoxControlPage.xaml new file mode 100644 index 000000000000..8238efa68edc --- /dev/null +++ b/src/Controls/tests/TestCases.HostApp/FeatureMatrix/CheckBox/CheckBoxControlPage.xaml @@ -0,0 +1,124 @@ + + + + + + + + + + +