Browse Source

Merge branch 'master' into feature/skia-renderinterface

pull/2364/head
Nikita Tsukanov 7 years ago
committed by GitHub
parent
commit
ac97decd13
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      nukebuild/Build.cs
  2. 1
      samples/BindingDemo/App.xaml.cs
  3. 1
      samples/ControlCatalog.Desktop/Program.cs
  4. 1
      samples/ControlCatalog.NetCore/Program.cs
  5. 1
      samples/RenderDemo/App.xaml.cs
  6. 3
      samples/RenderDemo/MainWindow.xaml
  7. 119
      samples/RenderDemo/Pages/CustomSkiaPage.cs
  8. 1
      samples/VirtualizationDemo/Program.cs
  9. 2
      src/Avalonia.Base/Utilities/WeakEventHandlerManager.cs
  10. 4
      src/Avalonia.Controls/ListBox.cs
  11. 8
      src/Avalonia.Controls/TreeView.cs
  12. 3
      src/Avalonia.Controls/Window.cs
  13. 7
      src/Avalonia.ReactiveUI/AppBuilderExtensions.cs
  14. 8
      src/Avalonia.ReactiveUI/Attributes.cs
  15. 18
      src/Avalonia.ReactiveUI/AvaloniaActivationForViewFetcher.cs
  16. 2
      src/Avalonia.ReactiveUI/ReactiveUserControl.cs
  17. 2
      src/Avalonia.ReactiveUI/ReactiveWindow.cs
  18. 8
      src/Avalonia.ReactiveUI/RoutedViewHost.cs
  19. 1
      src/Avalonia.Styling/StyledElement.cs
  20. 7
      src/Avalonia.Visuals/Media/DrawingContext.cs
  21. 7
      src/Avalonia.Visuals/Platform/IDrawingContextImpl.cs
  22. 39
      src/Avalonia.Visuals/Rendering/SceneGraph/CustomDrawOperation.cs
  23. 9
      src/Avalonia.Visuals/Rendering/SceneGraph/DeferredDrawingContextImpl.cs
  24. 7
      src/Skia/Avalonia.Skia/DrawingContextImpl.cs
  25. 2
      src/Skia/Avalonia.Skia/FormattedTextImpl.cs
  26. 2
      src/Skia/Avalonia.Skia/FramebufferRenderTarget.cs
  27. 2
      src/Skia/Avalonia.Skia/GeometryImpl.cs
  28. 2
      src/Skia/Avalonia.Skia/GlRenderTarget.cs
  29. 10
      src/Skia/Avalonia.Skia/ISkiaDrawingContextImpl.cs
  30. 2
      src/Skia/Avalonia.Skia/ImmutableBitmap.cs
  31. 2
      src/Skia/Avalonia.Skia/StreamGeometryImpl.cs
  32. 2
      src/Skia/Avalonia.Skia/SurfaceRenderTarget.cs
  33. 2
      src/Skia/Avalonia.Skia/TransformedGeometryImpl.cs
  34. 2
      src/Skia/Avalonia.Skia/WriteableBitmapImpl.cs
  35. 3
      src/Windows/Avalonia.Direct2D1/Media/DrawingContextImpl.cs
  36. 2
      src/Windows/Avalonia.Direct2D1/Media/FormattedTextImpl.cs
  37. 1
      tests/Avalonia.ReactiveUI.UnitTests/AvaloniaActivationForViewFetcherTest.cs
  38. 1
      tests/Avalonia.ReactiveUI.UnitTests/RoutedViewHostTest.cs

8
nukebuild/Build.cs

