From 36e12f3a75a000f723eba62d6278b7e19d223bff Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Tue, 1 Mar 2022 23:36:09 +0200 Subject: [PATCH 1/7] Update azure-pipelines.yml --- scripts/azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index afb032434ea..a914dede451 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -44,7 +44,7 @@ variables: DOTNET_VERSION_PREVIOUS: 3.1.413 DOTNET_VERSION: 6.0.200 DOTNET_VERSION_PREVIEW: '' - DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.200/preview.13.json' + DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.200/preview.14.json' VS_VERSION_PREVIEW: 17/pre CONFIGURATION: 'Release' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true From 7a63aa7ad950dc552d256074757020d157b3a91f Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Tue, 1 Mar 2022 23:39:09 +0200 Subject: [PATCH 2/7] Update azure-pipelines.yml --- scripts/azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index a914dede451..7c1966688e7 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -43,7 +43,7 @@ variables: XCODE_VERSION: 12.4 DOTNET_VERSION_PREVIOUS: 3.1.413 DOTNET_VERSION: 6.0.200 - DOTNET_VERSION_PREVIEW: '' + DOTNET_VERSION_PREVIEW: '6.0.200-rtm.22107.3' DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.200/preview.14.json' VS_VERSION_PREVIEW: 17/pre CONFIGURATION: 'Release' From d2245d459f28d8a9e2b2a2a18300541be7a349f6 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Tue, 1 Mar 2022 23:41:08 +0200 Subject: [PATCH 3/7] Update install-dotnet-workloads.ps1 --- scripts/install-dotnet-workloads.ps1 | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scripts/install-dotnet-workloads.ps1 b/scripts/install-dotnet-workloads.ps1 index 63a61dc7822..df505433977 100644 --- a/scripts/install-dotnet-workloads.ps1 +++ b/scripts/install-dotnet-workloads.ps1 @@ -9,8 +9,12 @@ $ErrorActionPreference = 'Stop' $env:DOTNET_ROOT="$InstallDir" $previewFeed = 'https://api.nuget.org/v3/index.json' +$previewRuntime = 'https://api.nuget.org/v3/index.json' +$previewEmscripten = 'https://api.nuget.org/v3/index.json' if ($IsPreview) { $previewFeed = 'https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet6/nuget/v3/index.json' + $previewRuntime = 'https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-runtime-6dd808ff-1/nuget/v3/index.json' + $previewEmscripten = 'https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-emsdk-ee0a97a0/nuget/v3/index.json' } Write-Host "Installing workloads..." @@ -18,6 +22,8 @@ Write-Host "Installing workloads..." android ios tvos macos maccatalyst wasm-tools maui ` --from-rollback-file $SourceUrl ` --source https://api.nuget.org/v3/index.json ` - --source $previewFeed + --source $previewFeed ` + --source $previewRuntime ` + --source $previewEmscripten exit $LASTEXITCODE From 81506e14f66b0c35a129d9b463bed41be4c92e08 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Wed, 2 Mar 2022 07:06:21 +0800 Subject: [PATCH 4/7] Updates --- scripts/azure-pipelines.yml | 2 +- .../SKGLViewRenderer.cs | 2 +- .../SKCanvasViewHandler.Android.cs | 24 ++++++++-------- .../SKCanvasView/SKCanvasViewHandler.Ref.cs | 2 +- .../SKCanvasViewHandler.Windows.cs | 28 +++++++++---------- .../SKCanvasView/SKCanvasViewHandler.iOS.cs | 28 +++++++++---------- 6 files changed, 43 insertions(+), 43 deletions(-) diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index 7c1966688e7..2f6e0685e23 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -12,7 +12,7 @@ parameters: - name: buildExternals displayName: 'The specific native artifacts to use for this build.' type: number - default: 0 + default: 5799634 - name: VM_IMAGE_WINDOWS type: string default: 'Azure-Pipelines-windows-2022' diff --git a/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.iOS/SKGLViewRenderer.cs b/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.iOS/SKGLViewRenderer.cs index f8016e4ddb4..2047f406098 100644 --- a/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.iOS/SKGLViewRenderer.cs +++ b/source/SkiaSharp.Views.Forms/SkiaSharp.Views.Forms.iOS/SKGLViewRenderer.cs @@ -95,7 +95,7 @@ protected override void SetupRenderLoop(bool oneShot) // redraw the view nativeView.Display(); }); - displayLink.AddToRunLoop(NSRunLoop.Current, NSRunLoop.NSDefaultRunLoopMode); + displayLink.AddToRunLoop(NSRunLoop.Current, NSRunLoopMode.Default); } } } diff --git a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Android.cs b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Android.cs index 9e0b18ef31e..2a35eeaffeb 100644 --- a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Android.cs +++ b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Android.cs @@ -11,47 +11,47 @@ public partial class SKCanvasViewHandler : ViewHandler new SKCanvasView(Context); + protected override SKCanvasView CreatePlatformView() => new SKCanvasView(Context); - protected override void ConnectHandler(SKCanvasView nativeView) + protected override void ConnectHandler(SKCanvasView platformView) { - nativeView.PaintSurface += OnPaintSurface; + platformView.PaintSurface += OnPaintSurface; - base.ConnectHandler(nativeView); + base.ConnectHandler(platformView); } - protected override void DisconnectHandler(SKCanvasView nativeView) + protected override void DisconnectHandler(SKCanvasView platformView) { - touchHandler?.Detach(nativeView); + touchHandler?.Detach(platformView); touchHandler = null; - nativeView.PaintSurface -= OnPaintSurface; + platformView.PaintSurface -= OnPaintSurface; - base.DisconnectHandler(nativeView); + base.DisconnectHandler(platformView); } // Mapper actions / properties public static void OnInvalidateSurface(SKCanvasViewHandler handler, ISKCanvasView canvasView, object? args) { - handler.NativeView?.Invalidate(); + handler.PlatformView?.Invalidate(); } public static void MapIgnorePixelScaling(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - handler.NativeView?.UpdateIgnorePixelScaling(canvasView); + handler.PlatformView?.UpdateIgnorePixelScaling(canvasView); } public static void MapEnableTouchEvents(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - if (handler.NativeView == null) + if (handler.PlatformView == null) return; handler.touchHandler ??= new SKTouchHandler( args => canvasView.OnTouch(args), (x, y) => handler.OnGetScaledCoord(x, y)); - handler.touchHandler?.SetEnabled(handler.NativeView, canvasView.EnableTouchEvents); + handler.touchHandler?.SetEnabled(handler.PlatformView, canvasView.EnableTouchEvents); } // helper methods diff --git a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Ref.cs b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Ref.cs index fecf1629007..c46026f43b8 100644 --- a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Ref.cs +++ b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Ref.cs @@ -5,7 +5,7 @@ namespace SkiaSharp.Views.Maui.Handlers { public partial class SKCanvasViewHandler : ViewHandler { - protected override object CreateNativeView() => throw new NotImplementedException(); + protected override object CreatePlatformView() => throw new NotImplementedException(); public static void MapIgnorePixelScaling(SKCanvasViewHandler handler, ISKCanvasView canvasView) { } diff --git a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Windows.cs b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Windows.cs index 2acee105f72..94242ea3668 100644 --- a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Windows.cs +++ b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.Windows.cs @@ -9,47 +9,47 @@ public partial class SKCanvasViewHandler : ViewHandler new SKXamlCanvas(); + protected override SKXamlCanvas CreatePlatformView() => new SKXamlCanvas(); - protected override void ConnectHandler(SKXamlCanvas nativeView) + protected override void ConnectHandler(SKXamlCanvas platformView) { - nativeView.PaintSurface += OnPaintSurface; + platformView.PaintSurface += OnPaintSurface; - base.ConnectHandler(nativeView); + base.ConnectHandler(platformView); } - protected override void DisconnectHandler(SKXamlCanvas nativeView) + protected override void DisconnectHandler(SKXamlCanvas platformView) { - touchHandler?.Detach(nativeView); + touchHandler?.Detach(platformView); touchHandler = null; - nativeView.PaintSurface -= OnPaintSurface; + platformView.PaintSurface -= OnPaintSurface; - base.DisconnectHandler(nativeView); + base.DisconnectHandler(platformView); } // Mapper actions / properties public static void OnInvalidateSurface(SKCanvasViewHandler handler, ISKCanvasView canvasView, object? args) { - handler.NativeView?.Invalidate(); + handler.PlatformView?.Invalidate(); } public static void MapIgnorePixelScaling(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - handler.NativeView?.UpdateIgnorePixelScaling(canvasView); + handler.PlatformView?.UpdateIgnorePixelScaling(canvasView); } public static void MapEnableTouchEvents(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - if (handler.NativeView == null) + if (handler.PlatformView == null) return; handler.touchHandler ??= new SKTouchHandler( args => canvasView.OnTouch(args), (x, y) => handler.OnGetScaledCoord(x, y)); - handler.touchHandler?.SetEnabled(handler.NativeView, canvasView.EnableTouchEvents); + handler.touchHandler?.SetEnabled(handler.PlatformView, canvasView.EnableTouchEvents); } // helper methods @@ -68,9 +68,9 @@ private void OnPaintSurface(object? sender, Windows.SKPaintSurfaceEventArgs e) private SKPoint OnGetScaledCoord(double x, double y) { - if (VirtualView?.IgnorePixelScaling == false && NativeView != null) + if (VirtualView?.IgnorePixelScaling == false && PlatformView != null) { - var scale = NativeView.Dpi; + var scale = PlatformView.Dpi; x *= scale; y *= scale; diff --git a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.iOS.cs b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.iOS.cs index fd777a88e15..4fbf664ffbf 100644 --- a/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.iOS.cs +++ b/source/SkiaSharp.Views.Maui/SkiaSharp.Views.Maui.Core/Handlers/SKCanvasView/SKCanvasViewHandler.iOS.cs @@ -10,47 +10,47 @@ public partial class SKCanvasViewHandler : ViewHandler new SKCanvasView { BackgroundColor = UIColor.Clear }; + protected override SKCanvasView CreatePlatformView() => new SKCanvasView { BackgroundColor = UIColor.Clear }; - protected override void ConnectHandler(SKCanvasView nativeView) + protected override void ConnectHandler(SKCanvasView platformView) { - nativeView.PaintSurface += OnPaintSurface; + platformView.PaintSurface += OnPaintSurface; - base.ConnectHandler(nativeView); + base.ConnectHandler(platformView); } - protected override void DisconnectHandler(SKCanvasView nativeView) + protected override void DisconnectHandler(SKCanvasView platformView) { - touchHandler?.Detach(nativeView); + touchHandler?.Detach(platformView); touchHandler = null; - nativeView.PaintSurface -= OnPaintSurface; + platformView.PaintSurface -= OnPaintSurface; - base.DisconnectHandler(nativeView); + base.DisconnectHandler(platformView); } // Mapper actions / properties public static void OnInvalidateSurface(SKCanvasViewHandler handler, ISKCanvasView canvasView, object? args) { - handler.NativeView?.SetNeedsDisplay(); + handler.PlatformView?.SetNeedsDisplay(); } public static void MapIgnorePixelScaling(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - handler.NativeView?.UpdateIgnorePixelScaling(canvasView); + handler.PlatformView?.UpdateIgnorePixelScaling(canvasView); } public static void MapEnableTouchEvents(SKCanvasViewHandler handler, ISKCanvasView canvasView) { - if (handler.NativeView == null) + if (handler.PlatformView == null) return; handler.touchHandler ??= new SKTouchHandler( args => canvasView.OnTouch(args), (x, y) => handler.OnGetScaledCoord(x, y)); - handler.touchHandler?.SetEnabled(handler.NativeView, canvasView.EnableTouchEvents); + handler.touchHandler?.SetEnabled(handler.PlatformView, canvasView.EnableTouchEvents); } // helper methods @@ -69,9 +69,9 @@ private void OnPaintSurface(object? sender, iOS.SKPaintSurfaceEventArgs e) private SKPoint OnGetScaledCoord(double x, double y) { - if (VirtualView?.IgnorePixelScaling == false && NativeView != null) + if (VirtualView?.IgnorePixelScaling == false && PlatformView != null) { - var scale = NativeView.ContentScaleFactor; + var scale = PlatformView.ContentScaleFactor; x *= scale; y *= scale; From c9aa46094e1f010531b7ceba71a8031e640bf44e Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Wed, 2 Mar 2022 07:08:12 +0800 Subject: [PATCH 5/7] feeds --- nuget.config | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/nuget.config b/nuget.config index e796bb26103..2f5e995c3b0 100644 --- a/nuget.config +++ b/nuget.config @@ -5,9 +5,7 @@ - - - - + + From 4751164f332a5a917902c038c350e5885b6b3c18 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Wed, 2 Mar 2022 15:10:56 +0800 Subject: [PATCH 6/7] ngfds --- scripts/azure-pipelines.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index 2f6e0685e23..22796e44731 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -41,8 +41,8 @@ variables: MONO_VERSION_MACOS: '6_12_7' MONO_VERSION_LINUX: '' XCODE_VERSION: 12.4 - DOTNET_VERSION_PREVIOUS: 3.1.413 - DOTNET_VERSION: 6.0.200 + DOTNET_VERSION_PREVIOUS: 3.1.416 + DOTNET_VERSION: 5.0.405 DOTNET_VERSION_PREVIEW: '6.0.200-rtm.22107.3' DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.200/preview.14.json' VS_VERSION_PREVIEW: 17/pre From f93a364e947df311cb95d2deb3f31b40da001cb6 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Wed, 2 Mar 2022 17:09:38 +0200 Subject: [PATCH 7/7] Update azure-pipelines.yml --- scripts/azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/azure-pipelines.yml b/scripts/azure-pipelines.yml index 704d525890a..bf2d4a6b8a6 100644 --- a/scripts/azure-pipelines.yml +++ b/scripts/azure-pipelines.yml @@ -12,7 +12,7 @@ parameters: - name: buildExternals displayName: 'The specific native artifacts to use for this build.' type: number - default: 5799634 + default: 0 - name: VM_IMAGE_WINDOWS type: object default: