Explorar o código

Changed namespaces

flabbet %!s(int64=6) %!d(string=hai) anos
pai
achega
1be4cb05a2
Modificáronse 27 ficheiros con 63 adicións e 31 borrados
  1. 1 1
      PixiEditorDotNetCore3/Models/BasicLayer.cs
  2. 1 1
      PixiEditorDotNetCore3/Models/BitmapConverter.cs
  3. 1 1
      PixiEditorDotNetCore3/Models/Change.cs
  4. 1 1
      PixiEditorDotNetCore3/Models/Coordinates.cs
  5. 1 1
      PixiEditorDotNetCore3/Models/CustomDialog.cs
  6. 1 1
      PixiEditorDotNetCore3/Models/DCords.cs
  7. 1 1
      PixiEditorDotNetCore3/Models/Enums/FileType.cs
  8. 1 1
      PixiEditorDotNetCore3/Models/ExColor.cs
  9. 1 1
      PixiEditorDotNetCore3/Models/ExportFileDialog.cs
  10. 2 2
      PixiEditorDotNetCore3/Models/Exporter.cs
  11. 1 1
      PixiEditorDotNetCore3/Models/ImageGenerator.cs
  12. 1 1
      PixiEditorDotNetCore3/Models/ImportFileDialog.cs
  13. 1 1
      PixiEditorDotNetCore3/Models/Importer.cs
  14. 1 1
      PixiEditorDotNetCore3/Models/Layer.cs
  15. 2 2
      PixiEditorDotNetCore3/Models/LayerGenerator.cs
  16. 1 1
      PixiEditorDotNetCore3/Models/LightLayer.cs
  17. 1 1
      PixiEditorDotNetCore3/Models/MousePositionConverter.cs
  18. 1 1
      PixiEditorDotNetCore3/Models/NewFileDialog.cs
  19. 1 1
      PixiEditorDotNetCore3/Models/StackEx.cs
  20. 1 1
      PixiEditorDotNetCore3/Models/ToolManager.cs
  21. 1 1
      PixiEditorDotNetCore3/Models/Tools/ToolSet.cs
  22. 1 1
      PixiEditorDotNetCore3/Models/Tools/ToolType.cs
  23. 1 3
      PixiEditorDotNetCore3/Models/UndoManager.cs
  24. 6 0
      PixiEditorDotNetCore3/PixiEditorDotNetCore3.sln
  25. 2 3
      PixiEditorDotNetCore3/ViewModels/ViewModelMain.cs
  26. 1 1
      PixiEditorDotNetCore3/Views/MainDrawingPanel.xaml.cs
  27. 29 0
      PixiEditorTests/PixiEditorTests.csproj

+ 1 - 1
PixiEditorDotNetCore3/Models/BasicLayer.cs

@@ -6,7 +6,7 @@ using System.Threading.Tasks;
 using System.Windows.Controls;
 using PixiEditor.Helpers;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     [Serializable]
     public class BasicLayer : NotifyableObject

+ 1 - 1
PixiEditorDotNetCore3/Models/BitmapConverter.cs

@@ -8,7 +8,7 @@ using System.Threading.Tasks;
 using System.Windows.Media;
 using System.Windows.Media.Imaging;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public static class BitmapConverter
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/Change.cs

@@ -6,7 +6,7 @@ using System.Text;
 using System.Threading.Tasks;
 using PixiEditorDotNetCore3.Models;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     [Serializable]
     public class Change

+ 1 - 1
PixiEditorDotNetCore3/Models/Coordinates.cs

@@ -4,7 +4,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class Coordinates
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/CustomDialog.cs

@@ -7,7 +7,7 @@ using System.Text;
 using System.Threading.Tasks;
 using System.Windows;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public abstract class CustomDialog : NotifyableObject
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/DCords.cs

@@ -4,7 +4,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class DCords
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/Enums/FileType.cs

