Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): Update SamplesApp to SkiaSharp 3 #17751

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/AddIns/Uno.UI.Lottie/Uno.UI.Lottie.Reference.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
<PackageReference Include="SkiaSharp.Views.Uno.WinUI" Condition="'$(UNO_UWP_BUILD)'!='true'" />

<!-- Explicitly included to remove all assets from Uno dependencies coming from SkiaSharp.Views.* -->
<PackageReference Include="Uno.UI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
<PackageReference Include="Uno.UI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
</ItemGroup>

<Import Project="..\..\SourceGenerators\Uno.UI.SourceGenerators\Content\Uno.UI.SourceGenerators.props" />
Expand Down
4 changes: 2 additions & 2 deletions src/AddIns/Uno.UI.Lottie/Uno.UI.Lottie.Skia.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
<PackageReference Include="SkiaSharp.Views.Uno.WinUI" Condition="'$(UNO_UWP_BUILD)'!='true'" />

<!-- Explicitly included to remove all assets from Uno dependencies coming from SkiaSharp.Views.* -->
<PackageReference Include="Uno.UI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
<PackageReference Include="Uno.UI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
</ItemGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions src/AddIns/Uno.UI.Lottie/Uno.UI.Lottie.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
<PackageReference Include="SkiaSharp.Views.Uno.WinUI" Condition="'$(UNO_UWP_BUILD)'!='true'" />

<!-- Explicitly included to remove all assets from Uno dependencies coming from SkiaSharp.Views.* -->
<PackageReference Include="Uno.UI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
<PackageReference Include="Uno.UI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
</ItemGroup>

<Import Project="..\..\SourceGenerators\Uno.UI.SourceGenerators\Content\Uno.UI.SourceGenerators.props" />
Expand Down
4 changes: 2 additions & 2 deletions src/AddIns/Uno.UI.Lottie/Uno.UI.Lottie.netcoremobile.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
<PackageReference Include="SkiaSharp.Views.Uno.WinUI" Condition="'$(UNO_UWP_BUILD)'!='true'" />

<!-- Explicitly included to remove all assets from Uno dependencies coming from SkiaSharp.Views.* -->
<PackageReference Include="Uno.UI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.4.5" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
<PackageReference Include="Uno.UI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'=='true'"/>
<PackageReference Include="Uno.WinUI" Version="4.9.26" ExcludeAssets="all" IncludeAssets="none" PrivateAssets="all" Condition="'$(UNO_UWP_BUILD)'!='true'" />
</ItemGroup>

<ItemGroup Condition="$(IsAndroid)">
Expand Down
13 changes: 8 additions & 5 deletions src/Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,11 @@

<PropertyGroup>
<SkiaSharpVersion>2.88.7</SkiaSharpVersion>
<!-- TODO: Uncomment when we're net8.0+ to have SamplesApp serve as a good test for SkiaSharp 3 support -->
<!-- <SkiaSharpVersion Condition="'$(IsTestProject)' == 'true' or '$(IsSampleProject)' == 'true'">3.0.0-preview.3.1</SkiaSharpVersion> -->

<!-- SkiaSharp is no longer supporting SkiaSharp.Views.Uno, so there is no 3.x of this particular package. -->
<SkiaSharpViewsUnoVersion>$(SkiaSharpVersion)</SkiaSharpViewsUnoVersion>

<SkiaSharpVersion Condition="'$(IsTestProject)' == 'true' or '$(IsSampleProject)' == 'true'">3.0.0-preview.4.1</SkiaSharpVersion>
</PropertyGroup>

<ItemGroup>
Expand Down Expand Up @@ -98,7 +101,7 @@
<PackageReference Update="System.Numerics.Vectors" Version="4.5.0" />

<PackageReference Update="SkiaSharp.Views" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp.Views.Uno" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp.Views.Uno" Version="$(SkiaSharpViewsUnoVersion)" />
<PackageReference Update="SkiaSharp.Views.Uno.WinUI" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp.Views.WPF" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp" Version="$(SkiaSharpVersion)" />
Expand All @@ -109,11 +112,11 @@
<PackageReference Update="SkiaSharp.NativeAssets.iOS" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp.NativeAssets.MacCatalyst" Version="$(SkiaSharpVersion)" />
<PackageReference Update="SkiaSharp.NativeAssets.macos" Version="$(SkiaSharpVersion)" />

<PackageReference Update="SkiaSharp.HarfBuzz" Version="$(SkiaSharpVersion)" />

<PackageReference Update="HarfBuzzSharp.NativeAssets.macOS" Version="7.3.0.1" />
<PackageReference Update="HarfBuzzSharp.NativeAssets.Linux" Version="7.3.0.1" />
<PackageReference Update="harfbuzzsharp.nativeassets.ios" Version="7.3.0.1" />
<PackageReference Update="SkiaSharp.HarfBuzz" Version="$(SkiaSharpVersion)" />

<PackageReference Update="Svg.Skia" Version="1.0.0.1" />
<PackageReference Update="GtkSharp" Version="3.24.24.38" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -600,7 +600,9 @@ public async Task When_Png_Should_Have_High_Quality()

var skBitmapScaled = new SKBitmap(skBitmap.Info with { Width = 100, Height = 100 });

#pragma warning disable CS0618 // Type or member is obsolete
Assert.IsTrue(skBitmap.ScalePixels(skBitmapScaled, SKFilterQuality.High));
#pragma warning restore CS0618 // Type or member is obsolete

for (int x = 0; x < 100; x++)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ public async Task When_Drawn()
using var filter = SKImageFilter.CreateBlur(30.0f, 30.0f, SKImageFilter.CreateImage(image));

paint.IsAntialias = true;
#pragma warning disable CS0618 // Type or member is obsolete
paint.FilterQuality = SKFilterQuality.High;
#pragma warning restore CS0618 // Type or member is obsolete
paint.ImageFilter = filter;
canvas.DrawPaint(paint);

Expand Down
3 changes: 3 additions & 0 deletions src/Uno.UI.RuntimeTests/Uno.UI.RuntimeTests.Skia.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
<PackageReference Include="FluentAssertions" />
<PackageReference Include="MSTest.TestFramework" />
<PackageReference Include="MSTest.Analyzers" />

<PackageReference Include="SkiaSharp" />
<PackageReference Include="SkiaSharp.Harfbuzz" />
</ItemGroup>

<ItemGroup>
Expand Down
Loading