From ac783b142d537bb56d078518cae314f05c307dfa Mon Sep 17 00:00:00 2001 From: Daniel Date: Sat, 21 Oct 2017 19:42:47 +0200 Subject: [PATCH 01/13] Test --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ab3c71a..17341cf 100644 --- a/README.md +++ b/README.md @@ -1 +1,3 @@ -# SweetUtils \ No newline at end of file +# SweetUtils + +Awesome :) From 7e01e9a98947e56bcafcf0dddef94591251db4e2 Mon Sep 17 00:00:00 2001 From: Daniel Date: Sat, 21 Oct 2017 19:44:13 +0200 Subject: [PATCH 02/13] Another test commit --- README.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/README.md b/README.md index 17341cf..782dd30 100644 --- a/README.md +++ b/README.md @@ -1,3 +1 @@ # SweetUtils - -Awesome :) From 6df24a614fd5add567947c860bfa8ead20d82b56 Mon Sep 17 00:00:00 2001 From: Serraniel Date: Thu, 26 Oct 2017 18:27:37 +0200 Subject: [PATCH 03/13] Renamed old project --- .../SweetLib.Demo.Console.csproj | 6 ------ SweetLib.Demo/SweetLib.Demo.csproj | 6 ------ .../Exception/RegistryStorerException.cs | 0 .../Classes/Storer/IStorer.cs | 0 .../Classes/Storer/IniFileStorer.cs | 0 .../Classes/Storer/RegistryStorer.cs | 0 .../Properties/AssemblyInfo.cs | 0 .../SweetLib.Old.csproj | 0 {SweetLib => SweetLib.Old}/SweetLib.nuspec | 0 .../Utils/Logger/Logger.cs | 0 .../Memory/ArchivableConsoleLogMemory.cs | 0 .../Utils/Logger/Memory/ILogMemory.cs | 0 .../Utils/Logger/Message/LogMessage.cs | 0 .../Logger/Message/LogMessageFormatter.cs | 0 .../Utils/SweetUtils.cs | 0 .../Utils/TaskBar/TaskBarProgress.cs | 0 {SweetLib => SweetLib.Old}/build-nuget.bat | 0 SweetLib.sln | 19 +++++++++++-------- 18 files changed, 11 insertions(+), 20 deletions(-) rename {SweetLib => SweetLib.Old}/Classes/Exception/RegistryStorerException.cs (100%) rename {SweetLib => SweetLib.Old}/Classes/Storer/IStorer.cs (100%) rename {SweetLib => SweetLib.Old}/Classes/Storer/IniFileStorer.cs (100%) rename {SweetLib => SweetLib.Old}/Classes/Storer/RegistryStorer.cs (100%) rename {SweetLib => SweetLib.Old}/Properties/AssemblyInfo.cs (100%) rename SweetLib/SweetLib.csproj => SweetLib.Old/SweetLib.Old.csproj (100%) rename {SweetLib => SweetLib.Old}/SweetLib.nuspec (100%) rename {SweetLib => SweetLib.Old}/Utils/Logger/Logger.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/Logger/Memory/ArchivableConsoleLogMemory.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/Logger/Memory/ILogMemory.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/Logger/Message/LogMessage.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/Logger/Message/LogMessageFormatter.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/SweetUtils.cs (100%) rename {SweetLib => SweetLib.Old}/Utils/TaskBar/TaskBarProgress.cs (100%) rename {SweetLib => SweetLib.Old}/build-nuget.bat (100%) diff --git a/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj b/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj index 9bc892b..4a7e6f1 100644 --- a/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj +++ b/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj @@ -49,12 +49,6 @@ - - - {02c1f8ef-32f2-4e77-a36d-79129402af37} - SweetLib - - - \ No newline at end of file diff --git a/SweetLib.Old/SweetLib.nuspec b/SweetLib.Old/SweetLib.nuspec deleted file mode 100644 index 60041e9..0000000 --- a/SweetLib.Old/SweetLib.nuspec +++ /dev/null @@ -1,18 +0,0 @@ - - - - $id$ - $version$-alpha - $title$ - Serraniel - $author$ - https://opensource.org/licenses/GPL-3.0 - https://github.com/Serraniel/SweetLib - https://github.com/Serraniel/SweetLib/blob/develop/nuget_icon.png?raw=true - true - $description$ - First pre version just to try that nuget package thing :) - Copyright © 2017 Serraniel - Utility - - \ No newline at end of file diff --git a/SweetLib.Old/Utils/Logger/Logger.cs b/SweetLib.Old/Utils/Logger/Logger.cs deleted file mode 100644 index daa682d..0000000 --- a/SweetLib.Old/Utils/Logger/Logger.cs +++ /dev/null @@ -1,128 +0,0 @@ -using System; -using SweetLib.Utils.Logger.Memory; -using SweetLib.Utils.Logger.Message; - -namespace SweetLib.Utils.Logger -{ - /// - /// Enum which contains the several log levels. - /// - [Flags] - public enum LogLevel - { - None = 0, - Trace = 1 << 0, - Debug = 1 << 1, - Info = 1 << 2, - Warn = 1 << 3, - Error = 1 << 4, - - All = Int32.MaxValue, - }; - - /// - /// Global logger class providing several methods to log events by the application. - /// - /// - /// As a will be used. You can change this to any other implementation at any time while runtime. - /// Default log levels are set as bitflags in . - /// - public static class Logger - { - /// - /// The global log level. Only messages with the set will be procedered. - /// - public static LogLevel GlobalLogLevel { get; set; } = LogLevel.Info | LogLevel.Warn | LogLevel.Error; - - /// - /// The default which will be used for any logging action, if no custom is set as parameter. - /// - public static ILogMemory DefaultLogMemory = new ArchivableConsoleLogMemory(); - - /// - /// Will log a message into the global . - /// - /// The log level of this message. - /// The message to log. - public static void Log(LogLevel logLevel, string message) - { - Log(logLevel, message, DefaultLogMemory); - } - - /// - /// Will log a message into the provided . - /// - /// The log level of this message. - /// /// The message to log. - /// The to store the into. - public static void Log(LogLevel logLevel, string message, ILogMemory logMemory) - { - Log(new LogMessage(logLevel, message), logMemory); - } - - /// - /// Will log a message into the provided . - /// - /// A object to store. - /// The to store the into. - /// In general use cases you should either use one of the or methods which will generate a call to this method. - public static void Log(LogMessage message, ILogMemory logMemory) - { - if (message == null) - throw new ArgumentNullException(nameof(message)); - - if (logMemory == null) - throw new ArgumentNullException(nameof(logMemory)); - - if ((GlobalLogLevel & message.LogLevel) == LogLevel.None) - return; - - logMemory.Remember(message); - } - - /// - /// Will log a message with the log level. - /// - /// Message to log. - public static void Trace(string message) - { - Log(LogLevel.Trace, message); - } - - /// - /// Will log a message with the log level. - /// - /// Message to log. - public static void Debug(string message) - { - Log(LogLevel.Debug, message); - } - - /// - /// Will log a message with the log level. - /// - /// Message to log. - public static void Info(string message) - { - Log(LogLevel.Info, message); - } - - /// - /// Will log a message with the log level. - /// - /// Message to log. - public static void Warn(string message) - { - Log(LogLevel.Warn, message); - } - - /// - /// Will log a message with the log level. - /// - /// Message to log. - public static void Error(string message) - { - Log(LogLevel.Error, message); - } - } -} diff --git a/SweetLib.Old/Utils/Logger/Memory/ArchivableConsoleLogMemory.cs b/SweetLib.Old/Utils/Logger/Memory/ArchivableConsoleLogMemory.cs deleted file mode 100644 index 482dac5..0000000 --- a/SweetLib.Old/Utils/Logger/Memory/ArchivableConsoleLogMemory.cs +++ /dev/null @@ -1,163 +0,0 @@ -using System; -using System.Collections.Concurrent; -using System.IO; -using System.IO.Compression; -using System.Linq; -using System.Threading; -using SweetLib.Utils.Logger.Message; - -namespace SweetLib.Utils.Logger.Memory -{ - public class ArchivableConsoleLogMemory : ILogMemory - { - private string TempFile { get; } = Path.GetTempFileName(); - - private Timer QueueTimer { get; } - - private ConcurrentQueue LogQueue { get; } = new ConcurrentQueue(); - - public string ArchiveFile { get; set; } = null; - - public bool AutoArchiveOnDispose { get; set; } = true; - - public ArchivableConsoleLogMemory() : this(null) { } - - public ArchivableConsoleLogMemory(string archiveFile) - { - ArchiveFile = archiveFile; - - QueueTimer = new Timer(e => ProcessQueue(), null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); - } - - ~ArchivableConsoleLogMemory() - { - Dispose(false); - } - - private void ProcessQueue(bool isDisposing = false) - { - if (LogQueue.IsEmpty) - return; - - // if we are disposing no need to lock. This might cause issues! - if (!isDisposing) - { - lock (this) - { - if (LogQueue.IsEmpty) - return; - - LogMessage message; - if (LogQueue.TryDequeue(out message)) - File.AppendAllText(TempFile, message.ToString()); - } - } - else - { - if (LogQueue.IsEmpty) - return; - - LogMessage message; - if (LogQueue.TryDequeue(out message)) - File.AppendAllText(TempFile, message.ToString()); - } - } - - public void Remember(LogMessage message) - { - var consoleColor = Console.ForegroundColor; - - switch (message.LogLevel) - { - case LogLevel.Trace: - Console.ForegroundColor = ConsoleColor.Gray; - break; - case LogLevel.Debug: - Console.ForegroundColor = ConsoleColor.DarkYellow; - break; - case LogLevel.Info: - Console.ForegroundColor = ConsoleColor.Cyan; - break; - case LogLevel.Warn: - Console.ForegroundColor = ConsoleColor.Yellow; - break; - case LogLevel.Error: - Console.ForegroundColor = ConsoleColor.Red; - break; - } - - Console.WriteLine(message.ToString()); - LogQueue.Enqueue(message); - - Console.ForegroundColor = consoleColor; - } - - - - public void Forget(LogMessage message) - { - lock (this) - { - var lines = File.ReadAllLines(TempFile).ToList(); - foreach (var line in lines) - { - if (line == message.ToString()) - lines.Remove(line); - } - - File.WriteAllLines(TempFile, lines); - } - } - - public void Archive(string fullFileName = null) - { - if (fullFileName == null) - fullFileName = ArchiveFile; - - if (fullFileName == null) - throw new FileNotFoundException("target file not found"); - - using (var tmpFileStream = new FileInfo(TempFile).OpenRead()) - { - if (!Directory.Exists(Path.GetDirectoryName(fullFileName))) - Directory.CreateDirectory(Path.GetDirectoryName(fullFileName)); - - using (var compressedFileStream = File.Create(fullFileName)) - { - using (var compressionsStream = new GZipStream(compressedFileStream, CompressionMode.Compress)) - { - tmpFileStream.CopyTo(compressionsStream); - } - } - } - } - - public void Dispose() - { - Dispose(true); - GC.SuppressFinalize(this); - } - - protected virtual void Dispose(bool disposing) - { - QueueTimer.Dispose(); - - ProcessQueue(true); - - if (AutoArchiveOnDispose) - { - try - { - Archive(); - } - catch (FileNotFoundException) - { - if (disposing) - throw; - } - } - - File.Delete(TempFile); - } - } -} diff --git a/SweetLib.Old/Utils/Logger/Memory/ILogMemory.cs b/SweetLib.Old/Utils/Logger/Memory/ILogMemory.cs deleted file mode 100644 index 4f59112..0000000 --- a/SweetLib.Old/Utils/Logger/Memory/ILogMemory.cs +++ /dev/null @@ -1,29 +0,0 @@ -using SweetLib.Utils.Logger.Message; - -namespace SweetLib.Utils.Logger.Memory -{ - /// - /// Interface for a class to store and proceed objects. - /// - public interface ILogMemory - { - /// - /// Adds a into the . - /// - /// to be stored. - void Remember(LogMessage message); - - /// - /// Removes a from the . - /// - /// to be removed. - /// This might not have any effect depending on the implementation. - void Forget(LogMessage message); - - /// - /// Saves all remembered objects into a persistent file. - /// - /// File name to store the objects. - void Archive(string fullFileName); - } -} diff --git a/SweetLib.Old/Utils/Logger/Message/LogMessage.cs b/SweetLib.Old/Utils/Logger/Message/LogMessage.cs deleted file mode 100644 index 978dc17..0000000 --- a/SweetLib.Old/Utils/Logger/Message/LogMessage.cs +++ /dev/null @@ -1,72 +0,0 @@ -using System; -using System.Globalization; - -namespace SweetLib.Utils.Logger.Message -{ - /// - /// contains all event log data which should be logged in as a single log message. - /// - public class LogMessage : IFormattable - { - /// - /// The of this event log. - /// - public LogLevel LogLevel { get; } - - /// - /// The message of this event log. - /// - public string Message { get; } - - /// - /// The date and time of this event log. - /// - public DateTime LogDateTime { get; } - - /// - /// Creates a new instance. will be the . - /// - /// The log level of this event log. - /// The message of this event log. - public LogMessage(LogLevel logLevel, string message) : this(logLevel, message, DateTime.Now) { } - - /// - /// Creates a new instance. - /// - /// The log level of this event log. - /// The message of this event log. - /// The of this event log. - public LogMessage(LogLevel logLevel, string message, DateTime logDateTime) - { - if (message == null) - throw new ArgumentNullException(nameof(message)); - - if (logDateTime == null) - throw new ArgumentNullException(nameof(logDateTime)); - - LogLevel = logLevel; - Message = message; - LogDateTime = logDateTime; - } - - /// - /// Generates a formatted of this event log. will be used to format this event log. - /// - /// A formated of this event log. - public override string ToString() - { - return ToString(LogMessageFormatter.DefaultFormatString, CultureInfo.CurrentCulture); - } - - /// - /// Generates a formatted of this event log with a given format. - /// - /// The format to be used. See for more format information. - /// Optional, an interface to be used while formatting if needed. - /// A formated of this event log. - public string ToString(string format, IFormatProvider formatProvider = null) - { - return LogMessageFormatter.Instance.Format(format, this, formatProvider); - } - } -} diff --git a/SweetLib.Old/Utils/Logger/Message/LogMessageFormatter.cs b/SweetLib.Old/Utils/Logger/Message/LogMessageFormatter.cs deleted file mode 100644 index 85befa7..0000000 --- a/SweetLib.Old/Utils/Logger/Message/LogMessageFormatter.cs +++ /dev/null @@ -1,79 +0,0 @@ -using System; -using System.Globalization; - -namespace SweetLib.Utils.Logger.Message -{ - /// - /// A which is used to format objects. - /// - /// This class implements a singleton pattern. - public class LogMessageFormatter : ICustomFormatter - { - - private LogMessageFormatter() { } - - private static object Locker { get; } = new object(); - - /// - /// Accesses the global instance of the . - /// - private static LogMessageFormatter FormatterInstance { get; set; } - - public static string DefaultFormatString { get; set; } = $"[{CultureInfo.CurrentCulture.DateTimeFormat.ShortDatePattern} - {CultureInfo.CurrentCulture.DateTimeFormat.LongTimePattern}] (LL): V"; - - /// - /// The default format string which is used to format objects, if no custom format string is provided. - /// - public static LogMessageFormatter Instance - { - get - { - if (FormatterInstance != null) - return FormatterInstance; - - lock (Locker) - { - if (FormatterInstance != null) - return FormatterInstance; - - FormatterInstance = new LogMessageFormatter(); - } - return FormatterInstance; - } - } - - /// - /// Formats a object. - /// - /// The format string. If , will be used. - /// The object to be formatted. - /// Optional, an interface to be used while formatting if needed. - /// A formatted of the . - /// - /// If is not a object, it will either be returned the formatted string implemented by the type of , if is implemented by it, or the result." - /// - public string Format(string format, object arg, IFormatProvider formatProvider) - { - if (format == null) - format = DefaultFormatString; - - if (arg == null) - throw new ArgumentNullException(nameof(arg)); - - if (arg.GetType() != typeof(LogMessage)) - { - var formattable = arg as IFormattable; - return formattable?.ToString(format, formatProvider) ?? arg.ToString(); - } - - var message = (LogMessage)arg; - - var result = message.LogDateTime.ToString(format, formatProvider); - - result = result.Replace("LL", message.LogLevel.ToString()); - result = result.Replace("V", message.Message); - - return result; - } - } -} diff --git a/SweetLib.Old/Utils/SweetUtils.cs b/SweetLib.Old/Utils/SweetUtils.cs deleted file mode 100644 index 4147a48..0000000 --- a/SweetLib.Old/Utils/SweetUtils.cs +++ /dev/null @@ -1,63 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace SweetLib.Utils -{ - /// - /// A generic class containing useful methods. - /// - public static class SweetUtils - { - public static char DefaultFileNameReplaceChar { get; set; } = '-'; - - /// - /// Legalizes a file name with the character. - /// - /// File name to legalize. - /// Legalized file name. - public static string LegalizeFilename(string fileName) - { - return LegalizeFilename(fileName, '-'); - } - - /// - /// Legalizes a file name by a given replace character. - /// - /// File name to legalize. - /// Character to be used as replace character. - /// Legalized file name. - public static string LegalizeFilename(string fileName, char replaceChar) - { - var invalidChars = System.IO.Path.GetInvalidFileNameChars(); - - if (invalidChars.Contains(replaceChar)) - throw new IOException($"Replace character {replaceChar} is an invalid file name character."); - - return invalidChars.Aggregate(fileName, (current, c) => current.Replace(c, replaceChar)); - } - - /// - /// Converts a into an Unix timestamp. - /// - /// to convert into Unix timestamp. - /// Converted Unix timestamp. - public static double DateTimeToUnixTimeStamp(DateTime date) - { - return date.Subtract(new DateTime(1970, 1, 1)).TotalSeconds; - } - - /// - /// Converts an Unix timestamp into a . - /// - /// Unix timestamp to convert. - /// Converted . - public static DateTime UnixTimestampToDateTime(double timestamp) - { - return new DateTime(1970, 1, 1).AddMilliseconds(timestamp); - } - } -} diff --git a/SweetLib.Old/Utils/TaskBar/TaskBarProgress.cs b/SweetLib.Old/Utils/TaskBar/TaskBarProgress.cs deleted file mode 100644 index cde7803..0000000 --- a/SweetLib.Old/Utils/TaskBar/TaskBarProgress.cs +++ /dev/null @@ -1,65 +0,0 @@ -using System; -using System.Runtime.InteropServices; - -namespace SweetLib.Utils.TaskBar -{ - public static class TaskBarProgress - { - public enum TaskbarStates - { - NoProgress = 0, - Indeterminate = 0x1, - Normal = 0x2, - Error = 0x4, - Paused = 0x8 - } - - [ComImport] - [Guid("26C41017-74B8-4C70-88AA-61B11D8C0D5A")] - [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)] - private interface ITaskbarList3 - { - // ITaskbarList - [PreserveSig] - void HrInit(); - [PreserveSig] - void AddTab(IntPtr hwnd); - [PreserveSig] - void DeleteTab(IntPtr hwnd); - [PreserveSig] - void ActivateTab(IntPtr hwnd); - [PreserveSig] - void SetActiveAlt(IntPtr hwnd); - - // ITaskbarList2 - [PreserveSig] - void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen); - - // ITaskbarList3 - [PreserveSig] - void SetProgressValue(IntPtr hwnd, UInt64 ullCompleted, UInt64 ullTotal); - [PreserveSig] - void SetProgressState(IntPtr hwnd, TaskbarStates state); - } - - [Guid("D6031210-4108-4E8A-B740-A627052FDAC2")] - [ClassInterface(ClassInterfaceType.None)] - [ComImport] - private class TaskbarInstance - { - } - - private static ITaskbarList3 taskbarInstance = (ITaskbarList3)new TaskbarInstance(); - private static bool taskbarSupported = Environment.OSVersion.Version >= new Version(6, 1); - - public static void SetState(IntPtr windowHandle, TaskbarStates taskbarState) - { - if (taskbarSupported) taskbarInstance.SetProgressState(windowHandle, taskbarState); - } - - public static void SetValue(IntPtr windowHandle, double progressValue, double progressMax) - { - if (taskbarSupported) taskbarInstance.SetProgressValue(windowHandle, (ulong)progressValue, (ulong)progressMax); - } - } -} diff --git a/SweetLib.Old/build-nuget.bat b/SweetLib.Old/build-nuget.bat deleted file mode 100644 index ac3b2ab..0000000 --- a/SweetLib.Old/build-nuget.bat +++ /dev/null @@ -1,2 +0,0 @@ -nuget pack SweetLib.csproj -properties Configuration=Release -symbols -pause \ No newline at end of file diff --git a/SweetLib.sln b/SweetLib.sln index 170dc46..6673fc1 100644 --- a/SweetLib.sln +++ b/SweetLib.sln @@ -7,9 +7,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SweetLib.Demo", "SweetLib.D EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SweetLib.Demo.Console", "SweetLib.Demo.Console\SweetLib.Demo.Console.csproj", "{C8681E08-6F23-45E1-A16F-BBA72003219B}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SweetLib.Old", "SweetLib.Old\SweetLib.Old.csproj", "{02C1F8EF-32F2-4E77-A36D-79129402AF37}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SweetLib", "SweetLib\SweetLib.csproj", "{7C15F2F3-2BF2-46FB-B813-9EEC1B41D679}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SweetLib", "SweetLib\SweetLib.csproj", "{7C15F2F3-2BF2-46FB-B813-9EEC1B41D679}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -25,10 +23,6 @@ Global {C8681E08-6F23-45E1-A16F-BBA72003219B}.Debug|Any CPU.Build.0 = Debug|Any CPU {C8681E08-6F23-45E1-A16F-BBA72003219B}.Release|Any CPU.ActiveCfg = Release|Any CPU {C8681E08-6F23-45E1-A16F-BBA72003219B}.Release|Any CPU.Build.0 = Release|Any CPU - {02C1F8EF-32F2-4E77-A36D-79129402AF37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {02C1F8EF-32F2-4E77-A36D-79129402AF37}.Debug|Any CPU.Build.0 = Debug|Any CPU - {02C1F8EF-32F2-4E77-A36D-79129402AF37}.Release|Any CPU.ActiveCfg = Release|Any CPU - {02C1F8EF-32F2-4E77-A36D-79129402AF37}.Release|Any CPU.Build.0 = Release|Any CPU {7C15F2F3-2BF2-46FB-B813-9EEC1B41D679}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {7C15F2F3-2BF2-46FB-B813-9EEC1B41D679}.Debug|Any CPU.Build.0 = Debug|Any CPU {7C15F2F3-2BF2-46FB-B813-9EEC1B41D679}.Release|Any CPU.ActiveCfg = Release|Any CPU From 661148af95d41f9f9c83f3b90dffcbe8398a60ad Mon Sep 17 00:00:00 2001 From: Serraniel Date: Thu, 26 Oct 2017 19:05:06 +0200 Subject: [PATCH 13/13] Fixed the demo projects --- SweetLib.Demo.Console/App.config | 6 +++--- SweetLib.Demo.Console/Program.cs | 8 +------- SweetLib.Demo.Console/Properties/AssemblyInfo.cs | 1 - .../SweetLib.Demo.Console.csproj | 9 ++++++++- SweetLib.Demo/App.config | 2 +- SweetLib.Demo/MainForm.cs | 15 ++++----------- SweetLib.Demo/Program.cs | 3 --- SweetLib.Demo/Properties/AssemblyInfo.cs | 1 - SweetLib.Demo/Properties/Resources.Designer.cs | 2 +- SweetLib.Demo/Properties/Settings.Designer.cs | 2 +- SweetLib.Demo/SweetLib.Demo.csproj | 8 +++++++- SweetLib/Classes/Storer/RegistryStorer.cs | 5 +---- 12 files changed, 27 insertions(+), 35 deletions(-) diff --git a/SweetLib.Demo.Console/App.config b/SweetLib.Demo.Console/App.config index 731f6de..2d2a12d 100644 --- a/SweetLib.Demo.Console/App.config +++ b/SweetLib.Demo.Console/App.config @@ -1,6 +1,6 @@ - + - + - \ No newline at end of file + diff --git a/SweetLib.Demo.Console/Program.cs b/SweetLib.Demo.Console/Program.cs index b7e4391..61d0cfd 100644 --- a/SweetLib.Demo.Console/Program.cs +++ b/SweetLib.Demo.Console/Program.cs @@ -1,12 +1,6 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using System.IO; using SweetLib.Classes.Storer; using SweetLib.Utils.Logger; -using SweetLib.Utils.Logger.Message; namespace SweetLib.Demo.Console { diff --git a/SweetLib.Demo.Console/Properties/AssemblyInfo.cs b/SweetLib.Demo.Console/Properties/AssemblyInfo.cs index 1e48fc1..7a01ec7 100644 --- a/SweetLib.Demo.Console/Properties/AssemblyInfo.cs +++ b/SweetLib.Demo.Console/Properties/AssemblyInfo.cs @@ -1,5 +1,4 @@ using System.Reflection; -using System.Runtime.CompilerServices; using System.Runtime.InteropServices; // Allgemeine Informationen über eine Assembly werden über die folgenden diff --git a/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj b/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj index 4a7e6f1..ac4315b 100644 --- a/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj +++ b/SweetLib.Demo.Console/SweetLib.Demo.Console.csproj @@ -9,9 +9,10 @@ Properties SweetLib.Demo.Console SweetLib.Demo.Console - v4.6.1 + v4.6 512 true + AnyCPU @@ -49,6 +50,12 @@ + + + {7c15f2f3-2bf2-46fb-b813-9eec1b41d679} + SweetLib + +