More changes to get Tizen packages published.
This commit is contained in:
Родитель
e4259140af
Коммит
a711e65e02
|
@ -34,5 +34,7 @@
|
||||||
<file src="src/System.Graphics.Forms/bin/Release/monoandroid10.0/System.Graphics.Forms.pdb" target="lib/monoandroid10.0/System.Graphics.Forms.pdb"/>
|
<file src="src/System.Graphics.Forms/bin/Release/monoandroid10.0/System.Graphics.Forms.pdb" target="lib/monoandroid10.0/System.Graphics.Forms.pdb"/>
|
||||||
<file src="src/System.Graphics.Forms/bin/Release/xamarin.mac20/System.Graphics.Forms.dll" target="lib/xamarin.mac20/System.Graphics.Forms.dll"/>
|
<file src="src/System.Graphics.Forms/bin/Release/xamarin.mac20/System.Graphics.Forms.dll" target="lib/xamarin.mac20/System.Graphics.Forms.dll"/>
|
||||||
<file src="src/System.Graphics.Forms/bin/Release/xamarin.mac20/System.Graphics.Forms.pdb" target="lib/xamarin.mac20/System.Graphics.Forms.pdb"/>
|
<file src="src/System.Graphics.Forms/bin/Release/xamarin.mac20/System.Graphics.Forms.pdb" target="lib/xamarin.mac20/System.Graphics.Forms.pdb"/>
|
||||||
|
<file src="src/System.Graphics.Forms/bin/Release/tizen40/System.Graphics.Skia.Forms.dll" target="lib/tizen40/System.Graphics.Forms.dll"/>
|
||||||
|
<file src="src/System.Graphics.Forms/bin/Release/tizen40/System.Graphics.Skia.Forms.pdb" target="lib/tizen40/System.Graphics.Forms.pdb"/>
|
||||||
</files>
|
</files>
|
||||||
</package>
|
</package>
|
|
@ -1,16 +1,16 @@
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Graphics.Android;
|
using System.Graphics.Forms;
|
||||||
using System.Graphics.Forms.Android;
|
using System.Graphics.Skia.Forms;
|
||||||
using Android.Content;
|
using Android.Content;
|
||||||
using Xamarin.Forms;
|
using Xamarin.Forms;
|
||||||
using Xamarin.Forms.Internals;
|
using Xamarin.Forms.Internals;
|
||||||
using Xamarin.Forms.Platform.Android;
|
using Xamarin.Forms.Platform.Android;
|
||||||
|
|
||||||
[assembly: ExportRenderer(typeof(System.Graphics.Forms.SkiaGraphicsView), typeof(SkiaGraphicsViewRenderer))]
|
[assembly: ExportRenderer(typeof(System.Graphics.Forms.SkiaGraphicsView), typeof(SkiaGraphicsViewRenderer))]
|
||||||
namespace System.Graphics.Forms.Android
|
namespace System.Graphics.Skia.Forms
|
||||||
{
|
{
|
||||||
[Preserve]
|
[Preserve]
|
||||||
public class SkiaGraphicsViewRenderer : ViewRenderer<System.Graphics.Forms.SkiaGraphicsView, NativeGraphicsView>
|
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, System.Graphics.Skia.Views.SkiaGraphicsView>
|
||||||
{
|
{
|
||||||
public SkiaGraphicsViewRenderer(Context context) : base(context)
|
public SkiaGraphicsViewRenderer(Context context) : base(context)
|
||||||
{
|
{
|
||||||
|
@ -29,7 +29,7 @@ namespace System.Graphics.Forms.Android
|
||||||
|
|
||||||
if (e.NewElement != null)
|
if (e.NewElement != null)
|
||||||
{
|
{
|
||||||
SetNativeControl(new NativeGraphicsView(Context));
|
SetNativeControl(new System.Graphics.Skia.Views.SkiaGraphicsView(Context));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,16 +1,14 @@
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Graphics.CoreGraphics;
|
|
||||||
using System.Graphics.Forms;
|
using System.Graphics.Forms;
|
||||||
using System.Graphics.Forms.Mac;
|
|
||||||
using Foundation;
|
using Foundation;
|
||||||
using Xamarin.Forms;
|
using Xamarin.Forms;
|
||||||
using Xamarin.Forms.Platform.MacOS;
|
using Xamarin.Forms.Platform.MacOS;
|
||||||
|
|
||||||
[assembly: ExportRenderer(typeof(SkiaGraphicsView), typeof(SkiaGraphicsViewRenderer))]
|
[assembly: ExportRenderer(typeof(SkiaGraphicsView), typeof(System.Graphics.Skia.Views.SkiaGraphicsView))]
|
||||||
namespace System.Graphics.Forms.Mac
|
namespace System.Graphics.Skia.Forms
|
||||||
{
|
{
|
||||||
[Preserve]
|
[Preserve]
|
||||||
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, NativeGraphicsView>
|
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, System.Graphics.Skia.Views.SkiaGraphicsView>
|
||||||
{
|
{
|
||||||
protected override void OnElementChanged(ElementChangedEventArgs<SkiaGraphicsView> e)
|
protected override void OnElementChanged(ElementChangedEventArgs<SkiaGraphicsView> e)
|
||||||
{
|
{
|
||||||
|
@ -24,7 +22,7 @@ namespace System.Graphics.Forms.Mac
|
||||||
|
|
||||||
if (e.NewElement != null)
|
if (e.NewElement != null)
|
||||||
{
|
{
|
||||||
SetNativeControl(new NativeGraphicsView());
|
SetNativeControl(new System.Graphics.Skia.Views.SkiaGraphicsView());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,45 @@
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Graphics.Forms;
|
||||||
|
using Xamarin.Forms;
|
||||||
|
using Xamarin.Forms.Internals;
|
||||||
|
using Xamarin.Forms.Platform.Tizen;
|
||||||
|
using XForms = Xamarin.Forms.Forms;
|
||||||
|
|
||||||
|
[assembly: ExportRenderer(typeof(SkiaGraphicsView), typeof(System.Graphics.Skia.Views.SkiaGraphicsView))]
|
||||||
|
namespace System.Graphics.Skia.Forms
|
||||||
|
{
|
||||||
|
[Preserve]
|
||||||
|
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, System.Graphics.Skia.Views.SkiaGraphicsView>
|
||||||
|
{
|
||||||
|
protected override void OnElementChanged(ElementChangedEventArgs<SkiaGraphicsView> e)
|
||||||
|
{
|
||||||
|
base.OnElementChanged(e);
|
||||||
|
|
||||||
|
if (e.OldElement != null)
|
||||||
|
{
|
||||||
|
// Unsubscribe from event handlers and cleanup any resources
|
||||||
|
SetNativeControl(null);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (e.NewElement != null)
|
||||||
|
{
|
||||||
|
SetNativeControl(new System.Graphics.Skia.Views.SkiaGraphicsView(XForms.NativeParent));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnElementPropertyChanged(
|
||||||
|
object sender,
|
||||||
|
PropertyChangedEventArgs e)
|
||||||
|
{
|
||||||
|
base.OnElementPropertyChanged(sender, e);
|
||||||
|
|
||||||
|
if (e.PropertyName == nameof(SkiaGraphicsView.Drawable))
|
||||||
|
UpdateDrawable();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void UpdateDrawable()
|
||||||
|
{
|
||||||
|
Control.Drawable = Element.Drawable;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,16 +1,15 @@
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Graphics.CoreGraphics;
|
|
||||||
using System.Graphics.Forms;
|
using System.Graphics.Forms;
|
||||||
using System.Graphics.Forms.iOS;
|
using System.Graphics.Skia.Forms;
|
||||||
using Foundation;
|
using Foundation;
|
||||||
using Xamarin.Forms;
|
using Xamarin.Forms;
|
||||||
using Xamarin.Forms.Platform.iOS;
|
using Xamarin.Forms.Platform.iOS;
|
||||||
|
|
||||||
[assembly: ExportRenderer(typeof(SkiaGraphicsView), typeof(SkiaGraphicsViewRenderer))]
|
[assembly: ExportRenderer(typeof(SkiaGraphicsView), typeof(SkiaGraphicsViewRenderer))]
|
||||||
namespace System.Graphics.Forms.iOS
|
namespace System.Graphics.Skia.Forms
|
||||||
{
|
{
|
||||||
[Preserve]
|
[Preserve]
|
||||||
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, NativeGraphicsView>
|
public class SkiaGraphicsViewRenderer : ViewRenderer<SkiaGraphicsView, System.Graphics.Skia.Views.SkiaGraphicsView>
|
||||||
{
|
{
|
||||||
protected override void OnElementChanged(ElementChangedEventArgs<SkiaGraphicsView> e)
|
protected override void OnElementChanged(ElementChangedEventArgs<SkiaGraphicsView> e)
|
||||||
{
|
{
|
||||||
|
@ -24,7 +23,7 @@ namespace System.Graphics.Forms.iOS
|
||||||
|
|
||||||
if (e.NewElement != null)
|
if (e.NewElement != null)
|
||||||
{
|
{
|
||||||
SetNativeControl(new NativeGraphicsView());
|
SetNativeControl(new System.Graphics.Skia.Views.SkiaGraphicsView());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<Project Sdk="MSBuild.Sdk.Extras">
|
<Project Sdk="MSBuild.Sdk.Extras">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netstandard2.1;netstandard2.0;Xamarin.iOS10;MonoAndroid10.0;Xamarin.Mac20;</TargetFrameworks>
|
<TargetFrameworks>netstandard2.1;netstandard2.0;Xamarin.iOS10;MonoAndroid10.0;Xamarin.Mac20;tizen40;</TargetFrameworks>
|
||||||
<RootNamespace>System.Graphics.Forms</RootNamespace>
|
<RootNamespace>System.Graphics.Forms</RootNamespace>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
@ -16,5 +16,6 @@
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Xamarin.Forms" Version="4.8.0.1821" />
|
<PackageReference Include="Xamarin.Forms" Version="4.8.0.1821" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<Import Project="..\targets\MultiTargeting.targets" />
|
<Import Project="..\targets\MultiTargeting.targets" />
|
||||||
</Project>
|
</Project>
|
Загрузка…
Ссылка в новой задаче