From 37e5138e6acac4a9b93e018087fe9c50d36c4b34 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Thu, 30 Aug 2018 19:04:18 +0300 Subject: Implemented machine update on PPC !!! Need to verify update scripts... --- .../Tango.PPC.UI/Views/MachineUpdateView.xaml.cs | 46 ++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineUpdateView.xaml.cs (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineUpdateView.xaml.cs') diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineUpdateView.xaml.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineUpdateView.xaml.cs new file mode 100644 index 000000000..f63899932 --- /dev/null +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineUpdateView.xaml.cs @@ -0,0 +1,46 @@ +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.UI.ViewModels; +using Tango.PPC.UI.ViewsContracts; + +namespace Tango.PPC.UI.Views +{ + /// + /// Interaction logic for UpdateView.xaml + /// + public partial class MachineUpdateView : UserControl, IMachineUpdateView + { + public MachineUpdateView() + { + InitializeComponent(); + + Instance = this; + } + + public static MachineUpdateView Instance { get; internal set; } + + public Task NavigateTo(MachineUpdateViewVM.MachineUpdateView view) + { + TaskCompletionSource source = new TaskCompletionSource(); + + navigationControl.NavigateTo(view.ToString(), () => + { + source.SetResult(new object()); + }); + + return source.Task; + } + } +} -- cgit v1.3.1