@@ -4,7 +4,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models.Enums
+namespace PixiEditorDotNetCore3.Models.Enums
 {
     public enum FileType
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/ExColor.cs

@@ -5,7 +5,7 @@ using System.Text;
 using System.Threading.Tasks;
 using System.Windows.Media;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class ExColor
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/ExportFileDialog.cs

@@ -7,7 +7,7 @@ using System.Text;
 using System.Threading.Tasks;
 using System.Windows;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class ExportFileDialog : CustomDialog
     {

+ 2 - 2
PixiEditorDotNetCore3/Models/Exporter.cs

@@ -10,9 +10,9 @@ using System.Windows.Controls;
 using System.Windows.Media;
 using System.Windows.Media.Imaging;
 using Microsoft.Win32;
-using PixiEditor.Models.Enums;
+using PixiEditorDotNetCore3.Models.Enums;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class Exporter
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/ImageGenerator.cs

@@ -6,7 +6,7 @@ using System.Threading.Tasks;
 using System.Windows.Controls;
 using System.Windows.Media;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public static class ImageGenerator
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/ImportFileDialog.cs

@@ -6,7 +6,7 @@ using System.Text;
 using System.Threading.Tasks;
 using System.Windows;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     class ImportFileDialog : CustomDialog
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/Importer.cs

@@ -7,7 +7,7 @@ using System.Threading.Tasks;
 using System.Windows.Media.Imaging;
 using System.Windows.Media;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class Importer : NotifyableObject
     { 

+ 1 - 1
PixiEditorDotNetCore3/Models/Layer.cs

@@ -11,7 +11,7 @@ using System.Windows.Controls;
 using System.Windows.Media;
 using System.Windows.Media.Imaging;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class Layer : BasicLayer
     {

+ 2 - 2
PixiEditorDotNetCore3/Models/LayerGenerator.cs

@@ -1,4 +1,4 @@
-using PixiEditor.Models.Tools;
+using PixiEditorDotNetCore3.Models.Tools;
 using System;
 using System.Collections.Generic;
 using System.ComponentModel;
@@ -10,7 +10,7 @@ using System.Windows.Controls;
 using System.Windows.Media;
 using System.Windows.Media.Imaging;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public static class LayerGenerator 
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/LightLayer.cs

@@ -8,7 +8,7 @@ using Newtonsoft.Json;
 using Newtonsoft.Json.Linq;
 using PixiEditor.Helpers;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     [Serializable]
     public class LightLayer : BasicLayer

+ 1 - 1
PixiEditorDotNetCore3/Models/MousePositionConverter.cs

@@ -7,7 +7,7 @@ using System.Threading.Tasks;
 using System.Windows;
 using System.Windows.Input;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public static class MousePositionConverter
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/NewFileDialog.cs

@@ -7,7 +7,7 @@ using System.Text;
 using System.Threading.Tasks;
 using System.Windows;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class NewFileDialog : CustomDialog
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/StackEx.cs

@@ -4,7 +4,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public class StackEx<T>
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/ToolManager.cs

@@ -6,7 +6,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models.Tools
+namespace PixiEditorDotNetCore3.Models.Tools
 {
     class ToolManager : NotifyableObject
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/Tools/ToolSet.cs

@@ -11,7 +11,7 @@ using System.Windows.Controls;
 using System.Windows.Input;
 using System.Windows.Media.Imaging;
 
-namespace PixiEditor.Models.Tools
+namespace PixiEditorDotNetCore3.Models.Tools
 {
     public class ToolSet
     {

+ 1 - 1
PixiEditorDotNetCore3/Models/Tools/ToolType.cs

@@ -4,7 +4,7 @@ using System.Linq;
 using System.Text;
 using System.Threading.Tasks;
 
-namespace PixiEditor.Models.Tools
+namespace PixiEditorDotNetCore3.Models.Tools
 {
     public enum ToolType
     {

+ 1 - 3
PixiEditorDotNetCore3/Models/UndoManager.cs

@@ -13,14 +13,12 @@ using System.Threading.Tasks;
 using System.Windows;
 using System.Windows.Media;
 
-namespace PixiEditor.Models
+namespace PixiEditorDotNetCore3.Models
 {
     public static class UndoManager
     {
         private const int MaximumChangesInRam = 1;
 
-        private static int _undosSavedOnDisk = 0;
-        private static int _redosSavedOnDisk = 0;
         public static StackEx<Change> UndoStack { get; set; } = new StackEx<Change>(); 
         public static StackEx<Change> RedoStack { get; set; } = new StackEx<Change>();
         private static bool _stopRecording = false; 

+ 6 - 0
PixiEditorDotNetCore3/PixiEditorDotNetCore3.sln

@@ -5,6 +5,8 @@ VisualStudioVersion = 16.0.28729.10
 MinimumVisualStudioVersion = 10.0.40219.1
 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PixiEditorDotNetCore3", "PixiEditorDotNetCore3.csproj", "{B17A8190-059F-4FDD-A1B5-4F63D866778F}"
 EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PixiEditorTests", "..\PixiEditorTests\PixiEditorTests.csproj", "{D61922EA-3BF3-4AFA-8930-3A8B30A9A195}"
+EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Debug|Any CPU = Debug|Any CPU
@@ -15,6 +17,10 @@ Global
 		{B17A8190-059F-4FDD-A1B5-4F63D866778F}.Debug|Any CPU.Build.0 = Debug|Any CPU
 		{B17A8190-059F-4FDD-A1B5-4F63D866778F}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{B17A8190-059F-4FDD-A1B5-4F63D866778F}.Release|Any CPU.Build.0 = Release|Any CPU
+		{D61922EA-3BF3-4AFA-8930-3A8B30A9A195}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{D61922EA-3BF3-4AFA-8930-3A8B30A9A195}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{D61922EA-3BF3-4AFA-8930-3A8B30A9A195}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{D61922EA-3BF3-4AFA-8930-3A8B30A9A195}.Release|Any CPU.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE

+ 2 - 3
PixiEditorDotNetCore3/ViewModels/ViewModelMain.cs

@@ -1,8 +1,7 @@
 using Microsoft.Win32;
 using PixiEditor.Helpers;
-using PixiEditor.Models;
-using PixiEditor.Models.Enums;
-using PixiEditor.Models.Tools;
+using PixiEditorDotNetCore3.Models.Enums;
+using PixiEditorDotNetCore3.Models.Tools;
 using PixiEditor.Views;
 using PixiEditorDotNetCore3.Models;
 using System;

+ 1 - 1
PixiEditorDotNetCore3/Views/MainDrawingPanel.xaml.cs

@@ -1,4 +1,4 @@
-using PixiEditor.Models;
+using PixiEditorDotNetCore3.Models;
 using System;
 using System.Collections.Generic;
 using System.Diagnostics;

+ 29 - 0
PixiEditorTests/PixiEditorTests.csproj

@@ -0,0 +1,29 @@
+<Project Sdk="Microsoft.NET.Sdk">
+
+  <PropertyGroup>
+    <TargetFramework>netcoreapp3.0</TargetFramework>
+
+    <IsPackable>false</IsPackable>
+  </PropertyGroup>
+
+  <ItemGroup>
+    <PackageReference Include="nunit" Version="3.11.0" />
+    <PackageReference Include="NUnit3TestAdapter" Version="3.13.0" />
+    <PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.9.0" />
+  </ItemGroup>
+
+  <ItemGroup>
+    <Folder Include="ToolsTests\" />
+  </ItemGroup>
+
+  <ItemGroup>
+    <ProjectReference Include="..\PixiEditorDotNetCore3\PixiEditorDotNetCore3.csproj" />
+  </ItemGroup>
+
+  <ItemGroup>
+    <Reference Include="PresentationCore">
+      <HintPath>C:\Program Files\Reference Assemblies\Microsoft\Framework\v3.0\PresentationCore.dll</HintPath>
+    </Reference>
+  </ItemGroup>
+
+</Project>