@ -122,6 +122,14 @@ partial class Build : NukeBuild
foreach(var fw in frameworks)
{
if (fw.StartsWith("net4")
&& RuntimeInformation.IsOSPlatform(OSPlatform.Linux)
&& Environment.GetEnvironmentVariable("FORCE_LINUX_TESTS") != "1")
{
Information($"Skipping {fw} tests on Linux - https://github.com/mono/mono/issues/13969");
continue;
}
Information("Running for " + fw);
DotNetTest(c =>
{

1
samples/BindingDemo/App.xaml.cs

@ -3,6 +3,7 @@ using Avalonia;
using Avalonia.Controls;
using Avalonia.Logging.Serilog;
using Avalonia.Markup.Xaml;
using Avalonia.ReactiveUI;
using Serilog;
namespace BindingDemo

1
samples/ControlCatalog.Desktop/Program.cs

@ -4,6 +4,7 @@ using Avalonia;
using Avalonia.Controls;
using Avalonia.Logging.Serilog;
using Avalonia.Platform;
using Avalonia.ReactiveUI;
using Serilog;
namespace ControlCatalog

1
samples/ControlCatalog.NetCore/Program.cs

@ -4,6 +4,7 @@ using System.Linq;
using System.Threading;
using Avalonia;
using Avalonia.Skia;
using Avalonia.ReactiveUI;
namespace ControlCatalog.NetCore
{

1
samples/RenderDemo/App.xaml.cs

@ -4,6 +4,7 @@
using Avalonia;
using Avalonia.Logging.Serilog;
using Avalonia.Markup.Xaml;
using Avalonia.ReactiveUI;
namespace RenderDemo
{

3
samples/RenderDemo/MainWindow.xaml

@ -33,6 +33,9 @@
<TabItem Header="Drawing">
<pages:DrawingPage/>
</TabItem>
<TabItem Header="SkCanvas">
<pages:CustomSkiaPage/>
</TabItem>
</TabControl>
</DockPanel>
</Window>

119
samples/RenderDemo/Pages/CustomSkiaPage.cs

@ -0,0 +1,119 @@
using System;
using System.Diagnostics;
using Avalonia;
using Avalonia.Controls;
using Avalonia.Media;
using Avalonia.Platform;
using Avalonia.Rendering.SceneGraph;
using Avalonia.Skia;
using Avalonia.Threading;
using SkiaSharp;
namespace RenderDemo.Pages
{
public class CustomSkiaPage : Control
{
public CustomSkiaPage()
{
ClipToBounds = true;
}
class CustomDrawOp : ICustomDrawOperation
{
private readonly FormattedText _noSkia;
public CustomDrawOp(Rect bounds, FormattedText noSkia)
{
_noSkia = noSkia;
Bounds = bounds;
}
public void Dispose()
{
// No-op
}
public Rect Bounds { get; }
public bool HitTest(Point p) => false;
public bool Equals(ICustomDrawOperation other) => false;
static Stopwatch St = Stopwatch.StartNew();
public void Render(IDrawingContextImpl context)
{
var canvas = (context as ISkiaDrawingContextImpl)?.SkCanvas;
if (canvas == null)
context.DrawText(Brushes.Black, new Point(), _noSkia.PlatformImpl);
else
{
canvas.Save();
// create the first shader
var colors = new SKColor[] {
new SKColor(0, 255, 255),
new SKColor(255, 0, 255),
new SKColor(255, 255, 0),
new SKColor(0, 255, 255)
};
var sx = Animate(100, 2, 10);
var sy = Animate(1000, 5, 15);
var lightPosition = new SKPoint(
(float)(Bounds.Width / 2 + Math.Cos(St.Elapsed.TotalSeconds) * Bounds.Width / 4),
(float)(Bounds.Height / 2 + Math.Sin(St.Elapsed.TotalSeconds) * Bounds.Height / 4));
using (var sweep =
SKShader.CreateSweepGradient(new SKPoint((int)Bounds.Width / 2, (int)Bounds.Height / 2), colors,
null))
using(var turbulence = SKShader.CreatePerlinNoiseFractalNoise(0.05f, 0.05f, 4, 0))
using(var shader = SKShader.CreateCompose(sweep, turbulence, SKBlendMode.SrcATop))
using(var blur = SKImageFilter.CreateBlur(Animate(100, 2, 10), Animate(100, 5, 15)))
using (var paint = new SKPaint
{
Shader = shader,
ImageFilter = blur
})
canvas.DrawPaint(paint);
using (var pseudoLight = SKShader.CreateRadialGradient(
lightPosition,
(float) (Bounds.Width/3),
new [] {
new SKColor(255, 200, 200, 100),
SKColors.Transparent,
new SKColor(40,40,40, 220),
new SKColor(20,20,20, (byte)Animate(100, 200,220)) },
new float[] { 0.3f, 0.3f, 0.8f, 1 },
SKShaderTileMode.Clamp))
using (var paint = new SKPaint
{
Shader = pseudoLight
})
canvas.DrawPaint(paint);
canvas.Restore();
}
}
static int Animate(int d, int from, int to)
{
var ms = (int)(St.ElapsedMilliseconds / d);
var diff = to - from;
var range = diff * 2;
var v = ms % range;
if (v > diff)
v = range - v;
var rv = v + from;
if (rv < from || rv > to)
throw new Exception("WTF");
return rv;
}
}
public override void Render(DrawingContext context)
{
var noSkia = new FormattedText()
{
Text = "Current rendering API is not Skia"
};
context.Custom(new CustomDrawOp(new Rect(0, 0, Bounds.Width, Bounds.Height), noSkia));
Dispatcher.UIThread.InvokeAsync(InvalidateVisual, DispatcherPriority.Background);
}
}
}

1
samples/VirtualizationDemo/Program.cs

@ -5,6 +5,7 @@ using System;
using Avalonia;
using Avalonia.Controls;
using Avalonia.Logging.Serilog;
using Avalonia.ReactiveUI;
using Serilog;
namespace VirtualizationDemo

2
src/Avalonia.Base/Utilities/WeakEventHandlerManager.cs

@ -19,6 +19,7 @@ namespace Avalonia.Utilities
/// </summary>
/// <typeparam name="TTarget">The type of the target.</typeparam>
/// <typeparam name="TEventArgs">The type of the event arguments.</typeparam>
/// <typeparam name="TSubscriber">The type of the subscriber.</typeparam>
/// <param name="target">The event source.</param>
/// <param name="eventName">The name of the event.</param>
/// <param name="subscriber">The subscriber.</param>
@ -40,6 +41,7 @@ namespace Avalonia.Utilities
/// Unsubscribes from an event.
/// </summary>
/// <typeparam name="TEventArgs">The type of the event arguments.</typeparam>
/// <typeparam name="TSubscriber">The type of the subscriber.</typeparam>
/// <param name="target">The event source.</param>
/// <param name="eventName">The name of the event.</param>
/// <param name="subscriber">The subscriber.</param>

4
src/Avalonia.Controls/ListBox.cs

@ -30,13 +30,13 @@ namespace Avalonia.Controls
/// <summary>
/// Defines the <see cref="SelectedItems"/> property.
/// </summary>
public static readonly new AvaloniaProperty<IList> SelectedItemsProperty =
public static readonly new DirectProperty<SelectingItemsControl, IList> SelectedItemsProperty =
SelectingItemsControl.SelectedItemsProperty;
/// <summary>
/// Defines the <see cref="SelectionMode"/> property.
/// </summary>
public static readonly new AvaloniaProperty<SelectionMode> SelectionModeProperty =
public static readonly new StyledProperty<SelectionMode> SelectionModeProperty =
SelectingItemsControl.SelectionModeProperty;
/// <summary>

8
src/Avalonia.Controls/TreeView.cs

@ -40,17 +40,15 @@ namespace Avalonia.Controls
/// Defines the <see cref="SelectedItems"/> property.
/// </summary>
public static readonly DirectProperty<TreeView, IList> SelectedItemsProperty =
AvaloniaProperty.RegisterDirect<TreeView, IList>(
nameof(SelectedItems),
ListBox.SelectedItemsProperty.AddOwner<TreeView>(
o => o.SelectedItems,
(o, v) => o.SelectedItems = v);
/// <summary>
/// Defines the <see cref="SelectionMode"/> property.
/// </summary>
protected static readonly StyledProperty<SelectionMode> SelectionModeProperty =
AvaloniaProperty.Register<SelectingItemsControl, SelectionMode>(
nameof(SelectionMode));
public static readonly StyledProperty<SelectionMode> SelectionModeProperty =
ListBox.SelectionModeProperty.AddOwner<TreeView>();
private static readonly IList Empty = new object[0];
private object _selectedItem;

3
src/Avalonia.Controls/Window.cs

@ -291,7 +291,8 @@ namespace Avalonia.Controls
/// </summary>
/// <param name="dialogResult">The dialog result.</param>
/// <remarks>
/// When the window is shown with the <see cref="ShowDialog{TResult}"/> method, the
/// When the window is shown with the <see cref="ShowDialog{TResult}(IWindowImpl)"/>
/// or <see cref="ShowDialog{TResult}(Window)"/> method, the
/// resulting task will produce the <see cref="_dialogResult"/> value when the window
/// is closed.
/// </remarks>

7
src/Avalonia.ReactiveUI/AppBuilderExtensions.cs

@ -6,10 +6,15 @@ using Avalonia.Threading;
using ReactiveUI;
using Splat;
namespace Avalonia
namespace Avalonia.ReactiveUI
{
public static class AppBuilderExtensions
{
/// <summary>
/// Initializes ReactiveUI framework to use with Avalonia. Registers Avalonia
/// scheduler and Avalonia activation for view fetcher. Always remember to
/// call this method if you are using ReactiveUI in your application.
/// </summary>
public static TAppBuilder UseReactiveUI<TAppBuilder>(this TAppBuilder builder)
where TAppBuilder : AppBuilderBase<TAppBuilder>, new()
{

8
src/Avalonia.ReactiveUI/Attributes.cs

@ -0,0 +1,8 @@
// Copyright (c) The Avalonia Project. All rights reserved.
// Licensed under the MIT license. See licence.md file in the project root for full license information.
using System.Reflection;
using System.Runtime.CompilerServices;
using Avalonia.Metadata;
[assembly: XmlnsDefinition("http://reactiveui.net", "Avalonia.ReactiveUI")]

18
src/Avalonia.ReactiveUI/AvaloniaActivationForViewFetcher.cs

@ -9,15 +9,24 @@ using Avalonia.VisualTree;
using Avalonia.Controls;
using ReactiveUI;
namespace Avalonia
namespace Avalonia.ReactiveUI
{
/// <summary>
/// Determines when Avalonia IVisuals get activated.
/// </summary>
public class AvaloniaActivationForViewFetcher : IActivationForViewFetcher
{
/// <summary>
/// Returns affinity for view.
/// </summary>
public int GetAffinityForView(Type view)
{
return typeof(IVisual).GetTypeInfo().IsAssignableFrom(view.GetTypeInfo()) ? 10 : 0;
}
/// <summary>
/// Returns activation observable for activatable Avalonia view.
/// </summary>
public IObservable<bool> GetActivationForView(IActivatable view)
{
if (!(view is IVisual visual)) return Observable.Return(false);
@ -25,6 +34,9 @@ namespace Avalonia
return GetActivationForVisual(visual);
}
/// <summary>
/// Listens to Opened and Closed events for Avalonia windows.
/// </summary>
private IObservable<bool> GetActivationForWindowBase(WindowBase window)
{
var windowLoaded = Observable
@ -42,6 +54,10 @@ namespace Avalonia
.DistinctUntilChanged();
}
/// <summary>
/// Listens to AttachedToVisualTree and DetachedFromVisualTree
/// events for Avalonia IVisuals.
/// </summary>
private IObservable<bool> GetActivationForVisual(IVisual visual)
{
var visualLoaded = Observable

2
src/Avalonia.ReactiveUI/ReactiveUserControl.cs

@ -6,7 +6,7 @@ using Avalonia.VisualTree;
using Avalonia.Controls;
using ReactiveUI;
namespace Avalonia
namespace Avalonia.ReactiveUI
{
/// <summary>
/// A ReactiveUI UserControl that implements <see cref="IViewFor{TViewModel}"/>

2
src/Avalonia.ReactiveUI/ReactiveWindow.cs

@ -6,7 +6,7 @@ using Avalonia.VisualTree;
using Avalonia.Controls;
using ReactiveUI;
namespace Avalonia
namespace Avalonia.ReactiveUI
{
/// <summary>
/// A ReactiveUI Window that implements <see cref="IViewFor{TViewModel}"/>

8
src/Avalonia.ReactiveUI/RoutedViewHost.cs

@ -1,13 +1,17 @@
// Copyright (c) The Avalonia Project. All rights reserved.
// Licensed under the MIT license. See licence.md file in the project root for full license information.
using System;
using System.Reactive.Disposables;
using System.Reactive.Linq;
using Avalonia.Animation;
using Avalonia.Controls;
using Avalonia.Styling;
using Avalonia;
using ReactiveUI;
using Splat;
namespace Avalonia
namespace Avalonia.ReactiveUI
{
/// <summary>
/// This control hosts the View associated with ReactiveUI RoutingState,
@ -157,7 +161,7 @@ namespace Avalonia
return;
}
var viewLocator = ViewLocator ?? ReactiveUI.ViewLocator.Current;
var viewLocator = ViewLocator ?? global::ReactiveUI.ViewLocator.Current;
var view = viewLocator.ResolveView(viewModel);
if (view == null) throw new Exception($"Couldn't find view for '{viewModel}'. Is it registered?");

1
src/Avalonia.Styling/StyledElement.cs

@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Linq;
using System.Reactive.Linq;
using System.Reactive.Subjects;

7
src/Avalonia.Visuals/Media/DrawingContext.cs

@ -2,6 +2,7 @@ using System;
using System.Collections.Generic;
using Avalonia.Media.Imaging;
using Avalonia.Platform;
using Avalonia.Rendering.SceneGraph;
using Avalonia.Threading;
using Avalonia.Visuals.Media.Imaging;
@ -131,6 +132,12 @@ namespace Avalonia.Media
}
}
/// <summary>
/// Draws a custom drawing operation
/// </summary>
/// <param name="custom">custom operation</param>
public void Custom(ICustomDrawOperation custom) => PlatformImpl.Custom(custom);
/// <summary>
/// Draws text.
/// </summary>

7
src/Avalonia.Visuals/Platform/IDrawingContextImpl.cs

@ -3,6 +3,7 @@
using System;
using Avalonia.Media;
using Avalonia.Rendering.SceneGraph;
using Avalonia.Utilities;
using Avalonia.Visuals.Media.Imaging;
@ -139,5 +140,11 @@ namespace Avalonia.Platform
/// Pops the latest pushed geometry clip.
/// </summary>
void PopGeometryClip();
/// <summary>
/// Adds a custom draw operation
/// </summary>
/// <param name="custom">Custom draw operation</param>
void Custom(ICustomDrawOperation custom);
}
}

39
src/Avalonia.Visuals/Rendering/SceneGraph/CustomDrawOperation.cs

@ -0,0 +1,39 @@
using System;
using Avalonia.Media;
using Avalonia.Platform;
namespace Avalonia.Rendering.SceneGraph
{
internal sealed class CustomDrawOperation : DrawOperation
{
public Matrix Transform { get; }
public ICustomDrawOperation Custom { get; }
public CustomDrawOperation(ICustomDrawOperation custom, Matrix transform)
: base(custom.Bounds, transform, null)
{
Transform = transform;
Custom = custom;
}
public override bool HitTest(Point p)
{
return Custom.HitTest(p * Transform);
}
public override void Render(IDrawingContextImpl context)
{
context.Transform = Transform;
Custom.Render(context);
}
public override void Dispose() => Custom.Dispose();
public bool Equals(Matrix transform, ICustomDrawOperation custom) =>
Transform == transform && Custom?.Equals(custom) == true;
}
public interface ICustomDrawOperation : IDrawOperation, IEquatable<ICustomDrawOperation>
{
}
}

9
src/Avalonia.Visuals/Rendering/SceneGraph/DeferredDrawingContextImpl.cs

@ -165,6 +165,15 @@ namespace Avalonia.Rendering.SceneGraph
++_drawOperationindex;
}
}
public void Custom(ICustomDrawOperation custom)
{
var next = NextDrawAs<CustomDrawOperation>();
if (next == null || !next.Item.Equals(Transform, custom))
Add(new CustomDrawOperation(custom, Transform));
else
++_drawOperationindex;
}
/// <inheritdoc/>
public void DrawText(IBrush foreground, Point origin, IFormattedTextImpl text)

7
src/Skia/Avalonia.Skia/DrawingContextImpl.cs

@ -9,6 +9,7 @@ using System.Threading;
using Avalonia.Media;
using Avalonia.Platform;
using Avalonia.Rendering;
using Avalonia.Rendering.SceneGraph;
using Avalonia.Rendering.Utilities;
using Avalonia.Utilities;
using Avalonia.Visuals.Media.Imaging;
@ -19,7 +20,7 @@ namespace Avalonia.Skia
/// <summary>
/// Skia based drawing context.
/// </summary>
public class DrawingContextImpl : IDrawingContextImpl
internal class DrawingContextImpl : IDrawingContextImpl, ISkiaDrawingContextImpl
{
private IDisposable[] _disposables;
private readonly Vector _dpi;
@ -99,6 +100,8 @@ namespace Avalonia.Skia
/// </summary>
public SKCanvas Canvas { get; }
SKCanvas ISkiaDrawingContextImpl.SkCanvas => Canvas;
/// <inheritdoc />
public void Clear(Color color)
{
@ -296,6 +299,8 @@ namespace Avalonia.Skia
Canvas.Restore();
}
public void Custom(ICustomDrawOperation custom) => custom.Render(this);
/// <inheritdoc />
public void PushOpacityMask(IBrush mask, Rect bounds)
{

2
src/Skia/Avalonia.Skia/FormattedTextImpl.cs

@ -13,7 +13,7 @@ namespace Avalonia.Skia
/// <summary>
/// Skia formatted text implementation.
/// </summary>
public class FormattedTextImpl : IFormattedTextImpl
internal class FormattedTextImpl : IFormattedTextImpl
{
public FormattedTextImpl(
string text,

2
src/Skia/Avalonia.Skia/FramebufferRenderTarget.cs

@ -13,7 +13,7 @@ namespace Avalonia.Skia
/// <summary>
/// Skia render target that renders to a framebuffer surface. No gpu acceleration available.
/// </summary>
public class FramebufferRenderTarget : IRenderTarget
internal class FramebufferRenderTarget : IRenderTarget
{
private readonly IFramebufferPlatformSurface _platformSurface;
private SKImageInfo _currentImageInfo;

2
src/Skia/Avalonia.Skia/GeometryImpl.cs

@ -11,7 +11,7 @@ namespace Avalonia.Skia
/// <summary>
/// A Skia implementation of <see cref="IGeometryImpl"/>.
/// </summary>
public abstract class GeometryImpl : IGeometryImpl
internal abstract class GeometryImpl : IGeometryImpl
{
private PathCache _pathCache;

2
src/Skia/Avalonia.Skia/GlRenderTarget.cs

@ -8,7 +8,7 @@ using static Avalonia.OpenGL.GlConsts;
namespace Avalonia.Skia
{
public class GlRenderTarget : IRenderTarget
internal class GlRenderTarget : IRenderTarget
{
private readonly GRContext _grContext;
private IGlPlatformSurfaceRenderTarget _surface;

10
src/Skia/Avalonia.Skia/ISkiaDrawingContextImpl.cs

@ -0,0 +1,10 @@
using Avalonia.Platform;
using SkiaSharp;
namespace Avalonia.Skia
{
public interface ISkiaDrawingContextImpl : IDrawingContextImpl
{
SKCanvas SkCanvas { get; }
}
}

2
src/Skia/Avalonia.Skia/ImmutableBitmap.cs

@ -12,7 +12,7 @@ namespace Avalonia.Skia
/// <summary>
/// Immutable Skia bitmap.
/// </summary>
public class ImmutableBitmap : IDrawableBitmapImpl
internal class ImmutableBitmap : IDrawableBitmapImpl
{
private readonly SKImage _image;

2
src/Skia/Avalonia.Skia/StreamGeometryImpl.cs

@ -10,7 +10,7 @@ namespace Avalonia.Skia
/// <summary>
/// A Skia implementation of a <see cref="IStreamGeometryImpl"/>.
/// </summary>
public class StreamGeometryImpl : GeometryImpl, IStreamGeometryImpl
internal class StreamGeometryImpl : GeometryImpl, IStreamGeometryImpl
{
private Rect _bounds;
private readonly SKPath _effectivePath;

2
src/Skia/Avalonia.Skia/SurfaceRenderTarget.cs

@ -14,7 +14,7 @@ namespace Avalonia.Skia
/// <summary>
/// Skia render target that writes to a surface.
/// </summary>
public class SurfaceRenderTarget : IRenderTargetBitmapImpl, IDrawableBitmapImpl
internal class SurfaceRenderTarget : IRenderTargetBitmapImpl, IDrawableBitmapImpl
{
private readonly SKSurface _surface;
private readonly SKCanvas _canvas;

2
src/Skia/Avalonia.Skia/TransformedGeometryImpl.cs

@ -9,7 +9,7 @@ namespace Avalonia.Skia
/// <summary>
/// A Skia implementation of a <see cref="ITransformedGeometryImpl"/>.
/// </summary>
public class TransformedGeometryImpl : GeometryImpl, ITransformedGeometryImpl
internal class TransformedGeometryImpl : GeometryImpl, ITransformedGeometryImpl
{
/// <summary>
/// Initializes a new instance of the <see cref="TransformedGeometryImpl"/> class.

2
src/Skia/Avalonia.Skia/WriteableBitmapImpl.cs

@ -13,7 +13,7 @@ namespace Avalonia.Skia
/// <summary>
/// Skia based writeable bitmap.
/// </summary>
public class WriteableBitmapImpl : IWriteableBitmapImpl, IDrawableBitmapImpl
internal class WriteableBitmapImpl : IWriteableBitmapImpl, IDrawableBitmapImpl
{
private static readonly SKBitmapReleaseDelegate s_releaseDelegate = ReleaseProc;
private readonly SKBitmap _bitmap;

3
src/Windows/Avalonia.Direct2D1/Media/DrawingContextImpl.cs

@ -6,6 +6,7 @@ using System.Collections.Generic;
using Avalonia.Media;
using Avalonia.Platform;
using Avalonia.Rendering;
using Avalonia.Rendering.SceneGraph;
using Avalonia.Utilities;
using SharpDX;
using SharpDX.Direct2D1;
@ -508,5 +509,7 @@ namespace Avalonia.Direct2D1.Media
{
PopLayer();
}
public void Custom(ICustomDrawOperation custom) => custom.Render(this);
}
}

2
src/Windows/Avalonia.Direct2D1/Media/FormattedTextImpl.cs

@ -9,7 +9,7 @@ using DWrite = SharpDX.DirectWrite;
namespace Avalonia.Direct2D1.Media
{
public class FormattedTextImpl : IFormattedTextImpl
internal class FormattedTextImpl : IFormattedTextImpl
{
public FormattedTextImpl(
string text,

1
tests/Avalonia.ReactiveUI.UnitTests/AvaloniaActivationForViewFetcherTest.cs

@ -11,6 +11,7 @@ using DynamicData;
using Xunit;
using Splat;
using Avalonia.Markup.Xaml;
using Avalonia.ReactiveUI;
namespace Avalonia
{

1
tests/Avalonia.ReactiveUI.UnitTests/RoutedViewHostTest.cs

@ -14,6 +14,7 @@ using Avalonia.Markup.Xaml;
using System.ComponentModel;
using System.Threading.Tasks;
using System.Reactive;
using Avalonia.ReactiveUI;
namespace Avalonia
{

Loading…
Cancel
Save