Refactored projects
This commit is contained in:
Родитель
223f0963cf
Коммит
aa3bc9603f
|
@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
|
|||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 16.0.28315.86
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WpfDemo", "samples\WpfDemo\WpfDemo.csproj", "{B2B6562E-FFCA-4571-A59C-359A45A07FF0}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WpfDemo", "samples\WpfDemo\WpfDemo.csproj", "{B2B6562E-FFCA-4571-A59C-359A45A07FF0}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AvaloniaDemo", "samples\AvaloniaDemo\AvaloniaDemo.csproj", "{6DB965C2-20A9-4A0A-9A1B-A76A6AC90903}"
|
||||
EndProject
|
||||
|
@ -67,6 +67,14 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Avalonia.Controls.ViewBox.U
|
|||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Wpf.Controls.PanAndZoom.UnitTests", "tests\Wpf.Controls.PanAndZoom.UnitTests\Wpf.Controls.PanAndZoom.UnitTests.csproj", "{45944D09-9DDB-4BD4-8C02-00CBFDAF0494}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Avalonia.MatrixExtensions", "src\Avalonia.MatrixExtensions\Avalonia.MatrixExtensions.csproj", "{1ACD087B-A5B5-4445-835B-FB4CA56568EB}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Avalonia.MatrixExtensions.UnitTests", "tests\Avalonia.MatrixExtensions.UnitTests\Avalonia.MatrixExtensions.UnitTests.csproj", "{246FF211-1311-43E6-A215-8B90CE826F89}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Wpf.MatrixExtensions", "src\Wpf.MatrixExtensions\Wpf.MatrixExtensions.csproj", "{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Wpf.MatrixExtensions.UnitTests", "tests\Wpf.MatrixExtensions.UnitTests\Wpf.MatrixExtensions.UnitTests.csproj", "{2240D6E0-2283-4DE6-A039-120CB36D827D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
|
@ -117,6 +125,22 @@ Global
|
|||
{45944D09-9DDB-4BD4-8C02-00CBFDAF0494}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{45944D09-9DDB-4BD4-8C02-00CBFDAF0494}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{45944D09-9DDB-4BD4-8C02-00CBFDAF0494}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{1ACD087B-A5B5-4445-835B-FB4CA56568EB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{1ACD087B-A5B5-4445-835B-FB4CA56568EB}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{1ACD087B-A5B5-4445-835B-FB4CA56568EB}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{1ACD087B-A5B5-4445-835B-FB4CA56568EB}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{246FF211-1311-43E6-A215-8B90CE826F89}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{246FF211-1311-43E6-A215-8B90CE826F89}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{246FF211-1311-43E6-A215-8B90CE826F89}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{246FF211-1311-43E6-A215-8B90CE826F89}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{2240D6E0-2283-4DE6-A039-120CB36D827D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{2240D6E0-2283-4DE6-A039-120CB36D827D}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{2240D6E0-2283-4DE6-A039-120CB36D827D}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{2240D6E0-2283-4DE6-A039-120CB36D827D}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
@ -136,6 +160,10 @@ Global
|
|||
{5436C290-E80A-4323-BA66-8E5997F464A9} = {053504B1-A08C-4617-BB5E-F81935A7A00A}
|
||||
{5E315089-C232-4696-AEE5-06D4FE95A25E} = {053504B1-A08C-4617-BB5E-F81935A7A00A}
|
||||
{45944D09-9DDB-4BD4-8C02-00CBFDAF0494} = {053504B1-A08C-4617-BB5E-F81935A7A00A}
|
||||
{1ACD087B-A5B5-4445-835B-FB4CA56568EB} = {3FBE9035-8FFD-447D-949A-8E63AF15B89A}
|
||||
{246FF211-1311-43E6-A215-8B90CE826F89} = {053504B1-A08C-4617-BB5E-F81935A7A00A}
|
||||
{6FD7CCDE-9929-4665-8CBA-F2A5B76AD843} = {3FBE9035-8FFD-447D-949A-8E63AF15B89A}
|
||||
{2240D6E0-2283-4DE6-A039-120CB36D827D} = {053504B1-A08C-4617-BB5E-F81935A7A00A}
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {81CAD068-E34F-49E9-A78D-B455F3CF2EAC}
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\Avalonia.Controls.ViewBox\Avalonia.Controls.ViewBox.csproj" />
|
||||
<ProjectReference Include="..\..\src\Avalonia.MatrixExtensions\Avalonia.MatrixExtensions.csproj" />
|
||||
<ProjectReference Include="..\..\src\PanAndZoom\PanAndZoom.csproj" />
|
||||
<ProjectReference Include="..\..\src\Avalonia.Controls.PanAndZoom\Avalonia.Controls.PanAndZoom.csproj" />
|
||||
</ItemGroup>
|
||||
|
|
|
@ -15,18 +15,7 @@
|
|||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\PanAndZoom\PanAndZoom.csproj" />
|
||||
<ProjectReference Include="..\..\src\Wpf.Controls.PanAndZoom\Wpf.Controls.PanAndZoom.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="App.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Page Update="MainWindow.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<ProjectReference Include="..\..\src\Wpf.MatrixExtensions\Wpf.MatrixExtensions.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Avalonia.MatrixExtensions\Avalonia.MatrixExtensions.csproj" />
|
||||
<ProjectReference Include="..\PanAndZoom\PanAndZoom.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using Avalonia.Data;
|
||||
using Avalonia.Input;
|
||||
using Avalonia.MatrixExtensions;
|
||||
using Avalonia.Media;
|
||||
using static System.Math;
|
||||
using PanAndZoom;
|
||||
using System.Diagnostics;
|
||||
using static System.Math;
|
||||
|
||||
namespace Avalonia.Controls.PanAndZoom
|
||||
{
|
||||
|
@ -297,7 +298,7 @@ namespace Avalonia.Controls.PanAndZoom
|
|||
private void Defaults()
|
||||
{
|
||||
_isPanning = false;
|
||||
_matrix = MatrixHelper.Identity;
|
||||
_matrix = Matrix.Identity;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -554,7 +555,7 @@ namespace Avalonia.Controls.PanAndZoom
|
|||
zoom = Max(zx, zy);
|
||||
return MatrixHelper.ScaleAt(zoom, zoom, cx, cy);
|
||||
}
|
||||
return MatrixHelper.Identity;
|
||||
return Matrix.Identity;
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
|
@ -635,7 +636,7 @@ namespace Avalonia.Controls.PanAndZoom
|
|||
/// <inheritdoc/>
|
||||
public void Reset()
|
||||
{
|
||||
_matrix = MatrixHelper.Identity;
|
||||
_matrix = Matrix.Identity;
|
||||
Invalidate();
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>netstandard2.0</TargetFrameworks>
|
||||
<OutputType>Library</OutputType>
|
||||
<EnableDefaultCompileItems>False</EnableDefaultCompileItems>
|
||||
<GeneratePackageOnBuild>False</GeneratePackageOnBuild>
|
||||
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\$(AssemblyName).xml</DocumentationFile>
|
||||
<LangVersion>latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<Description>Avalonia matrix extensions.</Description>
|
||||
<PackageTags>Avalonia;Matrix;Translate;TranslatePrepend;Scale;ScaleAt;ScaleAtPrepend;Skew;Rotation;TransformPoint;Managed;C#"</PackageTags>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="..\..\build\Base.props" />
|
||||
<Import Project="..\..\build\Rx.props" />
|
||||
<Import Project="..\..\build\Avalonia.props" />
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="**\*.cs" Exclude="obj\**" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
|
@ -3,19 +3,13 @@
|
|||
using Avalonia;
|
||||
using static System.Math;
|
||||
|
||||
namespace Avalonia.Controls.PanAndZoom
|
||||
namespace Avalonia.MatrixExtensions
|
||||
{
|
||||
/// <summary>
|
||||
/// Avalonia Matrix helper methods.
|
||||
/// </summary>
|
||||
public static class MatrixHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the identity matrix.
|
||||
/// </summary>
|
||||
/// <value>The identity matrix.</value>
|
||||
public static readonly Matrix Identity = new Matrix(1.0, 0.0, 0.0, 1.0, 0.0, 0.0);
|
||||
|
||||
/// <summary>
|
||||
/// Creates a translation matrix using the specified offsets.
|
||||
/// </summary>
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\PanAndZoom\PanAndZoom.csproj" />
|
||||
<ProjectReference Include="..\Wpf.MatrixExtensions\Wpf.MatrixExtensions.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Media;
|
||||
using static System.Math;
|
||||
using PanAndZoom;
|
||||
using System.Diagnostics;
|
||||
using Wpf.MatrixExtensions;
|
||||
using static System.Math;
|
||||
|
||||
namespace Wpf.Controls.PanAndZoom
|
||||
{
|
||||
|
@ -349,7 +350,7 @@ namespace Wpf.Controls.PanAndZoom
|
|||
private void Defaults()
|
||||
{
|
||||
_isPanning = false;
|
||||
_matrix = MatrixHelper.Identity;
|
||||
_matrix = Matrix.Identity;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -641,7 +642,7 @@ namespace Wpf.Controls.PanAndZoom
|
|||
}
|
||||
}
|
||||
}
|
||||
return MatrixHelper.Identity;
|
||||
return Matrix.Identity;
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
|
@ -722,7 +723,7 @@ namespace Wpf.Controls.PanAndZoom
|
|||
/// <inheritdoc/>
|
||||
public void Reset()
|
||||
{
|
||||
_matrix = MatrixHelper.Identity;
|
||||
_matrix = Matrix.Identity;
|
||||
Invalidate();
|
||||
}
|
||||
|
||||
|
|
|
@ -4,19 +4,13 @@ using System.Windows;
|
|||
using System.Windows.Media;
|
||||
using static System.Math;
|
||||
|
||||
namespace Wpf.Controls.PanAndZoom
|
||||
namespace Wpf.MatrixExtensions
|
||||
{
|
||||
/// <summary>
|
||||
/// WPF Matrix helper methods.
|
||||
/// </summary>
|
||||
public static class MatrixHelper
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the identity matrix.
|
||||
/// </summary>
|
||||
/// <value>The identity matrix.</value>
|
||||
public static readonly Matrix Identity = new Matrix(1.0, 0.0, 0.0, 1.0, 0.0, 0.0);
|
||||
|
||||
/// <summary>
|
||||
/// Creates a translation matrix using the specified offsets.
|
||||
/// </summary>
|
|
@ -0,0 +1,24 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net452;net461;netcoreapp3.0</TargetFrameworks>
|
||||
<OutputType>Library</OutputType>
|
||||
<UseWPF>True</UseWPF>
|
||||
<EnableDefaultCompileItems>False</EnableDefaultCompileItems>
|
||||
<GeneratePackageOnBuild>False</GeneratePackageOnBuild>
|
||||
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\$(AssemblyName).xml</DocumentationFile>
|
||||
<LangVersion>latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<Description>WPF matrix extensions.</Description>
|
||||
<PackageTags>WPF;Matrix;Translate;TranslatePrepend;Scale;ScaleAt;ScaleAtPrepend;Skew;Rotation;TransformPoint;Managed;C#"</PackageTags>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="..\..\build\Base.props" />
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="**\*.cs" Exclude="obj\**" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace Avalonia.Controls.PanAndZoom.UnitTests
|
||||
{
|
||||
public class ZoomBorderTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace Avalonia.Controls.ViewBox.UnitTests
|
||||
{
|
||||
public class ViewBoxTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||
<OutputType>Library</OutputType>
|
||||
<LangVersion>latest</LangVersion>
|
||||
<IsPackable>False</IsPackable>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="..\..\build\XUnit.props" />
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\Avalonia.MatrixExtensions\Avalonia.MatrixExtensions.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace Avalonia.MatrixExtensions.UnitTests
|
||||
{
|
||||
public class MatrixHelperTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace PanAndZoom.UnitTests
|
||||
{
|
||||
public class IPanAndZoomTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -12,6 +12,7 @@
|
|||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\PanAndZoom\PanAndZoom.csproj" />
|
||||
<ProjectReference Include="..\..\src\Wpf.Controls.PanAndZoom\Wpf.Controls.PanAndZoom.csproj" />
|
||||
<ProjectReference Include="..\..\src\Wpf.MatrixExtensions\Wpf.MatrixExtensions.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace Wpf.Controls.PanAndZoom.UnitTests
|
||||
{
|
||||
public class ZoomBorderTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Wiesław Šoltés. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
using System;
|
||||
using Xunit;
|
||||
|
||||
namespace Wpf.MatrixExtensions.UnitTests
|
||||
{
|
||||
public class MatrixHelperTests
|
||||
{
|
||||
[Fact]
|
||||
public void Stub()
|
||||
{
|
||||
Assert.True(true);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net452;net461;netcoreapp3.0</TargetFrameworks>
|
||||
<OutputType>Library</OutputType>
|
||||
<LangVersion>latest</LangVersion>
|
||||
<IsPackable>False</IsPackable>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="..\..\build\XUnit.props" />
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\Wpf.MatrixExtensions\Wpf.MatrixExtensions.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
Загрузка…
Ссылка в новой задаче