aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2018-12-17 16:43:40 +0200
committerRoy Ben-Shabat <Roy@Twine-s.com>2018-12-17 16:43:40 +0200
commitae1cfd30f1efbd385eac04b3d02fa1ed161058a3 (patch)
tree5b77d7484e80491b06f1b726a57a61c782b5569e /Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
parent8270aa37dee33cda98603a995de823df393f7294 (diff)
downloadTango-ae1cfd30f1efbd385eac04b3d02fa1ed161058a3.tar.gz
Tango-ae1cfd30f1efbd385eac04b3d02fa1ed161058a3.zip
Add AppButtons to PPC.
Implemented Stop & Start job app buttons!
Diffstat (limited to 'Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs')
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
index 98f429889..6a05eee12 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
@@ -30,6 +30,7 @@ using Tango.PPC.Common.Models;
using Tango.Logging;
using Tango.PPC.Common.Messages;
using Tango.BL.Builders;
+using Tango.PPC.Jobs.AppButtons;
namespace Tango.PPC.Jobs.ViewModels
{
@@ -45,6 +46,7 @@ namespace Tango.PPC.Jobs.ViewModels
private Job _job_to_load;
private JobNavigationIntent _job_to_load_intent;
private static Dictionary<String, List<FineTuneItem>> _jobs_fine_tune_items;
+ private StartPrintingButton _start_printing_btn;
#region Properties
@@ -458,6 +460,8 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log("Directing view to display fine tuning region.");
View.DisplayFineTuning();
}
+
+ DyeCommand.RaiseCanExecuteChanged();
}
catch (Exception ex)
{
@@ -1017,6 +1021,8 @@ namespace Tango.PPC.Jobs.ViewModels
/// </summary>
public override void OnNavigatedTo()
{
+ _start_printing_btn.Push();
+
base.OnNavigatedTo();
LoadJob();
}
@@ -1026,6 +1032,8 @@ namespace Tango.PPC.Jobs.ViewModels
/// </summary>
public override void OnNavigatedFrom()
{
+ _start_printing_btn.Pop();
+
base.OnNavigatedFrom();
_job_to_load_intent = JobNavigationIntent.Default;
}
@@ -1055,6 +1063,12 @@ namespace Tango.PPC.Jobs.ViewModels
return result;
}
+ public override void OnApplicationReady()
+ {
+ base.OnApplicationReady();
+
+ _start_printing_btn = new StartPrintingButton(DyeCommand, MachineProvider.MachineOperator);
+ }
#endregion
#region INavigationObjectReceiver