diff options
| author | Roy Ben-Shabat <Roy@Twine-s.com> | 2019-11-25 16:39:01 +0200 |
|---|---|---|
| committer | Roy Ben-Shabat <Roy@Twine-s.com> | 2019-11-25 16:39:01 +0200 |
| commit | 78c93e2ee1eddff67554edec9f956536a0b61482 (patch) | |
| tree | 208e8f9c368cfa324e255493bb287e50b79b04fa /Software | |
| parent | ca18248f6203d7567a2276ec76360aedd4cfda0b (diff) | |
| download | Tango-78c93e2ee1eddff67554edec9f956536a0b61482.tar.gz Tango-78c93e2ee1eddff67554edec9f956536a0b61482.zip | |
Working on Backup/Restore...
Diffstat (limited to 'Software')
77 files changed, 1574 insertions, 612 deletions
diff --git a/Software/Graphics/Mobile/error.png b/Software/Graphics/Mobile/error.png Binary files differindex 02a0a91a9..b4b50e4ac 100644 --- a/Software/Graphics/Mobile/error.png +++ b/Software/Graphics/Mobile/error.png diff --git a/Software/Graphics/Mobile/error@2x.png b/Software/Graphics/Mobile/error@2x.png Binary files differindex 9ef36018d..2aa0de6b8 100644 --- a/Software/Graphics/Mobile/error@2x.png +++ b/Software/Graphics/Mobile/error@2x.png diff --git a/Software/Graphics/Mobile/error@3x.png b/Software/Graphics/Mobile/error@3x.png Binary files differindex da9d34557..f1222eb64 100644 --- a/Software/Graphics/Mobile/error@3x.png +++ b/Software/Graphics/Mobile/error@3x.png diff --git a/Software/Graphics/Mobile/getting-ready.png b/Software/Graphics/Mobile/getting-ready.png Binary files differnew file mode 100644 index 000000000..a0dc77f92 --- /dev/null +++ b/Software/Graphics/Mobile/getting-ready.png diff --git a/Software/Graphics/Mobile/getting-ready@2x.png b/Software/Graphics/Mobile/getting-ready@2x.png Binary files differnew file mode 100644 index 000000000..f71d53c50 --- /dev/null +++ b/Software/Graphics/Mobile/getting-ready@2x.png diff --git a/Software/Graphics/Mobile/getting-ready@3x.png b/Software/Graphics/Mobile/getting-ready@3x.png Binary files differnew file mode 100644 index 000000000..850b1c624 --- /dev/null +++ b/Software/Graphics/Mobile/getting-ready@3x.png diff --git a/Software/Graphics/Mobile/service.png b/Software/Graphics/Mobile/service.png Binary files differnew file mode 100644 index 000000000..ba351ee66 --- /dev/null +++ b/Software/Graphics/Mobile/service.png diff --git a/Software/Graphics/Mobile/service@2x.png b/Software/Graphics/Mobile/service@2x.png Binary files differnew file mode 100644 index 000000000..3b0c9ddad --- /dev/null +++ b/Software/Graphics/Mobile/service@2x.png diff --git a/Software/Graphics/Mobile/service@3x.png b/Software/Graphics/Mobile/service@3x.png Binary files differnew file mode 100644 index 000000000..a575501b8 --- /dev/null +++ b/Software/Graphics/Mobile/service@3x.png diff --git a/Software/Graphics/Mobile/shutting-down.png b/Software/Graphics/Mobile/shutting-down.png Binary files differnew file mode 100644 index 000000000..9aa8e2db6 --- /dev/null +++ b/Software/Graphics/Mobile/shutting-down.png diff --git a/Software/Graphics/Mobile/shutting-down@2x.png b/Software/Graphics/Mobile/shutting-down@2x.png Binary files differnew file mode 100644 index 000000000..ee0d1e603 --- /dev/null +++ b/Software/Graphics/Mobile/shutting-down@2x.png diff --git a/Software/Graphics/Mobile/shutting-down@3x.png b/Software/Graphics/Mobile/shutting-down@3x.png Binary files differnew file mode 100644 index 000000000..75209f7d2 --- /dev/null +++ b/Software/Graphics/Mobile/shutting-down@3x.png diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml new file mode 100644 index 000000000..595ed2299 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml @@ -0,0 +1,11 @@ +<Application x:Class="Tango.PPC.BackupRestore.App" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> + <Application.Resources> + <ResourceDictionary> + <ResourceDictionary.MergedDictionaries> + <ResourceDictionary Source="pack://application:,,,/Tango.PPC.Common;component/Resources/Merged.xaml" /> + </ResourceDictionary.MergedDictionaries> + </ResourceDictionary> + </Application.Resources> +</Application>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupFile.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupFile.cs deleted file mode 100644 index 4425aad9e..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupFile.cs +++ /dev/null @@ -1,64 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Tango.Web; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup file record. - /// </summary> - public class BackupFile - { - /// <summary> - /// Gets or sets the backup name. - /// </summary> - public String Name { get; set; } - - /// <summary> - /// Gets or sets the creation date. - /// </summary> - public DateTime Date { get; set; } - - /// <summary> - /// Gets or sets the machine serial number. - /// </summary> - public String MachineSerialNumber { get; set; } - - /// <summary> - /// Gets or sets the application version. - /// </summary> - public String ApplicationVersion { get; set; } - - /// <summary> - /// Gets or sets the firmware version. - /// </summary> - public String FirmwareVersion { get; set; } - - /// <summary> - /// Gets or sets the settings file. - /// </summary> - public String SettingsFile { get; set; } - - /// <summary> - /// Gets or sets the job files. - /// </summary> - public List<String> JobFiles { get; set; } - - /// <summary> - /// Gets or sets the backup settings. - /// </summary> - public BackupSettings Settings { get; set; } - - /// <summary> - /// Initializes a new instance of the <see cref="BackupFile"/> class. - /// </summary> - public BackupFile() - { - Settings = new BackupSettings(); - JobFiles = new List<string>(); - } - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupMode.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupMode.cs deleted file mode 100644 index 8533ce22a..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupMode.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup mode. - /// </summary> - public enum BackupMode - { - /// <summary> - /// Jobs only backup. - /// </summary> - Jobs, - /// <summary> - /// Complete backup of data, app binaries, firmware and settings file. - /// </summary> - Full, - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreProgressEventArgs.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreProgressEventArgs.cs deleted file mode 100644 index d12db7b56..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreProgressEventArgs.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup restore procedure progress. - /// </summary> - /// <seealso cref="System.EventArgs" /> - public class BackupRestoreProgressEventArgs : EventArgs - { - /// <summary> - /// Gets or sets a value indicating whether the progress is intermediate. - /// </summary> - public bool IsIntermediate { get; set; } - - /// <summary> - /// Gets or sets the progress value. - /// </summary> - public double Progress { get; set; } - - - /// <summary> - /// Gets or sets the maximum progress. - /// </summary> - public double MaxProgress { get; set; } - - /// <summary> - /// Gets or sets the progress stage. - /// </summary> - public BackupRestoreStage Stage { get; set; } - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreStage.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreStage.cs deleted file mode 100644 index efef2d4d0..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupRestoreStage.cs +++ /dev/null @@ -1,47 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup restore procedure stage. - /// </summary> - public enum BackupRestoreStage - { - [Description("Initializing")] - Initializing, - - //Backup - [Description("Backing up data...")] - BackingupDatabase, - [Description("Backing up application...")] - BackingupApplication, - [Description("Backing up settings...")] - BackingupSettings, - [Description("Writing settings...")] - WritingSettings, - [Description("Compressing files...")] - CompressingFiles, - [Description("Finalizing backup...")] - FinalizingBackup, - - //Restore - [Description("Validating backup...")] - ValidatingBackup, - [Description("Extracting content...")] - ExtractingContent, - [Description("Restoring data...")] - RestoringDatabase, - - - [Description("Done")] - Done, - - [Description("Error")] - Error, - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupSettings.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupSettings.cs deleted file mode 100644 index b2021ba39..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/BackupSettings.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup settings. - /// </summary> - public class BackupSettings - { - /// <summary> - /// Gets or sets the backup mode. - /// </summary> - public BackupMode Mode { get; set; } - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/IBackupManager.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/IBackupManager.cs deleted file mode 100644 index a50f0ab60..000000000 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestore/IBackupManager.cs +++ /dev/null @@ -1,34 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - /// <summary> - /// Represents a backup/restore manager. - /// </summary> - public interface IBackupManager - { - /// <summary> - /// Occurs when the backup/restore procedure makes progress. - /// </summary> - event EventHandler<BackupRestoreProgressEventArgs> Progress; - - /// <summary> - /// Creates a backup file containing database, application and firmware versions. - /// </summary> - /// <param name="filePath">The file path.</param> - /// <param name="settings">Backup configuration.</param> - /// <returns></returns> - Task CreateBackup(String filePath, BackupSettings settings); - - /// <summary> - /// Restores a backup located in the specified file path. - /// </summary> - /// <param name="filePath">The file path.</param> - /// <returns></returns> - Task Restore(String filePath); - } -} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs new file mode 100644 index 000000000..0524e2f16 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs @@ -0,0 +1,84 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Media.Imaging; +using Tango.BL.Enumerations; +using Tango.PPC.Common; +using Tango.PPC.BackupRestore.Views; +using Tango.SharedUI.Helpers; + +namespace Tango.PPC.BackupRestore +{ + /// <summary> + /// Represents a PPC <see cref="BackupRestoreModule"/>. + /// </summary> + /// <seealso cref="Tango.PPC.Common.PPCModuleBase" /> + [PPCModule(20)] + public class BackupRestoreModule : PPCModuleBase + { + /// <summary> + /// Gets the module name. + /// </summary> + public override string Name + { + get + { + return "Backup/Restore"; + } + } + + /// <summary> + /// Gets the module description. + /// </summary> + public override string Description + { + get + { + return "Tango Backup/Restore Module"; + } + } + + /// <summary> + /// Gets the module cover image. + /// </summary> + public override BitmapSource Image + { + get + { + return ResourceHelper.GetImageFromResources("Images/backup-big.png"); + } + } + + /// <summary> + /// Gets the module entry point view type. + /// </summary> + public override Type MainViewType + { + get + { + return typeof(MainView); + } + } + + /// <summary> + /// Gets the permission required to see and load this module. + /// </summary> + public override Permissions Permission + { + get + { + return Permissions.RunPPC; + } + } + + /// <summary> + /// Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + /// </summary> + public override void Dispose() + { + //Dispose module here... + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-big.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-big.png Binary files differnew file mode 100644 index 000000000..3a712af49 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-big.png diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-restore.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-restore.png Binary files differnew file mode 100644 index 000000000..15be3b163 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-restore.png diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/restore.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/restore.png Binary files differnew file mode 100644 index 000000000..e60aaf425 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/restore.png diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/AssemblyInfo.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/AssemblyInfo.cs new file mode 100644 index 000000000..ac385e0ba --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/AssemblyInfo.cs @@ -0,0 +1,20 @@ +using System.Reflection; +using System.Resources; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; +using System.Windows; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Tango Backup & Restore Module")] +[assembly: AssemblyVersion("2.0.1.1407")] + +[assembly: ThemeInfo( + ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located + //(used if a resource is not found in the page, + // or application resource dictionaries) + ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located + //(used if a resource is not found in the page, + // app, or any theme specific resource dictionaries) +)] diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.Designer.cs new file mode 100644 index 000000000..160bdf95c --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.Designer.cs @@ -0,0 +1,63 @@ +//------------------------------------------------------------------------------ +// <auto-generated> +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// </auto-generated> +//------------------------------------------------------------------------------ + +namespace Tango.PPC.BackupRestore.Properties { + using System; + + + /// <summary> + /// A strongly-typed resource class, for looking up localized strings, etc. + /// </summary> + // This class was auto-generated by the StronglyTypedResourceBuilder + // class via a tool like ResGen or Visual Studio. + // To add or remove a member, edit your .ResX file then rerun ResGen + // with the /str option, or rebuild your VS project. + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() { + } + + /// <summary> + /// Returns the cached ResourceManager instance used by this class. + /// </summary> + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager { + get { + if (object.ReferenceEquals(resourceMan, null)) { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Tango.PPC.BackupRestore.Properties.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// <summary> + /// Overrides the current thread's CurrentUICulture property for all + /// resource lookups using this strongly typed resource class. + /// </summary> + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture { + get { + return resourceCulture; + } + set { + resourceCulture = value; + } + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.resx b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.resx new file mode 100644 index 000000000..af7dbebba --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.resx @@ -0,0 +1,117 @@ +<?xml version="1.0" encoding="utf-8"?> +<root> + <!-- + Microsoft ResX Schema + + Version 2.0 + + The primary goals of this format is to allow a simple XML format + that is mostly human readable. The generation and parsing of the + various data types are done through the TypeConverter classes + associated with the data types. + + Example: + + ... ado.net/XML headers & schema ... + <resheader name="resmimetype">text/microsoft-resx</resheader> + <resheader name="version">2.0</resheader> + <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader> + <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader> + <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data> + <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data> + <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64"> + <value>[base64 mime encoded serialized .NET Framework object]</value> + </data> + <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> + <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> + <comment>This is a comment</comment> + </data> + + There are any number of "resheader" rows that contain simple + name/value pairs. + + Each data row contains a name, and value. The row also contains a + type or mimetype. Type corresponds to a .NET class that support + text/value conversion through the TypeConverter architecture. + Classes that don't support this are serialized and stored with the + mimetype set. + + The mimetype is used for serialized objects, and tells the + ResXResourceReader how to depersist the object. This is currently not + extensible. For a given mimetype the value must be set accordingly: + + Note - application/x-microsoft.net.object.binary.base64 is the format + that the ResXResourceWriter will generate, however the reader can + read any of the formats listed below. + + mimetype: application/x-microsoft.net.object.binary.base64 + value : The object must be serialized with + : System.Serialization.Formatters.Binary.BinaryFormatter + : and then encoded with base64 encoding. + + mimetype: application/x-microsoft.net.object.soap.base64 + value : The object must be serialized with + : System.Runtime.Serialization.Formatters.Soap.SoapFormatter + : and then encoded with base64 encoding. + + mimetype: application/x-microsoft.net.object.bytearray.base64 + value : The object must be serialized into a byte array + : using a System.ComponentModel.TypeConverter + : and then encoded with base64 encoding. + --> + <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> + <xsd:element name="root" msdata:IsDataSet="true"> + <xsd:complexType> + <xsd:choice maxOccurs="unbounded"> + <xsd:element name="metadata"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="value" type="xsd:string" minOccurs="0" /> + </xsd:sequence> + <xsd:attribute name="name" type="xsd:string" /> + <xsd:attribute name="type" type="xsd:string" /> + <xsd:attribute name="mimetype" type="xsd:string" /> + </xsd:complexType> + </xsd:element> + <xsd:element name="assembly"> + <xsd:complexType> + <xsd:attribute name="alias" type="xsd:string" /> + <xsd:attribute name="name" type="xsd:string" /> + </xsd:complexType> + </xsd:element> + <xsd:element name="data"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> + <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" /> + </xsd:sequence> + <xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" /> + <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" /> + <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" /> + </xsd:complexType> + </xsd:element> + <xsd:element name="resheader"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> + </xsd:sequence> + <xsd:attribute name="name" type="xsd:string" use="required" /> + </xsd:complexType> + </xsd:element> + </xsd:choice> + </xsd:complexType> + </xsd:element> + </xsd:schema> + <resheader name="resmimetype"> + <value>text/microsoft-resx</value> + </resheader> + <resheader name="version"> + <value>2.0</value> + </resheader> + <resheader name="reader"> + <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> + </resheader> + <resheader name="writer"> + <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> + </resheader> +</root>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.Designer.cs new file mode 100644 index 000000000..087ecdbcd --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.Designer.cs @@ -0,0 +1,26 @@ +//------------------------------------------------------------------------------ +// <auto-generated> +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// </auto-generated> +//------------------------------------------------------------------------------ + +namespace Tango.PPC.BackupRestore.Properties { + + + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.8.0.0")] + internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { + + private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); + + public static Settings Default { + get { + return defaultInstance; + } + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.settings b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.settings new file mode 100644 index 000000000..033d7a5e9 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.settings @@ -0,0 +1,7 @@ +<?xml version='1.0' encoding='utf-8'?> +<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)"> + <Profiles> + <Profile Name="(Default)" /> + </Profiles> + <Settings /> +</SettingsFile>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Tango.PPC.BackupRestore.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Tango.PPC.BackupRestore.csproj new file mode 100644 index 000000000..d32415e17 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Tango.PPC.BackupRestore.csproj @@ -0,0 +1,207 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> + <ProjectGuid>{BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}</ProjectGuid> + <OutputType>library</OutputType> + <RootNamespace>Tango.PPC.BackupRestore</RootNamespace> + <AssemblyName>Tango.PPC.BackupRestore</AssemblyName> + <TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion> + <FileAlignment>512</FileAlignment> + <ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> + <WarningLevel>4</WarningLevel> + <TargetFrameworkProfile /> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> + <DebugSymbols>true</DebugSymbols> + <DebugType>full</DebugType> + <Optimize>false</Optimize> + <OutputPath>..\..\..\Build\PPC\Debug\</OutputPath> + <DefineConstants>DEBUG;TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> + <DebugType>pdbonly</DebugType> + <Optimize>true</Optimize> + <OutputPath>..\..\..\Build\PPC\Release\</OutputPath> + <DefineConstants>TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <ItemGroup> + <Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"> + <HintPath>..\..\..\packages\EntityFramework.6.0.0\lib\net45\EntityFramework.dll</HintPath> + <Private>True</Private> + </Reference> + <Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"> + <HintPath>..\..\..\packages\EntityFramework.6.0.0\lib\net45\EntityFramework.SqlServer.dll</HintPath> + </Reference> + <Reference Include="FontAwesome.WPF, Version=4.7.0.37774, Culture=neutral, PublicKeyToken=0758b07a11a4f466, processorArchitecture=MSIL"> + <HintPath>..\..\..\packages\FontAwesome.WPF.4.7.0.9\lib\net40\FontAwesome.WPF.dll</HintPath> + </Reference> + <Reference Include="Google.Protobuf, Version=3.4.1.0, Culture=neutral, PublicKeyToken=a7d26565bac4d604, processorArchitecture=MSIL"> + <HintPath>..\..\..\packages\Google.Protobuf.3.4.1\lib\net45\Google.Protobuf.dll</HintPath> + </Reference> + <Reference Include="System" /> + <Reference Include="System.ComponentModel.DataAnnotations" /> + <Reference Include="System.Data" /> + <Reference Include="System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL"> + <HintPath>..\..\..\packages\Expression.Blend.Sdk.1.0.2\lib\net45\System.Windows.Interactivity.dll</HintPath> + </Reference> + <Reference Include="System.Xml" /> + <Reference Include="Microsoft.CSharp" /> + <Reference Include="System.Core" /> + <Reference Include="System.Xml.Linq" /> + <Reference Include="System.Data.DataSetExtensions" /> + <Reference Include="System.Net.Http" /> + <Reference Include="System.Xaml"> + <RequiredTargetFramework>4.0</RequiredTargetFramework> + </Reference> + <Reference Include="WindowsBase" /> + <Reference Include="PresentationCore" /> + <Reference Include="PresentationFramework" /> + </ItemGroup> + <ItemGroup> + <Page Include="App.xaml"> + <Generator>MSBuild:Compile</Generator> + <SubType>Designer</SubType> + </Page> + <Page Include="Views\BackupProgressView.xaml"> + <Generator>MSBuild:Compile</Generator> + <SubType>Designer</SubType> + </Page> + <Page Include="Views\BackupView.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + <Page Include="Views\MainView.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + <Page Include="Views\RestoreView.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + <Page Include="Views\WelcomeView.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + </ItemGroup> + <ItemGroup> + <Compile Include="..\..\..\Versioning\GlobalVersionInfo.cs"> + <Link>GlobalVersionInfo.cs</Link> + </Compile> + <Compile Include="BackupRestoreModule.cs" /> + <Compile Include="Properties\AssemblyInfo.cs"> + <SubType>Code</SubType> + </Compile> + <Compile Include="Properties\Resources.Designer.cs"> + <AutoGen>True</AutoGen> + <DesignTime>True</DesignTime> + <DependentUpon>Resources.resx</DependentUpon> + </Compile> + <Compile Include="Properties\Settings.Designer.cs"> + <AutoGen>True</AutoGen> + <DependentUpon>Settings.settings</DependentUpon> + <DesignTimeSharedInput>True</DesignTimeSharedInput> + </Compile> + <Compile Include="ViewModelLocator.cs" /> + <Compile Include="ViewModels\BackupViewVM.cs" /> + <Compile Include="ViewModels\MainViewVM.cs" /> + <Compile Include="ViewModels\RestoreViewVM.cs" /> + <Compile Include="ViewModels\WelcomeViewVM.cs" /> + <Compile Include="Views\BackupProgressView.xaml.cs"> + <DependentUpon>BackupProgressView.xaml</DependentUpon> + </Compile> + <Compile Include="Views\BackupView.xaml.cs"> + <DependentUpon>BackupView.xaml</DependentUpon> + </Compile> + <Compile Include="Views\MainView.xaml.cs"> + <DependentUpon>MainView.xaml</DependentUpon> + </Compile> + <Compile Include="Views\RestoreView.xaml.cs"> + <DependentUpon>RestoreView.xaml</DependentUpon> + </Compile> + <Compile Include="Views\WelcomeView.xaml.cs"> + <DependentUpon>WelcomeView.xaml</DependentUpon> + </Compile> + <EmbeddedResource Include="Properties\Resources.resx"> + <Generator>ResXFileCodeGenerator</Generator> + <LastGenOutput>Resources.Designer.cs</LastGenOutput> + </EmbeddedResource> + <None Include="app.config" /> + <None Include="packages.config" /> + <None Include="Properties\Settings.settings"> + <Generator>SettingsSingleFileGenerator</Generator> + <LastGenOutput>Settings.Designer.cs</LastGenOutput> + </None> + </ItemGroup> + <ItemGroup> + <ProjectReference Include="..\..\..\Tango.BL\Tango.BL.csproj"> + <Project>{f441feee-322a-4943-b566-110e12fd3b72}</Project> + <Name>Tango.BL</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Core\Tango.Core.csproj"> + <Project>{a34ee0f0-649d-41c8-8489-b6f1cc6924ee}</Project> + <Name>Tango.Core</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.DragAndDrop\Tango.DragAndDrop.csproj"> + <Project>{b112d89a-a106-41ae-a0c1-4abc84c477f5}</Project> + <Name>Tango.DragAndDrop</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Explorer\Tango.Explorer.csproj"> + <Project>{4399AF76-DB52-4CFB-8020-6F85BDB29FD5}</Project> + <Name>Tango.Explorer</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Logging\Tango.Logging.csproj"> + <Project>{bc932dbd-7cdb-488c-99e4-f02cf441f55e}</Project> + <Name>Tango.Logging</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.PMR\Tango.PMR.csproj"> + <Project>{e4927038-348d-4295-aaf4-861c58cb3943}</Project> + <Name>Tango.PMR</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Settings\Tango.Settings.csproj"> + <Project>{d8f1ad85-526a-4f50-b6dc-d437af63d8d8}</Project> + <Name>Tango.Settings</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.SharedUI\Tango.SharedUI.csproj"> + <Project>{8491d07b-c1f6-4b62-a412-41b9fd2d6538}</Project> + <Name>Tango.SharedUI</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Touch\Tango.Touch.csproj"> + <Project>{fd86424c-6e84-491b-8df9-3d0f5c236a2a}</Project> + <Name>Tango.Touch</Name> + </ProjectReference> + <ProjectReference Include="..\..\..\Tango.Transport\Tango.Transport.csproj"> + <Project>{74e700b0-1156-4126-be40-ee450d3c3026}</Project> + <Name>Tango.Transport</Name> + </ProjectReference> + <ProjectReference Include="..\..\Tango.PPC.Common\Tango.PPC.Common.csproj"> + <Project>{0be74eee-22cb-4dba-b896-793b9e1a3ac0}</Project> + <Name>Tango.PPC.Common</Name> + </ProjectReference> + <ProjectReference Include="..\Tango.PPC.Storage\Tango.PPC.Storage.csproj"> + <Project>{04FEBB02-F782-4B96-B47D-F6902AFA43BE}</Project> + <Name>Tango.PPC.Storage</Name> + </ProjectReference> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\backup-big.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\backup-restore.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\restore.png" /> + </ItemGroup> + <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> + <ProjectExtensions> + <VisualStudio> + <UserProperties BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_StartDate="2000/1/1" /> + </VisualStudio> + </ProjectExtensions> +</Project>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModelLocator.cs new file mode 100644 index 000000000..e414bca51 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModelLocator.cs @@ -0,0 +1,59 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tango.Core.DI; +using Tango.PPC.BackupRestore.ViewModels; + +namespace Tango.PPC.BackupRestore +{ + public static class ViewModelLocator + { + /// <summary> + /// Initializes a new instance of the ViewModelLocator class. + /// </summary> + static ViewModelLocator() + { + TangoIOC.Default.Register<MainViewVM>(); + TangoIOC.Default.Register<WelcomeViewVM>(); + TangoIOC.Default.Register<BackupViewVM>(); + TangoIOC.Default.Register<RestoreViewVM>(); + } + + /// <summary> + /// Gets the main view VM. + /// </summary> + public static MainViewVM MainViewVM + { + get + { + return TangoIOC.Default.GetInstance<MainViewVM>(); + } + } + + public static WelcomeViewVM WelcomeViewVM + { + get + { + return TangoIOC.Default.GetInstance<WelcomeViewVM>(); + } + } + + public static BackupViewVM BackupViewVM + { + get + { + return TangoIOC.Default.GetInstance<BackupViewVM>(); + } + } + + public static RestoreViewVM RestoreViewVM + { + get + { + return TangoIOC.Default.GetInstance<RestoreViewVM>(); + } + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupViewVM.cs new file mode 100644 index 000000000..067e40d08 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupViewVM.cs @@ -0,0 +1,145 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tango.Core.Commands; +using Tango.Core.DI; +using Tango.Explorer; +using Tango.PPC.BackupRestore.Views; +using Tango.PPC.Common; +using Tango.PPC.Common.BackupRestore; +using Tango.PPC.Storage; + +namespace Tango.PPC.BackupRestore.ViewModels +{ + public class BackupViewVM : PPCViewModel + { + [TangoInject] + public IBackupManager BackupManager { get; set; } + + public BackupSettings BackupSettings { get; set; } + + private BackupRestoreProgressEventArgs _currentBackupProgress; + public BackupRestoreProgressEventArgs CurrentBackupProgress + { + get { return _currentBackupProgress; } + set { _currentBackupProgress = value; RaisePropertyChangedAuto(); } + } + + + private bool _isBackupJobs; + public bool IsBackupJobs + { + get { return _isBackupJobs; } + set + { + if (value) + { + _isBackupJobs = value; + RaisePropertyChangedAuto(); + _isBackupFull = false; + RaisePropertyChanged(nameof(IsBackupFull)); + } + else + { + RaisePropertyChangedAuto(); + } + } + } + + private bool _isBackupFull; + public bool IsBackupFull + { + get { return _isBackupFull; } + set + { + if (value) + { + _isBackupFull = value; + RaisePropertyChangedAuto(); + _isBackupJobs = false; + RaisePropertyChanged(nameof(IsBackupJobs)); + } + else + { + RaisePropertyChangedAuto(); + } + } + } + + private String _backupLocation; + public String BackupLocation + { + get { return _backupLocation; } + set { _backupLocation = value; RaisePropertyChangedAuto(); } + } + + private String _backupName; + public String BackupName + { + get { return _backupName; } + set { _backupName = value; RaisePropertyChangedAuto(); } + } + + public RelayCommand BackupCommand { get; set; } + + public RelayCommand BrowseBackupLocationCommand { get; set; } + + public BackupViewVM() + { + BrowseBackupLocationCommand = new RelayCommand(BrowseBackupLocation); + BackupCommand = new RelayCommand(StartBackup); + IsBackupJobs = true; + } + + private async void StartBackup() + { + await NavigationManager.NavigateTo<BackupRestoreModule>(nameof(BackupProgressView)); + + if (IsFree) + { + IsFree = false; + await Task.Delay(10000); + IsFree = true; + } + } + + public override void OnApplicationStarted() + { + + } + + public override void OnApplicationReady() + { + base.OnApplicationReady(); + BackupManager.Progress += BackupManager_Progress; + } + + private void BackupManager_Progress(object sender, BackupRestoreProgressEventArgs e) + { + CurrentBackupProgress = e; + } + + private async void BrowseBackupLocation() + { + var result = await NavigationManager. + NavigateForResult<StorageModule, + Storage.Views.MainView, ExplorerFileItem, + Storage.Models.StorageNavigationRequest>( + new Storage.Models.StorageNavigationRequest() + { + Intent = Storage.Models.StorageNavigationIntent.SaveFile, + DefaultFileName = $"Tango-Backup-{DateTime.Now.ToFileName()}", + Filter = ExplorerFileDefinition.Backup.Extension, + Title = "Select Destination Backup File", + }); + + if (result != null) + { + BackupLocation = System.IO.Path.GetFileNameWithoutExtension(result.Path) + ExplorerFileDefinition.Backup.Extension; + } + } + + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/MainViewVM.cs new file mode 100644 index 000000000..989f8a6ee --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/MainViewVM.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tango.Core.Commands; +using Tango.Core.DI; +using Tango.Explorer; +using Tango.PPC.BackupRestore.Views; +using Tango.PPC.Common; +using Tango.PPC.Common.BackupRestore; +using Tango.PPC.Storage; + +namespace Tango.PPC.BackupRestore.ViewModels +{ + public class MainViewVM : PPCViewModel + { + public override void OnNavigatedFrom() + { + base.OnNavigatedFrom(); + } + + public override void OnNavigatedTo() + { + base.OnNavigatedTo(); + NavigationManager.NavigateTo<BackupRestoreModule>(nameof(WelcomeView), false); + } + + public override void OnApplicationStarted() + { + + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreViewVM.cs new file mode 100644 index 000000000..904fd9e52 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreViewVM.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tango.PPC.Common; + +namespace Tango.PPC.BackupRestore.ViewModels +{ + public class RestoreViewVM : PPCViewModel + { + public override void OnApplicationStarted() + { + + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/WelcomeViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/WelcomeViewVM.cs new file mode 100644 index 000000000..daddfeedc --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/WelcomeViewVM.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Tango.Core.Commands; +using Tango.PPC.BackupRestore.Views; +using Tango.PPC.Common; + +namespace Tango.PPC.BackupRestore.ViewModels +{ + public class WelcomeViewVM : PPCViewModel + { + public RelayCommand NavigateToBackupCommand { get; set; } + + public RelayCommand NavigateToRestoreCommand { get; set; } + + public WelcomeViewVM() + { + NavigateToBackupCommand = new RelayCommand(() => + { + NavigationManager.NavigateTo<BackupRestoreModule>(nameof(BackupView)); + }); + + NavigateToRestoreCommand = new RelayCommand(() => + { + NavigationManager.NavigateTo<BackupRestoreModule>(nameof(RestoreView)); + }); + } + + public override void OnApplicationStarted() + { + + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml new file mode 100644 index 000000000..53056e794 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml @@ -0,0 +1,38 @@ +<UserControl x:Class="Tango.PPC.BackupRestore.Views.BackupProgressView" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" + xmlns:vm="clr-namespace:Tango.PPC.BackupRestore.ViewModels" + xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:global="clr-namespace:Tango.PPC.BackupRestore" + xmlns:local="clr-namespace:Tango.PPC.BackupRestore.Views" + mc:Ignorable="d" + d:DesignHeight="700" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:BackupViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BackupViewVM}"> + + <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}"> + <DockPanel Margin="30 0 30 30"> + <Grid DockPanel.Dock="Top"> + <StackPanel> + <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> + <Run FontSize="{StaticResource TangoTitleFontSize}">Backing up your system</Run> + <LineBreak/> + <LineBreak/> + <Run>This process may take several minutes, please wait.</Run> + </TextBlock> + + + </StackPanel> + </Grid> + + <Grid> + <StackPanel VerticalAlignment="Center"> + <TextBlock Text="{Binding CurrentBackupProgress.Stage,Converter={StaticResource EnumToDescriptionConverter},FallbackValue='Backing up data'}" HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}"></TextBlock> + <touch:TouchProgressBar Margin="0 20" Height="10" IsIndeterminate="{Binding CurrentBackupProgress.IsIntermediate}" Maximum="{Binding CurrentBackupProgress.Total}" Value="{Binding CurrentBackupProgress.Progress,Mode=OneWay}" /> + </StackPanel> + </Grid> + + </DockPanel> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml.cs new file mode 100644 index 000000000..dd650f750 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.PPC.BackupRestore.Views +{ + /// <summary> + /// Interaction logic for BackupView.xaml + /// </summary> + public partial class BackupProgressView : UserControl + { + public BackupProgressView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml new file mode 100644 index 000000000..68c022766 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml @@ -0,0 +1,110 @@ +<UserControl x:Class="Tango.PPC.BackupRestore.Views.BackupView" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" + xmlns:vm="clr-namespace:Tango.PPC.BackupRestore.ViewModels" + xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:global="clr-namespace:Tango.PPC.BackupRestore" + xmlns:local="clr-namespace:Tango.PPC.BackupRestore.Views" + mc:Ignorable="d" + d:DesignHeight="700" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:BackupViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BackupViewVM}"> + + <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}"> + <DockPanel Margin="30 0 30 30"> + <Grid DockPanel.Dock="Bottom"> + <DockPanel> + <touch:TouchButton Command="{Binding BackupCommand}" HorizontalAlignment="Right" Height="80" Width="300" CornerRadius="40"> + <touch:TouchButton.Style> + <Style TargetType="touch:TouchButton" BasedOn="{StaticResource {x:Type touch:TouchButton}}"> + <Setter Property="Content" Value="START"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding IsFree}" Value="False"> + <Setter Property="Content" Value="IN PROGRESS"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </touch:TouchButton.Style> + </touch:TouchButton> + </DockPanel> + </Grid> + <StackPanel IsEnabled="{Binding IsFree}"> + <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> + <Run FontSize="{StaticResource TangoTitleFontSize}">Backup your system</Run> + <LineBreak/> + <LineBreak/> + <Run>Select whether you would like to backup your jobs or the entire system and press 'Start Backup'.</Run> + </TextBlock> + + <touch:TouchDropShadowBorder Padding="10" Margin="0 50 0 0"> + <StackPanel> + <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> + <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoPrimaryAccentBrush}">Backup Mode</TextBlock> + </StackPanel> + + <StackPanel Margin="0 20 0 0" TextElement.Foreground="{StaticResource TangoDarkForegroundBrush}" TextElement.FontSize="{StaticResource TangoTitleFontSize}"> + <StackPanel.Resources> + <Style TargetType="touch:TouchCheckBox" BasedOn="{StaticResource {x:Type touch:TouchCheckBox}}"> + <Setter Property="Margin" Value="0 0 0 10"></Setter> + <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter> + </Style> + + <Style x:Key="run" TargetType="Run"> + <Setter Property="Foreground" Value="{StaticResource TangoGrayTextBrush}"></Setter> + <Setter Property="FontSize" Value="{StaticResource TangoDefaultFontSize}"></Setter> + </Style> + </StackPanel.Resources> + <touch:TouchCheckBox IsChecked="{Binding IsBackupJobs,Mode=TwoWay}"> + <touch:TouchCheckBox.Content> + <TextBlock> + <Run>Jobs</Run> + <Run Style="{StaticResource run}">(create a backup of all your jobs)</Run> + </TextBlock> + </touch:TouchCheckBox.Content> + </touch:TouchCheckBox> + <touch:TouchCheckBox IsChecked="{Binding IsBackupFull,Mode=TwoWay}"> + <touch:TouchCheckBox.Content> + <TextBlock> + <Run>Full Backup</Run> + <Run Style="{StaticResource run}">(backup the entire state of the system)</Run> + </TextBlock> + </touch:TouchCheckBox.Content> + </touch:TouchCheckBox> + </StackPanel> + </StackPanel> + </touch:TouchDropShadowBorder> + + <touch:TouchDropShadowBorder Padding="10 10 10 20" Margin="0 10 0 0"> + <StackPanel> + <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> + <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoPrimaryAccentBrush}">Location</TextBlock> + </StackPanel> + + <StackPanel Margin="0 20 0 0"> + + <TextBlock>Please select the destination of your backup file</TextBlock> + <DockPanel Height="50" Margin="0 20 0 0"> + <touch:TouchButton Command="{Binding BrowseBackupLocationCommand}" Margin="20 0 0 0" Width="150" DockPanel.Dock="Right" Foreground="{StaticResource TangoDarkForegroundBrush}" BorderBrush="{StaticResource TangoDarkForegroundBrush}" Style="{StaticResource TangoHollowButton}">BROWSE</touch:TouchButton> + <touch:TouchTextBox Text="{Binding BackupLocation}" IsReadOnly="True" /> + </DockPanel> + </StackPanel> + </StackPanel> + </touch:TouchDropShadowBorder> + + <touch:TouchDropShadowBorder Padding="10" Margin="0 10 0 0"> + <StackPanel> + <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> + <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoPrimaryAccentBrush}">Name</TextBlock> + </StackPanel> + + <StackPanel Margin="0 20 0 0"> + <TextBlock>Please enter the name of your backup</TextBlock> + <touch:TouchTextBox Margin="0 20 0 0" Text="{Binding BackupName}" /> + </StackPanel> + </StackPanel> + </touch:TouchDropShadowBorder> + </StackPanel> + </DockPanel> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml.cs new file mode 100644 index 000000000..adc951f87 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.PPC.BackupRestore.Views +{ + /// <summary> + /// Interaction logic for BackupView.xaml + /// </summary> + public partial class BackupView : UserControl + { + public BackupView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml new file mode 100644 index 000000000..0f7667c4e --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml @@ -0,0 +1,32 @@ +<UserControl x:Class="Tango.PPC.BackupRestore.Views.MainView" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" + xmlns:vm="clr-namespace:Tango.PPC.BackupRestore.ViewModels" + xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:global="clr-namespace:Tango.PPC.BackupRestore" + xmlns:local="clr-namespace:Tango.PPC.BackupRestore.Views" + mc:Ignorable="d" + d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}"> + + <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}"> + <DockPanel> + <Grid DockPanel.Dock="Top"> + <StackPanel DockPanel.Dock="Top" HorizontalAlignment="Center" Margin="0 20 0 0"> + <Image Source="/Images/backup-restore.png" Stretch="Fill" Width="700" /> + </StackPanel> + </Grid> + + <controls:NavigationControl x:Name="navigationControl" TransitionType="Slide" TransitionDuration="00:00:0.2" KeepElementsAttached="True" Margin="0 20 0 0" SelectedIndex="0"> + + <local:WelcomeView/> + <local:BackupView/> + <local:RestoreView/> + <local:BackupProgressView/> + + </controls:NavigationControl> + </DockPanel> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml.cs new file mode 100644 index 000000000..e21bec0cb --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml.cs @@ -0,0 +1,30 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; +using Tango.Core.DI; +using static Tango.PPC.BackupRestore.ViewModels.MainViewVM; + +namespace Tango.PPC.BackupRestore.Views +{ + /// <summary> + /// Interaction logic for MainView.xaml + /// </summary> + public partial class MainView : UserControl + { + public MainView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml new file mode 100644 index 000000000..ef7dcbb58 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml @@ -0,0 +1,30 @@ +<UserControl x:Class="Tango.PPC.BackupRestore.Views.RestoreView" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" + xmlns:vm="clr-namespace:Tango.PPC.BackupRestore.ViewModels" + xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:global="clr-namespace:Tango.PPC.BackupRestore" + xmlns:local="clr-namespace:Tango.PPC.BackupRestore.Views" + mc:Ignorable="d" + d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:RestoreViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RestoreViewVM}"> + + <Grid> + <StackPanel HorizontalAlignment="Left" Margin="50 20 50 0"> + <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> + <Run FontSize="{StaticResource TangoTitleFontSize}">Restore your system</Run> + <LineBreak/> + <LineBreak/> + <Run>This wizard allows you to create a complete backup of your current machine state including software, firmware, data and user settings.</Run> + <LineBreak/> + <LineBreak/> + <LineBreak/> + <Run>For creating a complete backup of your system please press 'Backup'.</Run> + <LineBreak/> + <Run>In case you want to restore your system to a previous state, please press 'Restore'.</Run> + </TextBlock> + </StackPanel> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml.cs new file mode 100644 index 000000000..4df9146bb --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.PPC.BackupRestore.Views +{ + /// <summary> + /// Interaction logic for RestoreView.xaml + /// </summary> + public partial class RestoreView : UserControl + { + public RestoreView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml new file mode 100644 index 000000000..cf64b5bea --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml @@ -0,0 +1,72 @@ +<UserControl x:Class="Tango.PPC.BackupRestore.Views.WelcomeView" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" + xmlns:vm="clr-namespace:Tango.PPC.BackupRestore.ViewModels" + xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:global="clr-namespace:Tango.PPC.BackupRestore" + xmlns:local="clr-namespace:Tango.PPC.BackupRestore.Views" + mc:Ignorable="d" + d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:WelcomeViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.WelcomeViewVM}"> + + <UserControl.Resources> + <Style TargetType="touch:TouchButton" x:Key="ButtonMenu"> + <Setter Property="Padding" Value="10"></Setter> + <Setter Property="HorizontalContentAlignment" Value="Left"></Setter> + <Setter Property="Height" Value="140"></Setter> + <Setter Property="Background" Value="Transparent"></Setter> + <Setter Property="BorderBrush" Value="{StaticResource TangoDarkForegroundBrush}"></Setter> + <Setter Property="BorderThickness" Value="1"></Setter> + <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter> + <Setter Property="EnableDropShadow" Value="False"></Setter> + <Setter Property="CornerRadius" Value="5"></Setter> + <Setter Property="Margin" Value="0 0 0 20"></Setter> + <Setter Property="RippleBrush" Value="#4BB8B8B8"></Setter> + </Style> + </UserControl.Resources> + + <Grid controls:NavigationControl.NavigationName="MainView"> + <StackPanel HorizontalAlignment="Left" Margin="50 20 50 0"> + <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> + <Run FontSize="{StaticResource TangoTitleFontSize}">Welcome to the backup/restore wizard</Run> + <LineBreak/> + <LineBreak/> + <Run>This wizard allows you to create a complete backup of your current machine state including software, firmware, data and user settings.</Run> + <LineBreak/> + <LineBreak/> + <LineBreak/> + <Run>For creating a complete backup of your system please press 'Backup'.</Run> + <LineBreak/> + <Run>In case you want to restore your system to a previous state, please press 'Restore'.</Run> + </TextBlock> + </StackPanel> + + <StackPanel VerticalAlignment="Center" Margin="50 150 50 0"> + <touch:TouchButton Style="{StaticResource ButtonMenu}" Command="{Binding NavigateToBackupCommand}"> + <StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> + <Image Source="../Images/backup-big.png" Width="80" Height="80" /> + <StackPanel Margin="10 0 0 0"> + <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Backup</TextBlock> + <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Width="470" TextWrapping="Wrap"> + Create a complete backup of your system state and save it to a storage device. + </TextBlock> + </StackPanel> + </StackPanel> + </touch:TouchButton> + + <touch:TouchButton Style="{StaticResource ButtonMenu}" Command="{Binding NavigateToRestoreCommand}" CommandParameter="RestoreView"> + <StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> + <Image Source="../Images/restore.png" Width="80" Height="65" /> + <StackPanel Margin="10 0 0 0"> + <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Restore</TextBlock> + <TextBlock Foreground="{StaticResource TangoGrayTextBrush}"> + Restore your system from a previously saved backup file. + </TextBlock> + </StackPanel> + </StackPanel> + </touch:TouchButton> + </StackPanel> + </Grid> +</UserControl> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml.cs new file mode 100644 index 000000000..a7c347016 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.PPC.BackupRestore.Views +{ + /// <summary> + /// Interaction logic for WelcomeView.xaml + /// </summary> + public partial class WelcomeView : UserControl + { + public WelcomeView() + { + InitializeComponent(); + } + } +} diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/app.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/app.config new file mode 100644 index 000000000..1e22e6a88 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/app.config @@ -0,0 +1,61 @@ +<?xml version="1.0" encoding="utf-8"?> +<configuration> + <configSections> + <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 --> + <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false"/> + </configSections> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <assemblyIdentity name="System.Reactive.Core" publicKeyToken="94bc3704cddfc263" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-3.0.3000.0" newVersion="3.0.3000.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Collections.Immutable" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-1.2.2.0" newVersion="1.2.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Reflection.Metadata" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-1.4.2.0" newVersion="1.4.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.IO.FileSystem" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.ValueTuple" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.IO.Compression" publicKeyToken="b77a5c561934e089" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.IO.FileSystem.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Security.Cryptography.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Xml.XPath.XDocument" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Console" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="System.Diagnostics.StackTrace" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> + <bindingRedirect oldVersion="0.0.0.0-4.0.3.0" newVersion="4.0.3.0"/> + </dependentAssembly> + </assemblyBinding> + </runtime> + <entityFramework> + <defaultConnectionFactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework"/> + <providers> + <provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer"/> + </providers> + </entityFramework> +<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1"/></startup></configuration> diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/packages.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/packages.config new file mode 100644 index 000000000..80367fdd2 --- /dev/null +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/packages.config @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8"?> +<packages> + <package id="EntityFramework" version="6.0.0" targetFramework="net46" /> + <package id="Expression.Blend.Sdk" version="1.0.2" targetFramework="net46" /> + <package id="FontAwesome.WPF" version="4.7.0.9" targetFramework="net46" /> + <package id="Google.Protobuf" version="3.4.1" targetFramework="net46" /> +</packages>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Tango.PPC.Jobs.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Tango.PPC.Jobs.csproj index 6d5b62295..609a15de4 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Tango.PPC.Jobs.csproj +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Tango.PPC.Jobs.csproj @@ -489,7 +489,7 @@ <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <ProjectExtensions> <VisualStudio> - <UserProperties BuildVersion_StartDate="2000/1/1" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" /> + <UserProperties BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_StartDate="2000/1/1" /> </VisualStudio> </ProjectExtensions> </Project>
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupFile.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupFile.cs index 42e6fec42..4425aad9e 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupFile.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupFile.cs @@ -7,21 +7,58 @@ using Tango.Web; namespace Tango.PPC.Common.BackupRestore { + /// <summary> + /// Represents a backup file record. + /// </summary> public class BackupFile { + /// <summary> + /// Gets or sets the backup name. + /// </summary> public String Name { get; set; } + + /// <summary> + /// Gets or sets the creation date. + /// </summary> public DateTime Date { get; set; } + + /// <summary> + /// Gets or sets the machine serial number. + /// </summary> public String MachineSerialNumber { get; set; } + /// <summary> + /// Gets or sets the application version. + /// </summary> public String ApplicationVersion { get; set; } + + /// <summary> + /// Gets or sets the firmware version. + /// </summary> public String FirmwareVersion { get; set; } + + /// <summary> + /// Gets or sets the settings file. + /// </summary> public String SettingsFile { get; set; } + /// <summary> + /// Gets or sets the job files. + /// </summary> + public List<String> JobFiles { get; set; } + + /// <summary> + /// Gets or sets the backup settings. + /// </summary> public BackupSettings Settings { get; set; } + /// <summary> + /// Initializes a new instance of the <see cref="BackupFile"/> class. + /// </summary> public BackupFile() { Settings = new BackupSettings(); + JobFiles = new List<string>(); } } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupMode.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupMode.cs index 5e2f6d168..8533ce22a 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupMode.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupMode.cs @@ -6,7 +6,18 @@ using System.Threading.Tasks; namespace Tango.PPC.Common.BackupRestore { - class BackupMode + /// <summary> + /// Represents a backup mode. + /// </summary> + public enum BackupMode { + /// <summary> + /// Jobs only backup. + /// </summary> + Jobs, + /// <summary> + /// Complete backup of data, app binaries, firmware and settings file. + /// </summary> + Full, } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreEventArgs.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreEventArgs.cs deleted file mode 100644 index 402db821a..000000000 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreEventArgs.cs +++ /dev/null @@ -1,16 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace Tango.PPC.Common.BackupRestore -{ - public class BackupRestoreEventArgs : EventArgs - { - public bool IsIntermediate { get; set; } - public double Progress { get; set; } - public double MaxProgress { get; set; } - public BackupRestoreStage Stage { get; set; } - } -} diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreProgressEventArgs.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreProgressEventArgs.cs index 402db821a..9508755cb 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreProgressEventArgs.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreProgressEventArgs.cs @@ -6,11 +6,36 @@ using System.Threading.Tasks; namespace Tango.PPC.Common.BackupRestore { - public class BackupRestoreEventArgs : EventArgs + /// <summary> + /// Represents a backup restore procedure progress. + /// </summary> + /// <seealso cref="System.EventArgs" /> + public class BackupRestoreProgressEventArgs : EventArgs { + /// <summary> + /// Gets or sets a value indicating whether the progress is intermediate. + /// </summary> public bool IsIntermediate { get; set; } + + /// <summary> + /// Gets or sets the progress value. + /// </summary> public double Progress { get; set; } + + + /// <summary> + /// Gets or sets the maximum progress. + /// </summary> public double MaxProgress { get; set; } + + /// <summary> + /// Gets or sets the progress stage. + /// </summary> public BackupRestoreStage Stage { get; set; } + + /// <summary> + /// Gets or sets the message. + /// </summary> + public String Message { get; set; } } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreStage.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreStage.cs index 4ffad3c95..efef2d4d0 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreStage.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupRestoreStage.cs @@ -7,6 +7,9 @@ using System.Threading.Tasks; namespace Tango.PPC.Common.BackupRestore { + /// <summary> + /// Represents a backup restore procedure stage. + /// </summary> public enum BackupRestoreStage { [Description("Initializing")] diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupSettings.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupSettings.cs index d1225a609..b2021ba39 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupSettings.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/BackupSettings.cs @@ -6,11 +6,14 @@ using System.Threading.Tasks; namespace Tango.PPC.Common.BackupRestore { + /// <summary> + /// Represents a backup settings. + /// </summary> public class BackupSettings { - public bool IncludeDatabase { get; set; } - public bool IncludeApplication { get; set; } - public bool IncludeFirmware { get; set; } - public bool IncludeSettings { get; set; } + /// <summary> + /// Gets or sets the backup mode. + /// </summary> + public BackupMode Mode { get; set; } } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/IBackupManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/IBackupManager.cs index 60baceb5c..a50f0ab60 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/IBackupManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/BackupRestore/IBackupManager.cs @@ -6,12 +6,15 @@ using System.Threading.Tasks; namespace Tango.PPC.Common.BackupRestore { + /// <summary> + /// Represents a backup/restore manager. + /// </summary> public interface IBackupManager { /// <summary> /// Occurs when the backup/restore procedure makes progress. /// </summary> - event EventHandler<BackupRestoreEventArgs> Progress; + event EventHandler<BackupRestoreProgressEventArgs> Progress; /// <summary> /// Creates a backup file containing database, application and firmware versions. diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Navigation/NavigationView.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/Navigation/NavigationView.cs index ff9a99168..d8a1eec56 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Navigation/NavigationView.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Navigation/NavigationView.cs @@ -23,6 +23,5 @@ namespace Tango.PPC.Common.Navigation ShutdownView, RestartingSystemView, EmergencyView, - BackupRestoreView } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Tango.PPC.Common.csproj b/Software/Visual_Studio/PPC/Tango.PPC.Common/Tango.PPC.Common.csproj index 921dbe62b..83d5f7b98 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Tango.PPC.Common.csproj +++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Tango.PPC.Common.csproj @@ -120,7 +120,8 @@ <Link>GlobalVersionInfo.cs</Link> </Compile> <Compile Include="ApplicationStates.cs" /> - <Compile Include="BackupRestore\BackupRestoreEventArgs.cs" /> + <Compile Include="BackupRestore\BackupMode.cs" /> + <Compile Include="BackupRestore\BackupRestoreProgressEventArgs.cs" /> <Compile Include="BackupRestore\BackupFile.cs" /> <Compile Include="BackupRestore\BackupSettings.cs" /> <Compile Include="BackupRestore\BackupRestoreStage.cs" /> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/BackupRestore/DefaultBackupManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/BackupRestore/DefaultBackupManager.cs index 1eeb848ed..e73dde3ce 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/BackupRestore/DefaultBackupManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/BackupRestore/DefaultBackupManager.cs @@ -10,7 +10,7 @@ namespace Tango.PPC.UI.BackupRestore { public class DefaultBackupManager : IBackupManager { - public event EventHandler<BackupRestoreEventArgs> Progress; + public event EventHandler<BackupRestoreProgressEventArgs> Progress; public DefaultBackupManager(IPPCApplicationManager applicationManager) { @@ -29,7 +29,7 @@ namespace Tango.PPC.UI.BackupRestore protected virtual void OnProgress(BackupRestoreStage stage, double progress = 0, double maxProgress = 100, bool isIntermediate = true) { - Progress?.Invoke(this, new BackupRestoreEventArgs() + Progress?.Invoke(this, new BackupRestoreProgressEventArgs() { Stage = stage, Progress = progress, diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/error.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/error.png Binary files differnew file mode 100644 index 000000000..b4b50e4ac --- /dev/null +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/error.png diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/getting-ready.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/getting-ready.png Binary files differnew file mode 100644 index 000000000..a0dc77f92 --- /dev/null +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/getting-ready.png diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/service.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/service.png Binary files differnew file mode 100644 index 000000000..ba351ee66 --- /dev/null +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/service.png diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/shutting-down.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/shutting-down.png Binary files differnew file mode 100644 index 000000000..9aa8e2db6 --- /dev/null +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/GlobalStatus/shutting-down.png diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Navigation/DefaultNavigationManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Navigation/DefaultNavigationManager.cs index 77b09f638..fe4be700c 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Navigation/DefaultNavigationManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Navigation/DefaultNavigationManager.cs @@ -117,22 +117,22 @@ namespace Tango.PPC.UI.Navigation var fromView = MainView.Instance.NavigationControl.SelectedElement; FrameworkElement toView = null; - toView = MainView.Instance.NavigationControl.NavigateTo(view.ToString(),() => - { - var fromVM = toView.DataContext as PPCViewModel; + toView = MainView.Instance.NavigationControl.NavigateTo(view.ToString(), () => + { + var fromVM = toView.DataContext as PPCViewModel; - if (fromVM != null) - { - fromVM.OnNavigatedFrom(); - } + if (fromVM != null) + { + fromVM.OnNavigatedFrom(); + } - var toVM = toView.DataContext as PPCViewModel; + var toVM = toView.DataContext as PPCViewModel; - if (toVM != null) - { - toVM.OnNavigatedTo(); - } - }); + if (toVM != null) + { + toVM.OnNavigatedTo(); + } + }); return Task.FromResult(true); } @@ -251,16 +251,19 @@ namespace Tango.PPC.UI.Navigation { await Task.Delay(100); - var v = moduleNavigation.NavigateTo(view, () => + FrameworkElement v = null; + + v = moduleNavigation.NavigateTo(view, () => { - if (fromVM is PPCViewModel) + if (v != null) { - (fromVM as PPCViewModel)?.OnNavigatedFrom(); - } + var toVM = v.DataContext as PPCViewModel; - if (_currentVM is PPCViewModel) - { - (_currentVM as PPCViewModel)?.OnNavigatedTo(); + if (toVM != null) + { + (fromVM as PPCViewModel)?.OnNavigatedFrom(); + (toVM as PPCViewModel)?.OnNavigatedTo(); + } } }); @@ -284,6 +287,18 @@ namespace Tango.PPC.UI.Navigation } else { + await Task.Delay(500); + + if (fromVM is PPCViewModel) + { + (fromVM as PPCViewModel)?.OnNavigatedFrom(); + } + + if (_currentVM is PPCViewModel) + { + (_currentVM as PPCViewModel)?.OnNavigatedTo(); + } + NavigationCycleCompleted?.Invoke(fromVM, _currentVM); } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj b/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj index fd068bd61..ca7bad41e 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj @@ -155,7 +155,6 @@ <Compile Include="Printing\DefaultPrintingManager.cs" /> <Compile Include="Threading\DefaultDispatcherProvider.cs" /> <Compile Include="ViewModelLocator.cs" /> - <Compile Include="ViewModels\BackupRestoreViewVM.cs" /> <Compile Include="ViewModels\EmergencyViewVM.cs" /> <Compile Include="ViewModels\ExternalBridgeViewVM.cs" /> <Compile Include="ViewModels\LayoutViewVM.cs" /> @@ -167,13 +166,9 @@ <Compile Include="ViewModels\MachineUpdateViewVM.cs" /> <Compile Include="ViewModels\NoPermissionsViewVM.cs" /> <Compile Include="ViewModels\RestartingSystemViewVM.cs" /> - <Compile Include="ViewsContracts\IBackupRestoreView.cs" /> <Compile Include="ViewsContracts\ILayoutView.cs" /> <Compile Include="ViewsContracts\IMachineSetupView.cs" /> <Compile Include="ViewsContracts\IMachineUpdateView.cs" /> - <Compile Include="Views\BackupRestoreView.xaml.cs"> - <DependentUpon>BackupRestoreView.xaml</DependentUpon> - </Compile> <Compile Include="Views\ExternalBridgeView.xaml.cs"> <DependentUpon>ExternalBridgeView.xaml</DependentUpon> </Compile> @@ -259,10 +254,6 @@ <SubType>Designer</SubType> <Generator>MSBuild:Compile</Generator> </Page> - <Page Include="Views\BackupRestoreView.xaml"> - <SubType>Designer</SubType> - <Generator>MSBuild:Compile</Generator> - </Page> <Page Include="Views\ExternalBridgeView.xaml"> <SubType>Designer</SubType> <Generator>MSBuild:Compile</Generator> @@ -363,6 +354,10 @@ <Resource Include="Images\backup-restore.png" /> <Resource Include="Images\restore.png" /> <Resource Include="Images\backup-big.png" /> + <Resource Include="Images\GlobalStatus\getting-ready.png" /> + <Resource Include="Images\GlobalStatus\shutting-down.png" /> + <Resource Include="Images\GlobalStatus\error.png" /> + <Resource Include="Images\GlobalStatus\service.png" /> <Content Include="Manifests\release.xml" /> <Content Include="Manifests\debug.xml" /> <None Include="packages.config" /> @@ -447,6 +442,10 @@ <Project>{6aa425c9-ea6a-4b01-aaed-5ff122e8b663}</Project> <Name>Tango.WiFi</Name> </ProjectReference> + <ProjectReference Include="..\Modules\Tango.PPC.BackupRestore\Tango.PPC.BackupRestore.csproj"> + <Project>{bc2753f8-c0f7-48f5-a85c-149ec7a2f8c7}</Project> + <Name>Tango.PPC.BackupRestore</Name> + </ProjectReference> <ProjectReference Include="..\Modules\Tango.PPC.BugReporting\Tango.PPC.BugReporting.csproj"> <Project>{8146fa0a-0725-4a1a-82e6-696c58f33a2b}</Project> <Name>Tango.PPC.BugReporting</Name> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModelLocator.cs index 9fc482389..688a9b376 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModelLocator.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModelLocator.cs @@ -109,7 +109,6 @@ namespace Tango.PPC.UI TangoIOC.Default.Register<NoPermissionsViewVM>(); TangoIOC.Default.Register<RestartingSystemViewVM>(); TangoIOC.Default.Register<EmergencyViewVM>(); - TangoIOC.Default.Register<BackupRestoreViewVM>(); TangoIOC.Default.GetInstance<IPPCApplicationManager>().ContentRendered += (_, __) => @@ -117,7 +116,6 @@ namespace Tango.PPC.UI TangoIOC.Default.Register<ILayoutView, LayoutView>(LayoutView.Instance); TangoIOC.Default.Register<IMachineSetupView, MachineSetupView>(MachineSetupView.Instance); TangoIOC.Default.Register<IMachineUpdateView, MachineUpdateView>(MachineUpdateView.Instance); - TangoIOC.Default.Register<IBackupRestoreView, BackupRestoreView>(BackupRestoreView.Instance); }; //TangoIOC.Default.Register<LoadingViewVM>(); @@ -216,13 +214,5 @@ namespace Tango.PPC.UI return TangoIOC.Default.GetInstance<EmergencyViewVM>(); } } - - public static BackupRestoreViewVM BackupRestoreViewVM - { - get - { - return TangoIOC.Default.GetInstance<BackupRestoreViewVM>(); - } - } } }
\ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/BackupRestoreViewVM.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/BackupRestoreViewVM.cs deleted file mode 100644 index 416ece24b..000000000 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/BackupRestoreViewVM.cs +++ /dev/null @@ -1,91 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Tango.Core.Commands; -using Tango.Core.DI; -using Tango.PPC.Common; -using Tango.PPC.Common.BackupRestore; -using Tango.PPC.UI.ViewsContracts; - -namespace Tango.PPC.UI.ViewModels -{ - public class BackupRestoreViewVM : PPCViewModel<IBackupRestoreView> - { - private Stack<BackupRestoreView> _navigation_history; - private BackupRestoreView _currentView; - private bool _canNavigateBack; - - public enum BackupRestoreView - { - MainView, - BackupView, - RestoreView - } - - [TangoInject] - public IBackupManager BackupManager { get; set; } - - public RelayCommand<String> NavigateCommand { get; set; } - - public RelayCommand NavigateBackCommand { get; set; } - - public BackupRestoreViewVM() - { - NavigateCommand = new RelayCommand<string>(HandleNavigateCommand); - NavigateBackCommand = new RelayCommand(NavigateBack, () => _canNavigateBack); - - _navigation_history = new Stack<BackupRestoreView>(); - _canNavigateBack = true; - } - - public override void OnNavigatedTo() - { - base.OnNavigatedTo(); - - _navigation_history = new Stack<BackupRestoreView>(); - _currentView = BackupRestoreView.MainView; - } - - private void HandleNavigateCommand(string view) - { - var v = (BackupRestoreView)Enum.Parse(typeof(BackupRestoreView), view); - NavigateTo(v); - } - - private Task NavigateTo(BackupRestoreView view, bool pushHistory = true) - { - if (pushHistory) - { - _navigation_history.Push(_currentView); - } - - _currentView = view; - return View.NavigateTo(view); - } - - private async void NavigateBack() - { - _canNavigateBack = false; - InvalidateRelayCommands(); - - if (_navigation_history.Count > 0) - { - await NavigateTo(_navigation_history.Pop(), false); - } - else - { - await NavigationManager.NavigateBack(); - } - - _canNavigateBack = true; - InvalidateRelayCommands(); - } - - public override void OnApplicationStarted() - { - - } - } -} diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/LayoutViewVM.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/LayoutViewVM.cs index 0b530c278..9e8a9fe34 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/LayoutViewVM.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/LayoutViewVM.cs @@ -112,11 +112,6 @@ namespace Tango.PPC.UI.ViewModels public RelayCommand UpdateCommand { get; set; } /// <summary> - /// Gets or sets the backup restore command. - /// </summary> - public RelayCommand BackupRestoreCommand { get; set; } - - /// <summary> /// Gets or sets the power command. /// </summary> public RelayCommand PowerCommand { get; set; } @@ -151,12 +146,6 @@ namespace Tango.PPC.UI.ViewModels PowerCommand = new RelayCommand(() => IsPowerOpened = true); RestartApplicationCommand = new RelayCommand(RestartApplication); - - BackupRestoreCommand = new RelayCommand(() => - { - NavigationManager.NavigateTo(NavigationView.BackupRestoreView); - IsMenuOpened = false; - }); } #endregion diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml deleted file mode 100644 index ad8a5ca18..000000000 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml +++ /dev/null @@ -1,128 +0,0 @@ -<UserControl x:Class="Tango.PPC.UI.Views.BackupRestoreView" - xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" - xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" - xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" - xmlns:d="http://schemas.microsoft.com/expression/blend/2008" - xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" - xmlns:vm="clr-namespace:Tango.PPC.UI.ViewModels" - xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" - xmlns:global="clr-namespace:Tango.PPC.UI" - xmlns:local="clr-namespace:Tango.PPC.UI.Views" - mc:Ignorable="d" - d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:BackupRestoreViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BackupRestoreViewVM}"> - - <UserControl.Resources> - <Style TargetType="touch:TouchButton" x:Key="ButtonMenu"> - <Setter Property="Padding" Value="10"></Setter> - <Setter Property="HorizontalContentAlignment" Value="Left"></Setter> - <Setter Property="Height" Value="140"></Setter> - <Setter Property="Background" Value="Transparent"></Setter> - <Setter Property="BorderBrush" Value="{StaticResource TangoDarkForegroundBrush}"></Setter> - <Setter Property="BorderThickness" Value="1"></Setter> - <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter> - <Setter Property="EnableDropShadow" Value="False"></Setter> - <Setter Property="CornerRadius" Value="5"></Setter> - <Setter Property="Margin" Value="0 0 0 20"></Setter> - <Setter Property="RippleBrush" Value="#4BB8B8B8"></Setter> - </Style> - </UserControl.Resources> - - <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}"> - <DockPanel> - <Grid DockPanel.Dock="Top"> - <StackPanel DockPanel.Dock="Top" HorizontalAlignment="Center" Margin="0 20 0 0"> - <Image Source="/Images/backup-restore.png" Stretch="Fill" Width="700" /> - </StackPanel> - </Grid> - - <Grid DockPanel.Dock="Bottom" Margin="50 20"> - <touch:TouchButton Command="{Binding NavigateBackCommand}" HorizontalAlignment="Right" Height="60" Width="200" Style="{StaticResource TangoHollowButton}"> - <StackPanel Orientation="Horizontal"> - <touch:TouchIcon Margin="-30 0 30 0" Icon="ArrowLeft" /> - <TextBlock>Back</TextBlock> - </StackPanel> - </touch:TouchButton> - </Grid> - - <controls:NavigationControl x:Name="navigationControl" TransitionType="Slide" KeepElementsAttached="True" Margin="0 20 0 0" SelectedIndex="0"> - - <Grid controls:NavigationControl.NavigationName="MainView"> - <StackPanel HorizontalAlignment="Left" Margin="50 20 50 0"> - <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> - <Run FontSize="{StaticResource TangoTitleFontSize}">Welcome to the backup/restore wizard</Run> - <LineBreak/> - <LineBreak/> - <Run>This wizard allows you to create a complete backup of your current machine state including software, firmware, data and user settings.</Run> - <LineBreak/> - <LineBreak/> - <LineBreak/> - <Run>For creating a complete backup of your system please press 'Backup'.</Run> - <LineBreak/> - <Run>In case you want to restore your system to a previous state, please press 'Restore'.</Run> - </TextBlock> - </StackPanel> - - <StackPanel VerticalAlignment="Center" Margin="50 150 50 0"> - <touch:TouchButton Style="{StaticResource ButtonMenu}" Command="{Binding NavigateCommand}" CommandParameter="BackupView"> - <StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> - <Image Source="../Images/backup-big.png" Width="80" Height="80" /> - <StackPanel Margin="10 0 0 0"> - <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Backup</TextBlock> - <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Width="470" TextWrapping="Wrap"> - Create a complete backup of your system state and save it to a storage device. - </TextBlock> - </StackPanel> - </StackPanel> - </touch:TouchButton> - - <touch:TouchButton Style="{StaticResource ButtonMenu}" Command="{Binding NavigateCommand}" CommandParameter="RestoreView"> - <StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> - <Image Source="../Images/restore.png" Width="80" Height="65" /> - <StackPanel Margin="10 0 0 0"> - <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Restore</TextBlock> - <TextBlock Foreground="{StaticResource TangoGrayTextBrush}"> - Restore your system from a previously saved backup file. - </TextBlock> - </StackPanel> - </StackPanel> - </touch:TouchButton> - </StackPanel> - </Grid> - - <Grid controls:NavigationControl.NavigationName="BackupView"> - <StackPanel HorizontalAlignment="Left" Margin="50 20 50 0"> - <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> - <Run FontSize="{StaticResource TangoTitleFontSize}">Backup your system</Run> - <LineBreak/> - <LineBreak/> - <Run>This wizard allows you to create a complete backup of your current machine state including software, firmware, data and user settings.</Run> - <LineBreak/> - <LineBreak/> - <LineBreak/> - <Run>For creating a complete backup of your system please press 'Backup'.</Run> - <LineBreak/> - <Run>In case you want to restore your system to a previous state, please press 'Restore'.</Run> - </TextBlock> - </StackPanel> - </Grid> - - <Grid controls:NavigationControl.NavigationName="RestoreView"> - <StackPanel HorizontalAlignment="Left" Margin="50 20 50 0"> - <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}"> - <Run FontSize="{StaticResource TangoTitleFontSize}">Restore your system</Run> - <LineBreak/> - <LineBreak/> - <Run>This wizard allows you to create a complete backup of your current machine state including software, firmware, data and user settings.</Run> - <LineBreak/> - <LineBreak/> - <LineBreak/> - <Run>For creating a complete backup of your system please press 'Backup'.</Run> - <LineBreak/> - <Run>In case you want to restore your system to a previous state, please press 'Restore'.</Run> - </TextBlock> - </StackPanel> - </Grid> - </controls:NavigationControl> - </DockPanel> - </Grid> -</UserControl> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml.cs deleted file mode 100644 index 824bad9f0..000000000 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/BackupRestoreView.xaml.cs +++ /dev/null @@ -1,47 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows; -using System.Windows.Controls; -using System.Windows.Data; -using System.Windows.Documents; -using System.Windows.Input; -using System.Windows.Media; -using System.Windows.Media.Imaging; -using System.Windows.Navigation; -using System.Windows.Shapes; -using Tango.PPC.Common; -using Tango.PPC.UI.ViewModels; -using Tango.PPC.UI.ViewsContracts; - -namespace Tango.PPC.UI.Views -{ - /// <summary> - /// Interaction logic for BackupRestoreView.xaml - /// </summary> - public partial class BackupRestoreView : UserControl, IBackupRestoreView - { - public static BackupRestoreView Instance { get; internal set; } - - public BackupRestoreView() - { - InitializeComponent(); - - Instance = this; - } - - public Task NavigateTo(BackupRestoreViewVM.BackupRestoreView view) - { - TaskCompletionSource<object> source = new TaskCompletionSource<object>(); - - navigationControl.NavigateTo(view.ToString(), () => - { - source.SetResult(new object()); - }); - - return source.Task; - } - } -} diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml index fa6b8de7e..39c087c52 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml @@ -100,15 +100,6 @@ </StackPanel> </touch:TouchButton> </Border> - - <Border BorderBrush="{StaticResource TangoDividerBrush}" BorderThickness="0 0 0 1"> - <touch:TouchButton Style="{StaticResource TangoFlatButton}" Padding="40 25" Foreground="{StaticResource TangoDarkForegroundBrush}" Command="{Binding BackupRestoreCommand}"> - <StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> - <Image Source="/Images/Menu/backup.png" VerticalAlignment="Center" Width="32" Height="32"></Image> - <TextBlock VerticalAlignment="Center" Margin="40 0 0 0" Foreground="{StaticResource TangoPrimaryAccentBrush}">Backup/Restore</TextBlock> - </StackPanel> - </touch:TouchButton> - </Border> </StackPanel> </StackPanel> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MainView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MainView.xaml index 2119aebe7..443ca4f7a 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MainView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MainView.xaml @@ -7,6 +7,7 @@ xmlns:commonControls="clr-namespace:Tango.PPC.Common.Controls;assembly=Tango.PPC.Common" xmlns:vm="clr-namespace:Tango.PPC.UI.ViewModels" xmlns:global="clr-namespace:Tango.PPC.UI" + xmlns:operations="clr-namespace:Tango.Integration.Operation;assembly=Tango.Integration" xmlns:local="clr-namespace:Tango.PPC.UI.Views" xmlns:notifications="clr-namespace:Tango.PPC.UI.Notifications" xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" @@ -73,6 +74,40 @@ </DataTemplate> </ItemsControl.ItemTemplate> </ItemsControl> + + <Image Margin="10 0 0 0" Width="18" Height="18" VerticalAlignment="Center" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Setter Property="Source" Value="/Images/GlobalStatus/standby.png"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.Disconnected}"> + <Setter Property="Source" Value="/Images/GlobalStatus/machine-off.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.Standby}"> + <Setter Property="Source" Value="/Images/GlobalStatus/standby.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.ReadyToDye}"> + <Setter Property="Source" Value="/Images/GlobalStatus/ready-to-dye.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.GettingReady}"> + <Setter Property="Source" Value="/Images/GlobalStatus/getting-ready.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.Printing}"> + <Setter Property="Source" Value="/Images/GlobalStatus/dyeing.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.ShuttingDown}"> + <Setter Property="Source" Value="/Images/GlobalStatus/shutting-down.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.Error}"> + <Setter Property="Source" Value="/Images/GlobalStatus/error.png"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding Status}" Value="{x:Static operations:MachineStatuses.Service}"> + <Setter Property="Source" Value="/Images/GlobalStatus/service.png"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> <Grid></Grid> </DockPanel> </Border> @@ -89,7 +124,6 @@ <local:MachineUpdateView></local:MachineUpdateView> <local:RestartingSystemView></local:RestartingSystemView> <local:EmergencyView></local:EmergencyView> - <local:BackupRestoreView></local:BackupRestoreView> </controls:NavigationControl> </touch:TouchPanel> </Grid> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewsContracts/IBackupRestoreView.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewsContracts/IBackupRestoreView.cs deleted file mode 100644 index ef5f43eda..000000000 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewsContracts/IBackupRestoreView.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Tango.PPC.Common; -using static Tango.PPC.UI.ViewModels.BackupRestoreViewVM; - -namespace Tango.PPC.UI.ViewsContracts -{ - public interface IBackupRestoreView : IPPCView - { - /// <summary> - /// Navigates to the specified backup/restore view. - /// </summary> - /// <param name="view">The view.</param> - Task NavigateTo(BackupRestoreView view); - } -} diff --git a/Software/Visual_Studio/Tango.Explorer/ExplorerFileDefinition.cs b/Software/Visual_Studio/Tango.Explorer/ExplorerFileDefinition.cs index 5df1900a4..5b9fcba02 100644 --- a/Software/Visual_Studio/Tango.Explorer/ExplorerFileDefinition.cs +++ b/Software/Visual_Studio/Tango.Explorer/ExplorerFileDefinition.cs @@ -56,9 +56,16 @@ namespace Tango.Explorer Extension = ".tcc", }; + public static ExplorerFileDefinition Backup => new ExplorerFileDefinition() + { + Icon = ResourceHelper.GetImageFromResources("/Images/backup.png"), + Description = "Tango Backup File", + Extension = ".tb", + }; + static ExplorerFileDefinition() { - _definitions = typeof(ExplorerFileDefinition).GetProperties(BindingFlags.Public | BindingFlags.Static).Where(x => x.PropertyType == typeof(ExplorerFileDefinition)).ToList().Select(x => x.GetValue(null,null) as ExplorerFileDefinition).ToList(); + _definitions = typeof(ExplorerFileDefinition).GetProperties(BindingFlags.Public | BindingFlags.Static).Where(x => x.PropertyType == typeof(ExplorerFileDefinition)).ToList().Select(x => x.GetValue(null, null) as ExplorerFileDefinition).ToList(); } public static ExplorerFileDefinition GetByExtension(String ext) diff --git a/Software/Visual_Studio/Tango.Explorer/Images/backup.png b/Software/Visual_Studio/Tango.Explorer/Images/backup.png Binary files differnew file mode 100644 index 000000000..fab1fdb6d --- /dev/null +++ b/Software/Visual_Studio/Tango.Explorer/Images/backup.png diff --git a/Software/Visual_Studio/Tango.Explorer/Tango.Explorer.csproj b/Software/Visual_Studio/Tango.Explorer/Tango.Explorer.csproj index 10f3b929e..a39630940 100644 --- a/Software/Visual_Studio/Tango.Explorer/Tango.Explorer.csproj +++ b/Software/Visual_Studio/Tango.Explorer/Tango.Explorer.csproj @@ -111,5 +111,8 @@ <Resource Include="Images\pulse.png" /> <Resource Include="Images\update.png" /> </ItemGroup> + <ItemGroup> + <Resource Include="Images\backup.png" /> + </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> </Project>
\ No newline at end of file diff --git a/Software/Visual_Studio/Tango.SharedUI/Controls/NavigationControl.cs b/Software/Visual_Studio/Tango.SharedUI/Controls/NavigationControl.cs index b3869daff..71dc96774 100644 --- a/Software/Visual_Studio/Tango.SharedUI/Controls/NavigationControl.cs +++ b/Software/Visual_Studio/Tango.SharedUI/Controls/NavigationControl.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Collections.ObjectModel; using System.Linq; using System.Text; +using System.Threading; using System.Threading.Tasks; using System.Windows; using System.Windows.Controls; @@ -574,17 +575,25 @@ namespace Tango.SharedUI.Controls var element = Elements.SingleOrDefault(x => GetNavigationName(x) == navigationName || x.GetType().Name == navigationName); - if (element != null) + Task.Factory.StartNew(() => { - if (SelectedElement == element) - { - _onCompleted?.Invoke(); - } - else + Thread.Sleep(10); + + Dispatcher.BeginInvoke(new Action(() => { - SelectedElement = element; - } - } + if (element != null) + { + if (SelectedElement == element) + { + _onCompleted?.Invoke(); + } + else + { + SelectedElement = element; + } + } + })); + }); return element; } diff --git a/Software/Visual_Studio/Tango.Touch/Controls/TouchCheckBox.xaml b/Software/Visual_Studio/Tango.Touch/Controls/TouchCheckBox.xaml index 2e16aadd0..3ece097fa 100644 --- a/Software/Visual_Studio/Tango.Touch/Controls/TouchCheckBox.xaml +++ b/Software/Visual_Studio/Tango.Touch/Controls/TouchCheckBox.xaml @@ -35,6 +35,12 @@ </ControlTemplate> </Setter.Value> </Setter> + <Style.Triggers> + <Trigger Property="IsEnabled" Value="False"> + <Setter Property="BorderBrush" Value="{StaticResource TangoDisabledBackgroundBrush}"></Setter> + <Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter> + </Trigger> + </Style.Triggers> </Style> </ResourceDictionary>
\ No newline at end of file diff --git a/Software/Visual_Studio/Tango.sln b/Software/Visual_Studio/Tango.sln index c2dc16150..5acad1072 100644 --- a/Software/Visual_Studio/Tango.sln +++ b/Software/Visual_Studio/Tango.sln @@ -315,6 +315,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Tango.ColorLib_v3", "ColorL EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tango.PPC.Maintenance", "PPC\Modules\Tango.PPC.Maintenance\Tango.PPC.Maintenance.csproj", "{011470AC-6BD6-4366-B5F2-C82C065D4A84}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tango.PPC.BackupRestore", "PPC\Modules\Tango.PPC.BackupRestore\Tango.PPC.BackupRestore.csproj", "{BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution AppVeyor|Any CPU = AppVeyor|Any CPU @@ -5606,6 +5608,46 @@ Global {011470AC-6BD6-4366-B5F2-C82C065D4A84}.Release|x64.Build.0 = Release|Any CPU {011470AC-6BD6-4366-B5F2-C82C065D4A84}.Release|x86.ActiveCfg = Release|Any CPU {011470AC-6BD6-4366-B5F2-C82C065D4A84}.Release|x86.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|Any CPU.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|Any CPU.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|ARM.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|ARM.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|ARM64.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|ARM64.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|x64.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|x64.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|x86.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.AppVeyor|x86.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|Any CPU.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|ARM.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|ARM.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|ARM64.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|ARM64.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|x64.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|x64.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|x86.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Debug|x86.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|Any CPU.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|Any CPU.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|ARM.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|ARM.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|ARM64.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|ARM64.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|x64.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|x64.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|x86.ActiveCfg = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.DefaultBuild|x86.Build.0 = Debug|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|Any CPU.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|Any CPU.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|ARM.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|ARM.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|ARM64.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|ARM64.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|x64.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|x64.Build.0 = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|x86.ActiveCfg = Release|Any CPU + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -5708,14 +5750,15 @@ Global {1A3FC7FB-403C-4B3D-B705-28FCE11317DD} = {7181F9DE-0760-46B7-AD8F-BDBCAEDEF1B7} {A3A8ADA0-C150-4E30-A60D-11F291FDBF7A} = {7181F9DE-0760-46B7-AD8F-BDBCAEDEF1B7} {011470AC-6BD6-4366-B5F2-C82C065D4A84} = {0048447D-1D94-4E60-9DAD-7349C777CB4E} + {BC2753F8-C0F7-48F5-A85C-149EC7A2F8C7} = {0048447D-1D94-4E60-9DAD-7349C777CB4E} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {7986F7F4-A86A-4994-B1B6-0988D7F057B6} - BuildVersion_BuildVersioningStyle = None.None.Increment.DeltaBaseYearDayOfYear - BuildVersion_UpdateAssemblyVersion = True - BuildVersion_UpdateFileVersion = False - BuildVersion_StartDate = 2000/1/1 - BuildVersion_AssemblyInfoFilename = Properties\AssemblyInfo.cs BuildVersion_UseGlobalSettings = False + BuildVersion_AssemblyInfoFilename = Properties\AssemblyInfo.cs + BuildVersion_StartDate = 2000/1/1 + BuildVersion_UpdateFileVersion = False + BuildVersion_UpdateAssemblyVersion = True + BuildVersion_BuildVersioningStyle = None.None.Increment.DeltaBaseYearDayOfYear + SolutionGuid = {7986F7F4-A86A-4994-B1B6-0988D7F057B6} EndGlobalSection EndGlobal |
