aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj6
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs34
2 files changed, 36 insertions, 4 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
index 0bac2b355..c361a584d 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
@@ -268,6 +268,10 @@
<Project>{94f7acf8-55e1-4a02-b9bc-a818413fdbbf}</Project>
<Name>Tango.MachineStudio.DB</Name>
</ProjectReference>
+ <ProjectReference Include="..\Tango.MachineStudio.Logging\Tango.MachineStudio.Logging.csproj">
+ <Project>{1674f726-0e66-414f-b9fd-c6f20d7f07c7}</Project>
+ <Name>Tango.MachineStudio.Logging</Name>
+ </ProjectReference>
<ProjectReference Include="..\Tango.MachineStudio.MachineDesigner\Tango.MachineStudio.MachineDesigner.csproj">
<Project>{d0ce8122-077d-42a2-9490-028ae4769b52}</Project>
<Name>Tango.MachineStudio.MachineDesigner</Name>
@@ -359,7 +363,7 @@
<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" />
+ <UserProperties BuildVersion_StartDate="2000/1/1" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" />
</VisualStudio>
</ProjectExtensions>
</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
index 749a09023..0a033b118 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
@@ -39,6 +39,8 @@ using Tango.SharedUI.Helpers;
using Tango.Core.DI;
using Tango.MachineStudio.Common;
using Tango.BL.ColorConversion;
+using Tango.MachineStudio.Logging.ViewModels;
+using Tango.MachineStudio.Logging.Views;
namespace Tango.MachineStudio.Developer.ViewModels
{
@@ -68,6 +70,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
private Thread _colorConversionThread;
private bool _hiveOpened;
private bool _color_changed_from_hive;
+ private bool _dialog_shown;
#region Properties
@@ -491,6 +494,16 @@ namespace Tango.MachineStudio.Developer.ViewModels
set { _jobEvents = value; RaisePropertyChangedAuto(); }
}
+ private MachinesEvent _selectedJobEvent;
+ /// <summary>
+ /// Gets or sets the selected job event.
+ /// </summary>
+ public MachinesEvent SelectedJobEvent
+ {
+ get { return _selectedJobEvent; }
+ set { _selectedJobEvent = value; RaisePropertyChangedAuto(); OnSelectedJobEventChanged(); }
+ }
+
#endregion
#region Commands
@@ -798,7 +811,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
{
InvokeUI(() =>
{
- JobEvents.Add(e);
+ JobEvents.Insert(0, e);
});
}
}
@@ -1044,6 +1057,21 @@ namespace Tango.MachineStudio.Developer.ViewModels
#region Running Job Management
+ private void OnSelectedJobEventChanged()
+ {
+ if (SelectedJobEvent != null && SelectedJobEvent.Type != BL.Enumerations.EventTypes.ApplicationStarted && !_dialog_shown)
+ {
+ _dialog_shown = true;
+ _notification.ShowModalDialog<EventDetailsViewVM, EventDetailsView>(new EventDetailsViewVM(SelectedJobEvent), (x) =>
+ {
+
+ }, () =>
+ {
+ _dialog_shown = false;
+ });
+ }
+ }
+
/// <summary>
/// Closes the job completion status bar.
/// </summary>
@@ -1185,7 +1213,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
});
};
- _jobHandler.Finalizing += (_, __) =>
+ _jobHandler.Finalizing += (_, __) =>
{
_speech.SpeakInfo("Finalizing job...");
LogManager.Log(String.Format("Finalizing job {0}.", RunningJob.Name));
@@ -1401,7 +1429,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
Rmls = _activeJobDbContext.Rmls.ToObservableCollection();
WindingMethods = _activeJobDbContext.WindingMethods.ToObservableCollection();
SpoolTypes = _activeJobDbContext.SpoolTypes.ToObservableCollection();
-
+
LogManager.Log("Setting active job...");
_activeJob = _activeJobDbContext.Jobs.SingleOrDefault(x => x.Guid == SelectedMachineJob.Guid);