Skip to content

Commit

Permalink
Merge branch 'main' into dev--moljac--fix-resizetizer-invalid-png-fro…
Browse files Browse the repository at this point in the history
…m-svg
  • Loading branch information
moljac committed Mar 20, 2024
2 parents 13ee3c8 + e0b85ca commit 0c28a1b
Show file tree
Hide file tree
Showing 101 changed files with 1,790 additions and 493 deletions.
2 changes: 1 addition & 1 deletion .config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
]
},
"microsoft.dotnet.xharness.cli": {
"version": "9.0.0-prerelease.24129.1",
"version": "9.0.0-prerelease.24160.7",
"commands": [
"xharness"
]
Expand Down
4 changes: 3 additions & 1 deletion .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ body:
options:
-
- 9.0.0-preview.1.9973
- 8.0.10 SR3
- 8.0.7 SR2
- 8.0.6 SR1
- 8.0.3 GA
Expand Down Expand Up @@ -107,7 +108,8 @@ body:
- 8.0.0-rc.2.9511
- 8.0.3 GA
- 8.0.6 SR1
- 8.0.7 SR2
- 8.0.7 SR2
- 8.0.10 SR3
- 9.0.0-preview.1.9973
validations:
required: true
Expand Down
2 changes: 1 addition & 1 deletion GitInfo.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.20-ci.net8
8.0.20-ci.net8
2 changes: 1 addition & 1 deletion Microsoft.Maui-dev.sln
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UITest.Appium", "src\TestUt
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UITest.NUnit", "src\TestUtils\src\UITest.NUnit\UITest.NUnit.csproj", "{A307B624-48D4-494E-A70D-5B3CDF6620CF}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Controls.SourceGen.UnitTests", "src\Controls\tests\SourceGen.UnitTests\Conrtrols.SourceGen.UnitTests\Controls.SourceGen.UnitTests.csproj", "{06747B55-91DB-47F5-B7A2-56526C28A0D3}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Controls.SourceGen.UnitTests", "src\Controls\tests\SourceGen.UnitTests\Controls.SourceGen.UnitTests\Controls.SourceGen.UnitTests.csproj", "{06747B55-91DB-47F5-B7A2-56526C28A0D3}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SourceGen.UnitTests", "src\Controls\tests\SourceGen.UnitTests\SourceGen.UnitTests.csproj", "{BC7F7C82-694F-4B97-86FC-273FB3FACA25}"
EndProject
Expand Down
12 changes: 6 additions & 6 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<Dependencies>
<ProductDependencies>
<Dependency Name="Microsoft.DotNet.XHarness.TestRunners.Common" Version="9.0.0-prerelease.24129.1">
<Dependency Name="Microsoft.DotNet.XHarness.TestRunners.Common" Version="9.0.0-prerelease.24160.7">
<Uri>https://github.com/dotnet/xharness</Uri>
<Sha>9649ddab48b3795a49c6b51ccf588d56ca4be4e5</Sha>
<Sha>36310c81aed0452963ebf26866fc9f1b95d72dbb</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="9.0.0-prerelease.24129.1">
<Dependency Name="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="9.0.0-prerelease.24160.7">
<Uri>https://github.com/dotnet/xharness</Uri>
<Sha>9649ddab48b3795a49c6b51ccf588d56ca4be4e5</Sha>
<Sha>36310c81aed0452963ebf26866fc9f1b95d72dbb</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.XHarness.CLI" Version="9.0.0-prerelease.24129.1">
<Dependency Name="Microsoft.DotNet.XHarness.CLI" Version="9.0.0-prerelease.24160.7">
<Uri>https://github.com/dotnet/xharness</Uri>
<Sha>9649ddab48b3795a49c6b51ccf588d56ca4be4e5</Sha>
<Sha>36310c81aed0452963ebf26866fc9f1b95d72dbb</Sha>
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
Expand Down
6 changes: 3 additions & 3 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@
<_HarfBuzzSharpVersion>7.3.0</_HarfBuzzSharpVersion>
<_SkiaSharpNativeAssetsVersion>0.0.0-commit.e2c5c86249621857107c779af0f79b4d06613766.655</_SkiaSharpNativeAssetsVersion>
<MicrosoftTemplateEngineTasksVersion>7.0.114</MicrosoftTemplateEngineTasksVersion>
<MicrosoftDotNetXHarnessTestRunnersCommonVersion>9.0.0-prerelease.24129.1</MicrosoftDotNetXHarnessTestRunnersCommonVersion>
<MicrosoftDotNetXHarnessTestRunnersXunitVersion>9.0.0-prerelease.24129.1</MicrosoftDotNetXHarnessTestRunnersXunitVersion>
<MicrosoftDotNetXHarnessCLIVersion>9.0.0-prerelease.24129.1</MicrosoftDotNetXHarnessCLIVersion>
<MicrosoftDotNetXHarnessTestRunnersCommonVersion>9.0.0-prerelease.24160.7</MicrosoftDotNetXHarnessTestRunnersCommonVersion>
<MicrosoftDotNetXHarnessTestRunnersXunitVersion>9.0.0-prerelease.24160.7</MicrosoftDotNetXHarnessTestRunnersXunitVersion>
<MicrosoftDotNetXHarnessCLIVersion>9.0.0-prerelease.24160.7</MicrosoftDotNetXHarnessCLIVersion>
<TizenUIExtensionsVersion>0.9.2</TizenUIExtensionsVersion>
<SvgSkiaPackageVersion>1.0.0.16</SvgSkiaPackageVersion>
<FizzlerPackageVersion>1.3.0</FizzlerPackageVersion>
Expand Down
37 changes: 37 additions & 0 deletions eng/pipelines/common/maui-templates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,15 @@ jobs:
- ${{ each pair in step }}:
${{ pair.key }}: ${{ pair.value }}

- ${{ if eq(RunPlatform.testName, 'RunOniOS') }}:
- bash: |
chmod +x $(System.DefaultWorkingDirectory)/eng/scripts/clean-bot.sh
chmod +x $(System.DefaultWorkingDirectory)/eng/scripts/clean-simulator-runtime.sh
$(System.DefaultWorkingDirectory)/eng/scripts/clean-bot.sh
displayName: 'Clean bot'
continueOnError: true
timeoutInMinutes: 60
- template: provision.yml
parameters:
skipXcode: ${{ eq(RunPlatform.testName, 'RunOnAndroid') }}
Expand All @@ -161,15 +170,43 @@ jobs:
DOTNET_TOKEN: $(dotnetbuilds-internal-container-read-token)
PRIVATE_BUILD: $(PrivateBuild)

- ${{ if eq(RunPlatform.testName, 'RunOniOS') }}:
- bash: |
if [ -f "$HOME/Library/Logs/CoreSimulator/*" ]; then rm -r $HOME/Library/Logs/CoreSimulator/*; fi
if [ -f "$HOME/Library/Logs/DiagnosticReports/*" ]; then rm -r $HOME/Library/Logs/DiagnosticReports/*; fi
displayName: Delete Old Simulator Logs
condition: always()
continueOnError: true
# - script: dotnet tool update Microsoft.DotNet.XHarness.CLI --add-source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/index.json --version "9.0.0-prerelease*" -g
# displayName: install xharness

- ${{ if eq(RunPlatform.testName, 'RunOniOS') }}:
- pwsh: ./build.ps1 -Script eng/devices/ios.cake --target=Cleanup --verbosity=diagnostic
displayName: Reset iOS simulators
# TODO: pass properly device type/version from top-level yml
env:
IOS_TEST_DEVICE: ios-simulator-64_17.2

- pwsh: ./build.ps1 --target=dotnet-integration-build --verbosity=diagnostic
displayName: Build Microsoft.Maui.IntegrationTests

- pwsh: ./build.ps1 --target=dotnet-integration-test --filter="Name=${{ RunPlatform.testName }}" --resultsfilename="integration-run-${{ RunPlatform.testName }}" --verbosity=diagnostic
displayName: Run $(PLATFORM_NAME) templates run tests
continueOnError: true
# TODO: pass properly device type/version from top-level yml
${{ if eq(RunPlatform.testName, 'RunOniOS') }}:
env:
IOS_TEST_DEVICE: ios-simulator-64_17.2

- ${{ if eq(RunPlatform.testName, 'RunOniOS') }}:
- bash: |
suffix=$(date +%Y%m%d%H%M%S)
zip -9r "$(LogDirectory)/CoreSimulatorLog_${suffix}.zip" "$HOME/Library/Logs/CoreSimulator/"
zip -9r "$(LogDirectory)/DiagnosticReports_${suffix}.zip" "$HOME/Library/Logs/DiagnosticReports/"
displayName: Zip Simulator Logs
condition: always()
continueOnError: true
- task: PublishTestResults@2
displayName: Publish the $(PLATFORM_NAME) templates run tests
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ async void InitCV()

#if UITEST
[Test]
[Compatibility.UITests.FailsOnMauiIOS]
public void Issue10222Test()
{
RunningApp.WaitForElement(q => q.Marked("goTo"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ protected override void Init()

#if UITEST
[Test]
[Compatibility.UITests.FailsOnMauiAndroid]
public void Issue774TestsDismissActionSheetAfterRotation ()
{
RunningApp.Tap(q => q.Button("Show ActionSheet"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,10 +156,11 @@ public static void RemoveBackgroundLayer(this CALayer layer)
if (layer.Name == BackgroundLayer)
layer?.RemoveFromSuperLayer();

if (layer.Sublayers == null || layer.Sublayers.Count() == 0)
var sublayers = layer.Sublayers;
if (sublayers is null || sublayers.Length == 0)
return;

foreach (var subLayer in layer.Sublayers)
foreach (var subLayer in sublayers)
{
if (subLayer.Name == BackgroundLayer)
subLayer?.RemoveFromSuperLayer();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@
<MauiImage Include="Resources\Images\dotnet_bot.svg" Link="Resources\Images\small_dotnet_bot.svg" Color="#FFFFFF" BaseSize="64,64" />
<MauiImage Include="Resources\AppIcons\appicon.svg" ForegroundFile="Resources\AppIcons\appicon_foreground.svg" IsAppIcon="true" />
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#FFFFFF" BaseSize="168,208" />
<MauiFont Include="Resources\Fonts\OpenSans-Regular.ttf" />
</ItemGroup>

<Import Project="$(MauiSrcDirectory)Maui.InTree.props" Condition=" '$(UseMaui)' != 'true' " />

</Project>
33 changes: 17 additions & 16 deletions src/Controls/samples/Controls.Sample.UITests/Issues/Issue18242.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,37 @@
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Maui.Controls.Sample.Issues.Issue18242"
Title="Issue 18242">
<VerticalStackLayout
Padding="12">
<Label
<VerticalStackLayout
Padding="12"
Grid.Column="0">
<Label
AutomationId="WaitForStubControl"
Text="1. The image must adapt to the size of the Button and be in the position determined by the ContentLayout property."/>
<Label
<Label
Text="Button with Height"/>
<Button
<Button
HeightRequest="50"
ImageSource="dotnet_bot.png"
ContentLayout="Left,10"
Text="Button"/>
<Label
<Label
Text="Button without Height"/>
<Button
<Button
ImageSource="dotnet_bot.png"
ContentLayout="Left,10"
Text="Button"/>
<Label
<Label
Text="2. The image must adapt to the size of the ImageButton."/>
<Label
<Label
Text="ImageButton with Height"/>
<ImageButton
<ImageButton
HeightRequest="30"
WidthRequest="50"
Source="dotnet_bot.png"/>
<Label
Text="ImageButton without Height"/>
<ImageButton
WidthRequest="50"
Source="dotnet_bot.png"/>
</VerticalStackLayout>
<Label
Text="ImageButton without Height"/>
<ImageButton
WidthRequest="50"
Source="dotnet_bot.png"/>
</VerticalStackLayout>
</ContentPage>
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Maui.Controls.Sample.Issues.Issue19556"
xmlns:ios="clr-namespace:Microsoft.Maui.Controls.PlatformConfiguration.iOSSpecific;assembly=Microsoft.Maui.Controls"
ios:NavigationPage.PrefersLargeTitles="false"
Title="Issue19556">
<StackLayout Padding="30,0" Spacing="0">
<Label Text="NET Multi-platform App UI monospace"
FontFamily="monospace"
AutomationId="label"
SemanticProperties.HeadingLevel="Level1" />
<Label Text=".NET Multi-platform App UI sans-serif-condensed"
FontFamily="sans-serif-condensed"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif-condensed" />
<Label Text=".NET Multi-platform App UI sans-serif-condensed-light"
FontFamily="sans-serif-condensed-light"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif-condensed-light" />
<Label Text=".NET Multi-platform App UI serif"
FontFamily="serif"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I serif " />
<Label Text=".NET Multi-platform App UI sans-serif"
FontFamily="sans-serif"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif" />
<Label Text=".NET Multi-platform App UI sans-serif-black"
FontFamily="sans-serif-black"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif-black" />
<Label Text=".NET Multi-platform App UI sans-serif-light"
FontFamily="sans-serif-light"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif-light" />
<Label Text=".NET Multi-platform App UI sans-serif-medium"
FontFamily="sans-serif-medium"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I sans-serif-medium" />
</StackLayout>
</ContentPage>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
using Microsoft.Maui.Controls;
using Microsoft.Maui.Controls.Xaml;
namespace Maui.Controls.Sample.Issues;

[XamlCompilation(XamlCompilationOptions.Compile)]
[Issue(IssueTracker.Github, 19556, "[Android] Systemfonts (light/black etc.) not working", PlatformAffected.Android)]

public partial class Issue19556 : ContentPage
{
public Issue19556()
{
InitializeComponent();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
Title="Issue 20294"
x:Class="Maui.Controls.Sample.Issues.Issue20294">
<CollectionView SelectionMode="Single" Margin="10.0" AutomationId="theCollectionView">
<CollectionView.ItemsSource>
<x:Array Type="{x:Type x:String}">
<x:String>ONE</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>asdf</x:String>
<x:String>LAST</x:String>
</x:Array>
</CollectionView.ItemsSource>
<CollectionView.ItemsLayout>
<LinearItemsLayout
Orientation="Vertical"
ItemSpacing="15"/>
</CollectionView.ItemsLayout>
<CollectionView.Footer>
<Label HeightRequest="45" Text="FOOTER" AutomationId="FOOTER"/>
</CollectionView.Footer>
<CollectionView.ItemTemplate>
<DataTemplate x:DataType="x:String">
<Border AutomationId="{Binding}" StrokeThickness="0.2">
<Label Text="{Binding}" FontSize="20"/>
</Border>
</DataTemplate>
</CollectionView.ItemTemplate>
</CollectionView>
</ContentPage>
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
using Microsoft.Maui.Controls;
using Microsoft.Maui.Controls.Xaml;

namespace Maui.Controls.Sample.Issues
{
[XamlCompilation(XamlCompilationOptions.Compile)]
[Issue(IssueTracker.Github, 20294, "CollectionView containing a Footer and a Border with StrokeThickness set to decimal value crashes on scroll", PlatformAffected.iOS)]
public partial class Issue20294 : ContentPage
{
public Issue20294()
{
InitializeComponent();
}
}
}
Loading

0 comments on commit 0c28a1b

Please sign in to comment.