aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Modules
diff options
context:
space:
mode:
authorMirta <mirta@twine-s.com>2020-12-30 16:39:52 +0200
committerMirta <mirta@twine-s.com>2020-12-30 16:39:52 +0200
commit00a491d93733d4625ad329b2ba8237f445364b3f (patch)
tree4b24c6fa78d7648f4bb7cefafa464bb0b063fec4 /Software/Visual_Studio/PPC/Modules
parent124ad4150f80c6846fdee41dbbda9848c105f6e5 (diff)
downloadTango-00a491d9.tar.gz
Tango-00a491d9.zip
merge
Diffstat (limited to 'Software/Visual_Studio/PPC/Modules')
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml11
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs84
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-big.pngbin3044 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-restore.pngbin89496 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/restore.pngbin3252 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/AssemblyInfo.cs20
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.Designer.cs63
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.resx117
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.Designer.cs26
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.settings7
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Tango.PPC.BackupRestore.csproj246
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModelLocator.cs95
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupCompletedViewVM.cs20
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupErrorViewVM.cs37
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupViewVM.cs163
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/MainViewVM.cs34
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreCompletedViewVM.cs51
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreErrorViewVM.cs38
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreViewVM.cs168
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/WelcomeViewVM.cs48
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml37
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml39
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml38
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml99
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml39
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml37
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml39
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml38
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml160
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml72
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/app.config61
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/packages.config7
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/App.xaml11
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Attributes/BoundObjectAttribute.cs20
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BoundsObjects/KeyboardHandler.cs66
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BrowserModule.cs101
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/CefSharpOutput.zipbin143444091 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Helpers/BoundObjectsHelper.cs72
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Images/browser.pngbin2539 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Navigation/BrowserNavigationRequest.cs19
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/AssemblyInfo.cs20
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.Designer.cs63
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.resx117
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.Designer.cs26
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.settings7
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/RequestHandlers/ChromiumRequestHandler.cs114
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Scripts/keyboard.js21
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Tango.PPC.Browser.csproj199
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewContracts/IBrowserView.cs18
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModelLocator.cs32
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModels/BrowserViewVM.cs134
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml77
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml.cs211
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml23
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml.cs29
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/app.config90
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/packages.config11
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/BugReportingModule.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/TFS/TeamFoundationServicePPCClient.cs73
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/Tango.PPC.BugReporting_txujxqrg_wpftmp.csproj235
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/ViewModelLocator.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Converters/MachineEventToViewConverter.cs7
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml26
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml.cs49
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Resources/Styles.xaml4
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Tango.PPC.Events.csproj9
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/ViewModels/MainViewVM.cs32
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Views/MainView.xaml8
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppBarItems/JobProgressAppBarItemView.xaml5
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppButtons/StartPrintingButton.cs4
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobOutlineControl.cs319
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobSummeryViewer.xaml3
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/RunningJobViewer.xaml3
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Converters/ColorSpaceToVisibilityConverter.cs12
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml68
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionViewVM.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/BasicColorCorrectionView.xaml9
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/CatalogSelectionView.xaml2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/ImportJobView.xaml2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent.jpgbin27097 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent_small.jpgbin10743 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/color-picker.pngbin1171 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync.pngbin4127 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync_job.pngbin6743 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItem.cs32
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Tango.PPC.Jobs.csproj26
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobProgressViewVM.cs108
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobSummeryViewVM.cs37
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs149
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobsViewVM.cs186
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/MainViewVM.cs66
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobProgressView.xaml138
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobSummeryView.xaml2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml321
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml.cs16
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobsView.xaml14
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs229
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml186
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/App.xaml11
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/HomingMotorCommand.cs80
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseDyeingHeadCommand.cs31
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseLeftLeadingWheelsCommand.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseMotorCommand.cs158
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseRightLeadingWheelsCommand.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/ResetThreadLoadingCommand.cs24
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Controls/StateTouchButton.cs109
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToBrushConverter.cs74
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToShortNameConverter.cs41
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/MidTankLevelToElementHeightConverter.cs34
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/StringToFirstLetterConverter.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml66
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingViewVM.cs128
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml56
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningViewVM.cs150
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideBase.cs35
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideStep.cs21
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/HandleWasteCartridgeGuide.cs43
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadInkCartridgeGuide.cs43
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadNewThreadGuide.cs43
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceAirFilterGuide.cs43
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceThreadGuide.cs43
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Helpers/GuideHelper.cs33
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-New-Thread.gifbin4092741 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-an-Ink-Cartridge.gifbin4197318 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Air-Filter.gifbin3500573 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Thread.gifbin13319358 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Residue-Cartridges-A.gifbin3567850 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/handling-the-waste-cartridges.pngbin2174 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-an-ink-cartridge.pngbin2266 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-new-thread.pngbin2228 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image.pngbin138220 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-air-filter.pngbin2269 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-thread.pngbin2175 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/absent.pngbin892 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_error.pngbin1440 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_right.pngbin1497 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_full_right.pngbin2035 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/action.pngbin1152 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cl-full.pngbin3454 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-empty.pngbin4125 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-full.pngbin3018 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/guides.pngbin2099 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/head_cleaning.pngbin44260 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/inks.pngbin2075 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/l-full.pngbin19717 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/lubricant2.pngbin194234 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/maintenance.pngbin686 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/status.pngbin1663 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-green.pngbin926 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-red.pngbin928 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-yellow.pngbin927 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/thread_loading.pngbin7209 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceCommand.cs81
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceModule.cs84
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/MidTankLevelModel.cs35
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/OverallTemperatureModel.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/AssemblyInfo.cs20
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.Designer.cs63
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.resx117
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.Designer.cs26
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.settings7
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Resources/Guides.xaml60
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj320
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Themes/Generic.xaml9
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModelLocator.cs56
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/GeneralGuideViewVM.cs40
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MainViewVM.cs31
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs324
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml55
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml.cs33
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml22
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml341
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml.cs30
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/app.config61
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/packages.config11
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Models/StorageNavigationIntent.cs4
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/StorageModule.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs60
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Views/MainView.xaml70
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml80
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsViewVM.cs21
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml74
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsViewVM.cs22
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml87
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsViewVM.cs21
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/browser.pngbin2539 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/circuit-board.pngbin2492 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/conveyor.pngbin4349 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/exit.pngbin1784 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/mobile-phone.pngbin4438 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/packages.pngbin1781 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/remote_connections.pngbin4186 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/shutdown.pngbin3703 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/sync.pngbin4127 -> 0 bytes
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Tango.PPC.Technician.csproj71
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModelLocator.cs36
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/CatalogViewVM.cs23
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/LoggingViewVM.cs125
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/MainViewVM.cs4
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/PackagesViewVM.cs44
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/RemoteConnectionsViewVM.cs64
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/SystemViewVM.cs87
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/UpdatesViewVM.cs107
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/CatalogView.xaml130
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/LoggingView.xaml178
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/MainView.xaml3
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml103
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml88
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml.cs28
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/SystemView.xaml313
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml160
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml.cs28
232 files changed, 604 insertions, 10942 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml
deleted file mode 100644
index 595ed2299..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/App.xaml
+++ /dev/null
@@ -1,11 +0,0 @@
-<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/BackupRestoreModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs
deleted file mode 100644
index 25cdfbb27..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/BackupRestoreModule.cs
+++ /dev/null
@@ -1,84 +0,0 @@
-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
deleted file mode 100644
index 3a712af49..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-big.png
+++ /dev/null
Binary files differ
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
deleted file mode 100644
index 15be3b163..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/backup-restore.png
+++ /dev/null
Binary files differ
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
deleted file mode 100644
index e60aaf425..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Images/restore.png
+++ /dev/null
Binary files differ
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
deleted file mode 100644
index ac385e0ba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/AssemblyInfo.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-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
deleted file mode 100644
index 160bdf95c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.Designer.cs
+++ /dev/null
@@ -1,63 +0,0 @@
-//------------------------------------------------------------------------------
-// <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
deleted file mode 100644
index af7dbebba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-<?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
deleted file mode 100644
index 087ecdbcd..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.Designer.cs
+++ /dev/null
@@ -1,26 +0,0 @@
-//------------------------------------------------------------------------------
-// <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
deleted file mode 100644
index 033d7a5e9..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Properties/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-<?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
deleted file mode 100644
index 99ac13ae4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Tango.PPC.BackupRestore.csproj
+++ /dev/null
@@ -1,246 +0,0 @@
-<?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\RestoreCompletedView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\BackupCompletedView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\RestoreErrorView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\BackupErrorView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\RestoreProgressView.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\RestoreCompletedViewVM.cs" />
- <Compile Include="ViewModels\RestoreErrorViewVM.cs" />
- <Compile Include="ViewModels\BackupViewVM.cs" />
- <Compile Include="ViewModels\BackupCompletedViewVM.cs" />
- <Compile Include="ViewModels\BackupErrorViewVM.cs" />
- <Compile Include="ViewModels\MainViewVM.cs" />
- <Compile Include="ViewModels\RestoreViewVM.cs" />
- <Compile Include="ViewModels\WelcomeViewVM.cs" />
- <Compile Include="Views\RestoreCompletedView.xaml.cs">
- <DependentUpon>RestoreCompletedView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\BackupCompletedView.xaml.cs">
- <DependentUpon>BackupCompletedView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\RestoreErrorView.xaml.cs">
- <DependentUpon>RestoreErrorView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\BackupErrorView.xaml.cs">
- <DependentUpon>BackupErrorView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\RestoreProgressView.xaml.cs">
- <DependentUpon>RestoreProgressView.xaml</DependentUpon>
- </Compile>
- <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
deleted file mode 100644
index 698a70cd7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModelLocator.cs
+++ /dev/null
@@ -1,95 +0,0 @@
-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>();
- TangoIOC.Default.Register<BackupErrorViewVM>();
- TangoIOC.Default.Register<BackupCompletedViewVM>();
- TangoIOC.Default.Register<RestoreErrorViewVM>();
- TangoIOC.Default.Register<RestoreCompletedViewVM>();
- }
-
- /// <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>();
- }
- }
-
- public static BackupErrorViewVM BackupErrorViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<BackupErrorViewVM>();
- }
- }
-
- public static BackupCompletedViewVM BackupCompletedViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<BackupCompletedViewVM>();
- }
- }
-
- public static RestoreErrorViewVM RestoreErrorViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<RestoreErrorViewVM>();
- }
- }
-
- public static RestoreCompletedViewVM RestoreCompletedViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<RestoreCompletedViewVM>();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupCompletedViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupCompletedViewVM.cs
deleted file mode 100644
index 8c40bf288..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupCompletedViewVM.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common;
-using Tango.PPC.Common.BackupRestore;
-using Tango.PPC.Common.Navigation;
-using static Tango.PPC.BackupRestore.ViewModels.BackupCompletedViewVM;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class BackupCompletedViewVM : PPCViewModel
- {
- public override void OnApplicationStarted()
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupErrorViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupErrorViewVM.cs
deleted file mode 100644
index 42f2c9e51..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupErrorViewVM.cs
+++ /dev/null
@@ -1,37 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common;
-using Tango.PPC.Common.BackupRestore;
-using Tango.PPC.Common.Navigation;
-using static Tango.PPC.BackupRestore.ViewModels.BackupErrorViewVM;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class BackupErrorViewVM : PPCViewModel, INavigationObjectReceiver<BackupErrorNavigationObject>
- {
- public class BackupErrorNavigationObject
- {
- public String Error { get; set; }
- }
-
- private String _error;
- public String Error
- {
- get { return _error; }
- set { _error = value; RaisePropertyChangedAuto(); }
- }
-
- public override void OnApplicationStarted()
- {
-
- }
-
- public void OnNavigatedToWithObject(BackupErrorNavigationObject obj)
- {
- Error = obj.Error;
- }
- }
-}
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
deleted file mode 100644
index ef5b3810c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/BackupViewVM.cs
+++ /dev/null
@@ -1,163 +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.Explorer;
-using Tango.PPC.BackupRestore.Views;
-using Tango.PPC.Common;
-using Tango.PPC.Common.BackupRestore;
-using Tango.PPC.Storage;
-using static Tango.PPC.BackupRestore.ViewModels.BackupErrorViewVM;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class BackupViewVM : PPCViewModel
- {
- private String _backupFileName;
-
- [TangoInject]
- public IBackupManager BackupManager { 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(); InvalidateRelayCommands(); }
- }
-
- private String _backupName;
- public String BackupName
- {
- get { return _backupName; }
- set { _backupName = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- public RelayCommand BackupCommand { get; set; }
-
- public RelayCommand BrowseBackupLocationCommand { get; set; }
-
- public BackupViewVM()
- {
- BrowseBackupLocationCommand = new RelayCommand(BrowseBackupLocation);
- BackupCommand = new RelayCommand(StartBackup, () => !String.IsNullOrWhiteSpace(BackupName) && BackupLocation != null);
- IsBackupJobs = true;
- }
-
- private async void StartBackup()
- {
- await NavigationManager.NavigateTo<BackupRestoreModule>(nameof(BackupProgressView), false);
-
- try
- {
- IsFree = false;
- NavigationManager.IsBackEnabled = false;
- await BackupManager.CreateBackup(_backupFileName, BackupName, new BackupSettings()
- {
- Mode = IsBackupFull ? BackupMode.Full : BackupMode.Jobs,
- });
- await NavigationManager.NavigateTo<BackupRestoreModule>(nameof(BackupCompletedView), false);
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "The backup operation failed.");
-
- await NavigationManager.NavigateWithObject<BackupRestoreModule, BackupErrorView, BackupErrorNavigationObject>(new BackupErrorNavigationObject()
- {
- Error = ex.FlattenMessage(),
- }, false);
- }
- finally
- {
- IsFree = true;
- NavigationManager.IsBackEnabled = 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)
- {
- _backupFileName = result.Path + ExplorerFileDefinition.Backup.Extension;
- BackupLocation = 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
deleted file mode 100644
index 989f8a6ee..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/MainViewVM.cs
+++ /dev/null
@@ -1,34 +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.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/RestoreCompletedViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreCompletedViewVM.cs
deleted file mode 100644
index d773aa5d4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreCompletedViewVM.cs
+++ /dev/null
@@ -1,51 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core.Commands;
-using Tango.Core.Helpers;
-using Tango.PPC.Common;
-using Tango.PPC.Common.BackupRestore;
-using Tango.PPC.Common.Navigation;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class RestoreCompletedViewVM : PPCViewModel, INavigationObjectReceiver<RestoreResult>
- {
- private RestoreResult _restoreResult;
-
- public RelayCommand RestartCommand { get; set; }
-
- public RestoreCompletedViewVM()
- {
- RestartCommand = new RelayCommand(Restart);
- }
-
- private void Restart()
- {
- if (_restoreResult.BackupFile.Settings.Mode == BackupMode.Jobs)
- {
- //Perform normal restart.
- ApplicationManager.Restart();
- }
- else
- {
- //Perform update restart using the result path.
- String updater_exe = Path.Combine(_restoreResult.FolderPath, "Tango.PPC.Updater.exe");
- ApplicationManager.UpdateApplication(updater_exe, PathHelper.GetStartupPath());
- }
- }
-
- public override void OnApplicationStarted()
- {
-
- }
-
- public void OnNavigatedToWithObject(RestoreResult restoreResult)
- {
- _restoreResult = restoreResult;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreErrorViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreErrorViewVM.cs
deleted file mode 100644
index b6df53318..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreErrorViewVM.cs
+++ /dev/null
@@ -1,38 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.BackupRestore.Views;
-using Tango.PPC.Common;
-using Tango.PPC.Common.BackupRestore;
-using Tango.PPC.Common.Navigation;
-using static Tango.PPC.BackupRestore.ViewModels.RestoreErrorViewVM;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class RestoreErrorViewVM : PPCViewModel, INavigationObjectReceiver<RestoreErrorNavigationObject>
- {
- public class RestoreErrorNavigationObject
- {
- public String Error { get; set; }
- }
-
- private String _error;
- public String Error
- {
- get { return _error; }
- set { _error = value; RaisePropertyChangedAuto(); }
- }
-
- public override void OnApplicationStarted()
- {
-
- }
-
- public void OnNavigatedToWithObject(RestoreErrorNavigationObject obj)
- {
- Error = obj.Error;
- }
- }
-}
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
deleted file mode 100644
index d925ebad1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/RestoreViewVM.cs
+++ /dev/null
@@ -1,168 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.IO;
-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;
-using static Tango.PPC.BackupRestore.ViewModels.RestoreErrorViewVM;
-
-namespace Tango.PPC.BackupRestore.ViewModels
-{
- public class RestoreViewVM : PPCViewModel
- {
- private string _backupFileLocation;
- private bool _isBrowsing;
-
- [TangoInject]
- public IBackupManager BackupManager { get; set; }
-
- private String _backupFileName;
- public String BackupFileName
- {
- get { return _backupFileName; }
- set { _backupFileName = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private RestoreSettings _restoreSettings;
- public RestoreSettings RestoreSettings
- {
- get { return _restoreSettings; }
- set { _restoreSettings = value; RaisePropertyChangedAuto(); }
- }
-
- private BackupFile _backupFile;
- public BackupFile BackupFile
- {
- get { return _backupFile; }
- set { _backupFile = value; RaisePropertyChangedAuto(); }
- }
-
- private BackupRestoreProgressEventArgs _currentRestoreProgress;
- public BackupRestoreProgressEventArgs CurrentRestoreProgress
- {
- get { return _currentRestoreProgress; }
- set { _currentRestoreProgress = value; RaisePropertyChangedAuto(); }
- }
-
- private long _backupSize;
- public long BackupSize
- {
- get { return _backupSize; }
- set { _backupSize = value; RaisePropertyChangedAuto(); }
- }
-
- public RelayCommand BrowseForBackupCommand { get; set; }
-
- public RelayCommand RestoreCommand { get; set; }
-
- public RestoreViewVM()
- {
- RestoreSettings = new RestoreSettings();
- RestoreCommand = new RelayCommand(StartRestore, () => BackupFileName != null);
- BrowseForBackupCommand = new RelayCommand(BrowseForBackup);
- }
-
- private async void StartRestore()
- {
- await NavigationManager.NavigateTo<BackupRestoreModule>(nameof(RestoreProgressView), false);
-
- try
- {
- IsFree = false;
- NavigationManager.IsBackEnabled = false;
- var result = await BackupManager.Restore(_backupFileLocation, RestoreSettings);
- await NavigationManager.NavigateWithObject<BackupRestoreModule, RestoreCompletedView, RestoreResult>(result, false);
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "The restore operation failed.");
-
- await NavigationManager.NavigateWithObject<BackupRestoreModule, RestoreErrorView, RestoreErrorNavigationObject>(new RestoreErrorNavigationObject()
- {
- Error = ex.FlattenMessage(),
- }, false);
-
- NavigationManager.IsBackEnabled = true;
- }
- finally
- {
- IsFree = true;
- }
- }
-
- private async void BrowseForBackup()
- {
- _isBrowsing = true;
-
- var result = await NavigationManager.
- NavigateForResult<StorageModule,
- Storage.Views.MainView, ExplorerFileItem,
- Storage.Models.StorageNavigationRequest>(
- new Storage.Models.StorageNavigationRequest()
- {
- Intent = Storage.Models.StorageNavigationIntent.LoadFile,
- Filter = ExplorerFileDefinition.Backup.Extension,
- Title = "Select Backup File",
- });
-
- _isBrowsing = false;
-
- if (result != null)
- {
- _backupFileLocation = result.Path;
-
- try
- {
- BackupFile = await BackupManager.ExtractBackupConfiguration(_backupFileLocation);
- BackupFileName = Path.GetFileName(result.Path);
- BackupSize = new System.IO.FileInfo(_backupFileLocation).Length;
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, $"Error extracting backup configuration from file '{_backupFileLocation}'.");
- await NotificationProvider.ShowError($"Error occurred while trying to extract the backup file information\n{ex.FlattenMessage()}");
- }
- }
- }
-
- public override Task<bool> OnNavigateBackRequest()
- {
- return Task.FromResult(IsFree);
- }
-
- public override void OnNavigatedFrom()
- {
- base.OnNavigatedFrom();
-
- if (!_isBrowsing)
- {
- BackupFileName = null;
- BackupFile = null;
- _backupFileLocation = null;
- }
- }
-
- public override void OnApplicationReady()
- {
- base.OnApplicationReady();
- BackupManager.Progress += BackupManager_Progress;
- }
-
- private void BackupManager_Progress(object sender, BackupRestoreProgressEventArgs e)
- {
- CurrentRestoreProgress = e;
- }
-
- 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
deleted file mode 100644
index 4fbac321e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/ViewModels/WelcomeViewVM.cs
+++ /dev/null
@@ -1,48 +0,0 @@
-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()
- {
-
- }
-
- public override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
- NotificationProvider.NotificationsVisible = false;
- }
-
- public override Task<bool> OnNavigateBackRequest()
- {
- NotificationProvider.NotificationsVisible = true;
- return base.OnNavigateBackRequest();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml
deleted file mode 100644
index 470c16256..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml
+++ /dev/null
@@ -1,37 +0,0 @@
-<UserControl x:Class="Tango.PPC.BackupRestore.Views.BackupCompletedView"
- 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:BackupCompletedViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BackupCompletedViewVM}">
-
- <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}" Foreground="{StaticResource TangoSuccessBrush}">Backup completed</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>The backup operation was completed successfully.</Run>
- </TextBlock>
- </StackPanel>
- </Grid>
-
- <Grid DockPanel.Dock="Bottom">
-
- </Grid>
-
- <Grid>
-
- </Grid>
-
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml.cs
deleted file mode 100644
index 2a9779ed1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupCompletedView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.BackupRestore.Views
-{
- /// <summary>
- /// Interaction logic for BackupView.xaml
- /// </summary>
- public partial class BackupCompletedView : UserControl
- {
- public BackupCompletedView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml
deleted file mode 100644
index b54694a50..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml
+++ /dev/null
@@ -1,39 +0,0 @@
-<UserControl x:Class="Tango.PPC.BackupRestore.Views.BackupErrorView"
- 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:BackupErrorViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BackupErrorViewVM}">
-
- <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}" Foreground="{StaticResource TangoErrorBrush}">Backup failed</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>The backup operation has failed due to the following reason.</Run>
- </TextBlock>
- </StackPanel>
- </Grid>
-
- <Grid DockPanel.Dock="Bottom">
-
- </Grid>
-
- <Grid>
- <TextBlock Text="{Binding Error}" Margin="0 10 0 0" Height="Auto" TextWrapping="Wrap" Foreground="{StaticResource TangoGrayTextBrush}">
-
- </TextBlock>
- </Grid>
-
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml.cs
deleted file mode 100644
index cf050140d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupErrorView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.BackupRestore.Views
-{
- /// <summary>
- /// Interaction logic for BackupView.xaml
- /// </summary>
- public partial class BackupErrorView : UserControl
- {
- public BackupErrorView()
- {
- InitializeComponent();
- }
- }
-}
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
deleted file mode 100644
index 7785c1c0f..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml
+++ /dev/null
@@ -1,38 +0,0 @@
-<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.MaxProgress}" 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
deleted file mode 100644
index dd650f750..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupProgressView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-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
deleted file mode 100644
index 2a72f9788..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml
+++ /dev/null
@@ -1,99 +0,0 @@
-<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" Content="START"/>
- </DockPanel>
- </Grid>
- <StackPanel IsEnabled="{Binding IsFree}">
- <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}">
- <Run FontSize="{StaticResource TangoTitleFontSize}">Backup your system</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>Please specify the location and settings of your backup and press 'START'.</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:TouchRadioButton IsChecked="{Binding IsBackupJobs,Mode=TwoWay}">
- <touch:TouchRadioButton.Content>
- <TextBlock>
- <Run>Jobs</Run>
- <Run Style="{StaticResource run}">(create a backup of all your jobs)</Run>
- </TextBlock>
- </touch:TouchRadioButton.Content>
- </touch:TouchRadioButton>
- <touch:TouchRadioButton IsChecked="{Binding IsBackupFull,Mode=TwoWay}" Margin="0 5 0 0">
- <touch:TouchRadioButton.Content>
- <TextBlock>
- <Run>Full Backup</Run>
- <Run Style="{StaticResource run}">(backup the entire state of the system)</Run>
- </TextBlock>
- </touch:TouchRadioButton.Content>
- </touch:TouchRadioButton>
- </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}">SELECT</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}" KeyboardContainer="{Binding RelativeSource={RelativeSource AncestorType=touch:TouchKeyboardContainer}}" />
- </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
deleted file mode 100644
index adc951f87..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/BackupView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-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
deleted file mode 100644
index 0caabd0e1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml
+++ /dev/null
@@ -1,39 +0,0 @@
-<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}">
-
- <touch:TouchKeyboardContainer 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/>
- <local:RestoreProgressView/>
-
- <local:BackupErrorView/>
- <local:RestoreErrorView/>
-
- <local:BackupCompletedView/>
- <local:RestoreCompletedView/>
- </controls:NavigationControl>
- </DockPanel>
- </touch:TouchKeyboardContainer>
-</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
deleted file mode 100644
index e21bec0cb..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/MainView.xaml.cs
+++ /dev/null
@@ -1,30 +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.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/RestoreCompletedView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml
deleted file mode 100644
index 6352797e7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml
+++ /dev/null
@@ -1,37 +0,0 @@
-<UserControl x:Class="Tango.PPC.BackupRestore.Views.RestoreCompletedView"
- 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:RestoreCompletedViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RestoreCompletedViewVM}">
-
- <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}" Foreground="{StaticResource TangoSuccessBrush}">System restored</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>Your system was successfully restored. The system needs to restart in order apply the changes.</Run>
- </TextBlock>
- </StackPanel>
- </Grid>
-
- <Grid DockPanel.Dock="Bottom">
- <touch:TouchButton Command="{Binding RestartCommand}" HorizontalAlignment="Right" Height="80" Width="300" CornerRadius="40" Content="RESTART"/>
- </Grid>
-
- <Grid>
-
- </Grid>
-
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml.cs
deleted file mode 100644
index 5c3fbeaec..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreCompletedView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.BackupRestore.Views
-{
- /// <summary>
- /// Interaction logic for BackupView.xaml
- /// </summary>
- public partial class RestoreCompletedView : UserControl
- {
- public RestoreCompletedView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml
deleted file mode 100644
index 2d09326ea..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml
+++ /dev/null
@@ -1,39 +0,0 @@
-<UserControl x:Class="Tango.PPC.BackupRestore.Views.RestoreErrorView"
- 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:RestoreErrorViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RestoreErrorViewVM}">
-
- <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}" Foreground="{StaticResource TangoErrorBrush}">Restore failed</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>The restore operation has failed due to the following reason.</Run>
- </TextBlock>
- </StackPanel>
- </Grid>
-
- <Grid DockPanel.Dock="Bottom">
-
- </Grid>
-
- <Grid>
- <TextBlock Text="{Binding Error}" Margin="0 10 0 0" Height="Auto" TextWrapping="Wrap" Foreground="{StaticResource TangoGrayTextBrush}">
-
- </TextBlock>
- </Grid>
-
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml.cs
deleted file mode 100644
index c0268d020..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreErrorView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.BackupRestore.Views
-{
- /// <summary>
- /// Interaction logic for BackupView.xaml
- /// </summary>
- public partial class RestoreErrorView : UserControl
- {
- public RestoreErrorView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml
deleted file mode 100644
index 65c1678c5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml
+++ /dev/null
@@ -1,38 +0,0 @@
-<UserControl x:Class="Tango.PPC.BackupRestore.Views.RestoreProgressView"
- 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:RestoreViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RestoreViewVM}">
-
- <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}">Restoring 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 CurrentRestoreProgress.Stage,Converter={StaticResource EnumToDescriptionConverter},FallbackValue='Restoring data'}" HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}"></TextBlock>
- <touch:TouchProgressBar Margin="0 20" Height="10" IsIndeterminate="{Binding CurrentRestoreProgress.IsIntermediate}" Maximum="{Binding CurrentRestoreProgress.MaxProgress}" Value="{Binding CurrentRestoreProgress.Progress,Mode=OneWay}" />
- </StackPanel>
- </Grid>
-
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml.cs
deleted file mode 100644
index 3b8b19fa9..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreProgressView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.BackupRestore.Views
-{
- /// <summary>
- /// Interaction logic for BackupView.xaml
- /// </summary>
- public partial class RestoreProgressView : UserControl
- {
- public RestoreProgressView()
- {
- 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
deleted file mode 100644
index fca7a668e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml
+++ /dev/null
@@ -1,160 +0,0 @@
-<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="700" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:RestoreViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RestoreViewVM}">
-
- <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}">
- <DockPanel Margin="30 0 30 30">
- <Grid DockPanel.Dock="Bottom">
- <DockPanel>
- <touch:TouchButton Command="{Binding RestoreCommand}" HorizontalAlignment="Right" Height="80" Width="300" CornerRadius="40" Content="START"/>
- </DockPanel>
- </Grid>
- <StackPanel IsEnabled="{Binding IsFree}">
- <TextBlock TextWrapping="Wrap" FontSize="{StaticResource TangoDefaultFontSize}">
- <Run FontSize="{StaticResource TangoTitleFontSize}">Restore your system</Run>
- <LineBreak/>
- <LineBreak/>
- <Run>Please specify the location of your backup file and other options. Press 'START' when you are ready.</Run>
- </TextBlock>
-
- <touch:TouchDropShadowBorder Padding="10 10 10 20" Margin="0 50 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 insert a storage device and select your backup file</TextBlock>
- <DockPanel Height="50" Margin="0 20 0 0">
- <touch:TouchButton Command="{Binding BrowseForBackupCommand}" Margin="20 0 0 0" Width="150" DockPanel.Dock="Right" Foreground="{StaticResource TangoDarkForegroundBrush}" BorderBrush="{StaticResource TangoDarkForegroundBrush}" Style="{StaticResource TangoHollowButton}">SELECT</touch:TouchButton>
- <touch:TouchTextBox Text="{Binding BackupFileName}" IsReadOnly="True" />
- </DockPanel>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <touch:TouchDropShadowBorder Padding="10 10 10 0" Margin="0 10 0 0" Visibility="{Binding BackupFile,Converter={StaticResource IsNullToVisibilityConverter}}">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center">
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoPrimaryAccentBrush}">Information</TextBlock>
- </StackPanel>
-
- <StackPanel Margin="0 20 0 0">
-
- <StackPanel>
- <controls:TableGrid RowHeight="20">
- <TextBlock Text="Name:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.Name}"></TextBlock>
-
- <TextBlock Text="Date:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.Date}"></TextBlock>
-
- <TextBlock Text="Size:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupSize,Converter={StaticResource ByteArrayToFileSizeConverter}}"></TextBlock>
-
- <TextBlock Text="Mode:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.Settings.Mode}"></TextBlock>
- </controls:TableGrid>
- </StackPanel>
-
- <StackPanel Margin="0 -20 0 0">
- <StackPanel.Style>
- <Style TargetType="StackPanel">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding BackupFile.Settings.Mode}" Value="Jobs">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </StackPanel.Style>
- <controls:TableGrid RowHeight="20">
- <TextBlock Text="Jobs:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.JobFiles.Count}"></TextBlock>
- </controls:TableGrid>
- </StackPanel>
-
- <StackPanel>
- <StackPanel.Style>
- <Style TargetType="StackPanel">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding BackupFile.Settings.Mode}" Value="Full">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </StackPanel.Style>
- <controls:TableGrid RowHeight="20">
- <TextBlock Text="Application Version:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.ApplicationVersion}"></TextBlock>
-
- <TextBlock Text="Firmware Version:"></TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" Text="{Binding BackupFile.FirmwareVersion}"></TextBlock>
- </controls:TableGrid>
- </StackPanel>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <touch:TouchDropShadowBorder Padding="10" Margin="0 10 0 0">
- <touch:TouchDropShadowBorder.Style>
- <Style TargetType="touch:TouchDropShadowBorder">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding BackupFile.Settings.Mode}" Value="Jobs">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchDropShadowBorder.Style>
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center">
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoPrimaryAccentBrush}">Options</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 RestoreSettings.OverwriteExistingJobs,Mode=TwoWay}">
- <touch:TouchCheckBox.Content>
- <TextBlock>
- <Run>Overwrite existing jobs</Run>
- <Run Style="{StaticResource run}">(existing jobs will change if there are conflicts)</Run>
- </TextBlock>
- </touch:TouchCheckBox.Content>
- </touch:TouchCheckBox>
- <touch:TouchCheckBox IsChecked="{Binding RestoreSettings.AllowDeleteJobs,Converter={StaticResource BooleanInverseConverter},Mode=TwoWay}">
- <touch:TouchCheckBox.Content>
- <TextBlock>
- <Run>Do not remove existing jobs</Run>
- <Run Style="{StaticResource run}">(existing jobs will not be deleted)</Run>
- </TextBlock>
- </touch:TouchCheckBox.Content>
- </touch:TouchCheckBox>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
- </StackPanel>
- </DockPanel>
- </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
deleted file mode 100644
index 4df9146bb..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/RestoreView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-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
deleted file mode 100644
index cf64b5bea..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml
+++ /dev/null
@@ -1,72 +0,0 @@
-<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
deleted file mode 100644
index a7c347016..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/Views/WelcomeView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-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
deleted file mode 100644
index 1e22e6a88..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/app.config
+++ /dev/null
@@ -1,61 +0,0 @@
-<?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
deleted file mode 100644
index 80367fdd2..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BackupRestore/packages.config
+++ /dev/null
@@ -1,7 +0,0 @@
-<?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.Browser/App.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/App.xaml
deleted file mode 100644
index 576597134..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/App.xaml
+++ /dev/null
@@ -1,11 +0,0 @@
-<Application x:Class="Tango.PPC.Browser.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.Browser/Attributes/BoundObjectAttribute.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Attributes/BoundObjectAttribute.cs
deleted file mode 100644
index b4e822f1e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Attributes/BoundObjectAttribute.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
-namespace Tango.PPC.Browser.Attributes
-{
- public class BoundObjectAttribute : Attribute
- {
- public String Name { get; set; }
- public String ScriptFile { get; set; }
-
- public BoundObjectAttribute(String name,String scriptFile)
- {
- Name = name;
- ScriptFile = scriptFile;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BoundsObjects/KeyboardHandler.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BoundsObjects/KeyboardHandler.cs
deleted file mode 100644
index 3c608a518..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BoundsObjects/KeyboardHandler.cs
+++ /dev/null
@@ -1,66 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Diagnostics;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using Tango.PPC.Browser.Attributes;
-using Tango.PPC.Browser.Views;
-using Tango.PPC.Common.Helpers;
-using Tango.Touch.Keyboard;
-
-namespace Tango.PPC.Browser.BoundsObjects
-{
- [BoundObject("keyboard", "keyboard.js")]
- public class KeyboardHandler
- {
- private DateTime _lastTime;
-
- public KeyboardHandler()
- {
- _lastTime = DateTime.Now;
- }
-
- public void openKeyboard(String inputType)
- {
- if (DateTime.Now > _lastTime.AddMilliseconds(1000))
- {
- _lastTime = DateTime.Now;
-
- Application.Current.Dispatcher.BeginInvoke(new Action(async () =>
- {
- switch (inputType)
- {
- case "search":
- KeyboardHelper.OpenKeyboard(KeyboardActionKeyMode.Go);
- break;
- default:
- KeyboardHelper.OpenKeyboard(KeyboardActionKeyMode.Next);
- break;
- }
-
-
- await Task.Delay(50);
- BrowserView.Instance.btnGo.Focus();
- await Task.Delay(50);
- BrowserView.Instance.Browser.Focus();
- Debug.WriteLine("Focus");
- }));
- }
- }
-
- public void closeKeyboard()
- {
- if (DateTime.Now > _lastTime.AddMilliseconds(1000))
- {
- _lastTime = DateTime.Now;
-
- Application.Current.Dispatcher.BeginInvoke(new Action(() =>
- {
- KeyboardHelper.CloseKeyboard();
- }));
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BrowserModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BrowserModule.cs
deleted file mode 100644
index dc7b294d5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/BrowserModule.cs
+++ /dev/null
@@ -1,101 +0,0 @@
-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.Browser.Views;
-using Tango.SharedUI.Helpers;
-using Tango.Core.DI;
-using Tango.PPC.Common.Application;
-using System.IO;
-using Tango.Core.Helpers;
-
-namespace Tango.PPC.Browser
-{
- /// <summary>
- /// Represents a PPC <see cref="BrowserModule"/>.
- /// </summary>
- /// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(10)]
- public class BrowserModule : PPCModuleBase
- {
- /// <summary>
- /// Initializes a new instance of the <see cref="BrowserModule"/> class.
- /// </summary>
- public BrowserModule()
- {
- IsVisibleInMenu = false;
- }
-
- /// <summary>
- /// Gets the module name.
- /// </summary>
- public override string Name
- {
- get
- {
- return "Browser";
- }
- }
-
- /// <summary>
- /// Gets the module description.
- /// </summary>
- public override string Description
- {
- get
- {
- return "Browser module";
- }
- }
-
- /// <summary>
- /// Gets the module cover image.
- /// </summary>
- public override BitmapSource Image
- {
- get
- {
- return ResourceHelper.GetImageFromResources("Images/browser.png");
- }
- }
-
- /// <summary>
- /// Gets the module entry point view type.
- /// </summary>
- public override Type MainViewType
- {
- get
- {
- return IsCefAvailable() ? typeof(BrowserView) : typeof(ErrorView);
- }
- }
-
- /// <summary>
- /// Gets the permission required to see and load this module.
- /// </summary>
- public override Permissions Permission
- {
- get
- {
- return Permissions.RunPPC;
- }
- }
-
- private bool IsCefAvailable()
- {
- return File.Exists(Path.Combine(AssemblyHelper.GetCurrentAssemblyFolder(), "x86", "CefSharp.Core.dll"));
- }
-
- /// <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.Browser/CefSharpOutput.zip b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/CefSharpOutput.zip
deleted file mode 100644
index 8c68cedb7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/CefSharpOutput.zip
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Helpers/BoundObjectsHelper.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Helpers/BoundObjectsHelper.cs
deleted file mode 100644
index fe68ee848..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Helpers/BoundObjectsHelper.cs
+++ /dev/null
@@ -1,72 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Reflection;
-using Tango.PPC.Browser.Attributes;
-using CefSharp;
-using CefSharp.Wpf;
-using Tango.Core.Helpers;
-using System.Windows.Threading;
-
-namespace Tango.PPC.Browser.Helpers
-{
- public static class BoundObjectsHelper
- {
- private static DispatcherTimer _timer;
- private static Dispatcher _dispatcher;
- private static ChromiumWebBrowser _browser;
-
- private static List<String> _scripts = new List<string>();
-
- public static void RegisterAllBoundObjects(ChromiumWebBrowser browser, Dispatcher dispatcher)
- {
- _dispatcher = dispatcher;
- _browser = browser;
-
- _timer = new DispatcherTimer(DispatcherPriority.Background, dispatcher);
- _timer.Tick += _timer_Tick;
- _timer.Interval = TimeSpan.FromSeconds(2);
- _timer.Stop();
-
- foreach (var type in typeof(BoundObjectsHelper).Assembly.GetTypes().Where(x => x.GetCustomAttribute<BoundObjectAttribute>() != null))
- {
- var att = type.GetCustomAttribute<BoundObjectAttribute>();
-
- var script = EmbeddedResourceHelper.GetEmbeddedResourceText($"Tango.PPC.Browser.Scripts.{att.ScriptFile}");
- _scripts.Add(script);
-
- browser.JavascriptObjectRepository.Register(att.Name, Activator.CreateInstance(type), true);
-
- browser.FrameLoadEnd += Browser_FrameLoadEnd;
- }
- }
-
- private static void Browser_FrameLoadEnd(object sender, FrameLoadEndEventArgs e)
- {
- _timer.Stop();
- _timer.Start();
- }
-
- private static void _timer_Tick(object sender, EventArgs e)
- {
- try
- {
- _timer.Stop();
-
- _dispatcher.BeginInvoke(new Action(() =>
- {
- foreach (var script in _scripts)
- {
- _browser.GetMainFrame().ExecuteJavaScriptAsync(script);
- }
- }));
- }
- catch
- {
- _timer.Start();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Images/browser.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Images/browser.png
deleted file mode 100644
index ebb975b6f..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Images/browser.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Navigation/BrowserNavigationRequest.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Navigation/BrowserNavigationRequest.cs
deleted file mode 100644
index a8becf251..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Navigation/BrowserNavigationRequest.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.Browser.Navigation
-{
- public class BrowserNavigationRequest
- {
- public String Address { get; set; }
- public bool DisplayAddressBar { get; set; }
-
- public BrowserNavigationRequest()
- {
- DisplayAddressBar = true;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/AssemblyInfo.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/AssemblyInfo.cs
deleted file mode 100644
index 70edee491..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/AssemblyInfo.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-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 Web Browser 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.Browser/Properties/Resources.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.Designer.cs
deleted file mode 100644
index 01c0a8851..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.Designer.cs
+++ /dev/null
@@ -1,63 +0,0 @@
-//------------------------------------------------------------------------------
-// <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.Browser.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.Browser.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.Browser/Properties/Resources.resx b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.resx
deleted file mode 100644
index af7dbebba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-<?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.Browser/Properties/Settings.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.Designer.cs
deleted file mode 100644
index f464e258d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.Designer.cs
+++ /dev/null
@@ -1,26 +0,0 @@
-//------------------------------------------------------------------------------
-// <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.Browser.Properties {
-
-
- [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
- [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.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.Browser/Properties/Settings.settings b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.settings
deleted file mode 100644
index 033d7a5e9..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Properties/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-<?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.Browser/RequestHandlers/ChromiumRequestHandler.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/RequestHandlers/ChromiumRequestHandler.cs
deleted file mode 100644
index fc6cb119c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/RequestHandlers/ChromiumRequestHandler.cs
+++ /dev/null
@@ -1,114 +0,0 @@
-using CefSharp;
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
-namespace Tango.PPC.Browser.RequestHandlers
-{
- public class ChromiumRequestHandler : IRequestHandler
- {
- public event EventHandler<String> AddressChanged;
-
- public bool GetAuthCredentials(IWebBrowser browserControl, IBrowser browser, IFrame frame, bool isProxy, string host, int port, string realm, string scheme, IAuthCallback callback)
- {
- return false;
- }
-
- public bool OnBeforeBrowse(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, bool isRedirect)
- {
- // You can check the Request object for the URL Here
- return false;
- }
-
- public CefReturnValue OnBeforeResourceLoad(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, IRequestCallback callback)
- {
- // You can also check the URL here
- callback.Dispose();
- return CefReturnValue.Continue;
- }
-
- public bool OnCertificateError(IWebBrowser browserControl, IBrowser browser, CefErrorCode errorCode, string requestUrl, ISslInfo sslInfo, IRequestCallback callback)
- {
- callback.Dispose();
- return false;
- }
-
- public bool OnOpenUrlFromTab(IWebBrowser browserControl, IBrowser browser, IFrame frame, string targetUrl, WindowOpenDisposition targetDisposition, bool userGesture)
- {
- return false;
- }
-
- public void OnPluginCrashed(IWebBrowser browserControl, IBrowser browser, string pluginPath)
- {
- }
-
- public bool OnProtocolExecution(IWebBrowser browserControl, IBrowser browser, string url)
- {
- return false;
- }
-
- public bool OnQuotaRequest(IWebBrowser browserControl, IBrowser browser, string originUrl, long newSize, IRequestCallback callback)
- {
- callback.Dispose();
- return false;
- }
-
- public void OnRenderProcessTerminated(IWebBrowser browserControl, IBrowser browser, CefTerminationStatus status)
- {
- }
-
- public void OnRenderViewReady(IWebBrowser browserControl, IBrowser browser)
- {
- }
-
- public void OnResourceLoadComplete(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, IResponse response, UrlRequestStatus status, long receivedContentLength)
- {
- // You can also check the request URL here
- }
-
- public void OnResourceRedirect(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, ref string newUrl)
- {
- }
-
- public bool OnResourceResponse(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, IResponse response)
- {
- return false;
- }
-
-
- public IResponseFilter GetResourceResponseFilter(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, IResponse response)
- {
- return null;
- }
-
-
- public void OnResourceRedirect(IWebBrowser browserControl, IBrowser browser, IFrame frame, IRequest request, IResponse response, ref string newUrl)
- {
- }
-
- public bool OnSelectClientCertificate(IWebBrowser browserControl, IBrowser browser, bool isProxy, string host, int port, System.Security.Cryptography.X509Certificates.X509Certificate2Collection certificates, ISelectClientCertificateCallback callback)
- {
- callback.Dispose();
- return false;
- }
-
- public bool OnBeforeBrowse(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, IRequest request, bool userGesture, bool isRedirect)
- {
- AddressChanged?.Invoke(this, request.Url);
- return false;
- }
-
- public IResourceRequestHandler GetResourceRequestHandler(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, IRequest request, bool isNavigation, bool isDownload, string requestInitiator, ref bool disableDefaultHandling)
- {
- return null;
- }
-
- public bool GetAuthCredentials(IWebBrowser chromiumWebBrowser, IBrowser browser, string originUrl, bool isProxy, string host, int port, string realm, string scheme, IAuthCallback callback)
- {
- callback.Dispose();
- return false;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Scripts/keyboard.js b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Scripts/keyboard.js
deleted file mode 100644
index 21771eb8e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Scripts/keyboard.js
+++ /dev/null
@@ -1,21 +0,0 @@
-(async function () {
- await CefSharp.BindObjectAsync("keyboard", "bound");
-
- var inputs = document.getElementsByTagName('input');
- var i = 0;
-
- do {
-
- var type = inputs[i].type;
-
- if (type == 'text' || type == 'email' || type == 'password' || type == 'search' || type == 'date' || type == 'url' || type == 'time' || type == 'tel' || type == 'number') {
- inputs[i].onfocus = function () {
- keyboard.openKeyboard(type);
- }
- inputs[i].onblur = function () {
- keyboard.closeKeyboard();
- }
- }
- }
- while (inputs[++i])
-})(); \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Tango.PPC.Browser.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Tango.PPC.Browser.csproj
deleted file mode 100644
index b742d4d75..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Tango.PPC.Browser.csproj
+++ /dev/null
@@ -1,199 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
- <Import Project="..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.props" Condition="Exists('..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.props')" />
- <Import Project="..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.props" Condition="Exists('..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.props')" />
- <Import Project="..\..\..\packages\cef.redist.x86.75.1.14\build\cef.redist.x86.props" Condition="Exists('..\..\..\packages\cef.redist.x86.75.1.14\build\cef.redist.x86.props')" />
- <Import Project="..\..\..\packages\cef.redist.x64.75.1.14\build\cef.redist.x64.props" Condition="Exists('..\..\..\packages\cef.redist.x64.75.1.14\build\cef.redist.x64.props')" />
- <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
- <PropertyGroup>
- <CefSharpAnyCpuSupport>true</CefSharpAnyCpuSupport>
- <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
- <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
- <ProjectGuid>{F02EAA84-AD59-465B-99A2-4422C13BFB72}</ProjectGuid>
- <OutputType>library</OutputType>
- <RootNamespace>Tango.PPC.Browser</RootNamespace>
- <AssemblyName>Tango.PPC.Browser</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 />
- <NuGetPackageImportStamp>
- </NuGetPackageImportStamp>
- </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>bin\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\BrowserView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- <Page Include="Views\ErrorView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- </ItemGroup>
- <ItemGroup>
- <Compile Include="..\..\..\Versioning\GlobalVersionInfo.cs">
- <Link>GlobalVersionInfo.cs</Link>
- </Compile>
- <Compile Include="Attributes\BoundObjectAttribute.cs" />
- <Compile Include="BoundsObjects\KeyboardHandler.cs" />
- <Compile Include="BrowserModule.cs" />
- <Compile Include="Helpers\BoundObjectsHelper.cs" />
- <Compile Include="Navigation\BrowserNavigationRequest.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="RequestHandlers\ChromiumRequestHandler.cs" />
- <Compile Include="ViewContracts\IBrowserView.cs" />
- <Compile Include="ViewModelLocator.cs" />
- <Compile Include="ViewModels\BrowserViewVM.cs" />
- <Compile Include="Views\BrowserView.xaml.cs">
- <DependentUpon>BrowserView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\ErrorView.xaml.cs">
- <DependentUpon>ErrorView.xaml</DependentUpon>
- </Compile>
- <EmbeddedResource Include="Properties\Resources.resx">
- <Generator>ResXFileCodeGenerator</Generator>
- <LastGenOutput>Resources.Designer.cs</LastGenOutput>
- </EmbeddedResource>
- <None Include="app.config" />
- <None Include="CefSharpOutput.zip" />
- <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.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>
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\browser.png" />
- </ItemGroup>
- <ItemGroup>
- <EmbeddedResource Include="Scripts\keyboard.js" />
- </ItemGroup>
- <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" />
- </VisualStudio>
- </ProjectExtensions>
- <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
- <PropertyGroup>
- <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
- </PropertyGroup>
- <Error Condition="!Exists('..\..\..\packages\cef.redist.x64.75.1.14\build\cef.redist.x64.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\cef.redist.x64.75.1.14\build\cef.redist.x64.props'))" />
- <Error Condition="!Exists('..\..\..\packages\cef.redist.x86.75.1.14\build\cef.redist.x86.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\cef.redist.x86.75.1.14\build\cef.redist.x86.props'))" />
- <Error Condition="!Exists('..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.props'))" />
- <Error Condition="!Exists('..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.targets'))" />
- <Error Condition="!Exists('..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.props'))" />
- <Error Condition="!Exists('..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.targets'))" />
- </Target>
- <Import Project="..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.targets" Condition="Exists('..\..\..\packages\CefSharp.Common.75.1.143\build\CefSharp.Common.targets')" />
- <Import Project="..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.targets" Condition="Exists('..\..\..\packages\CefSharp.Wpf.75.1.143\build\CefSharp.Wpf.targets')" />
-</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewContracts/IBrowserView.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewContracts/IBrowserView.cs
deleted file mode 100644
index 8369209a3..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewContracts/IBrowserView.cs
+++ /dev/null
@@ -1,18 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Browser.ViewContracts
-{
- public interface IBrowserView : IPPCView
- {
- event EventHandler<String> AddressChanged;
- bool CanGoBack();
- void NavigateTo(String address);
- void GoBack();
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModelLocator.cs
deleted file mode 100644
index 054310e99..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModelLocator.cs
+++ /dev/null
@@ -1,32 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core.DI;
-using Tango.PPC.Browser.ViewModels;
-
-namespace Tango.PPC.Browser
-{
- public static class ViewModelLocator
- {
- /// <summary>
- /// Initializes a new instance of the ViewModelLocator class.
- /// </summary>
- static ViewModelLocator()
- {
- TangoIOC.Default.Register<BrowserViewVM>();
- }
-
- /// <summary>
- /// Gets the main view VM.
- /// </summary>
- public static BrowserViewVM BrowserViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<BrowserViewVM>();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModels/BrowserViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModels/BrowserViewVM.cs
deleted file mode 100644
index 0f5a49639..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/ViewModels/BrowserViewVM.cs
+++ /dev/null
@@ -1,134 +0,0 @@
-using CefSharp;
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core.Commands;
-using Tango.PPC.Browser.Navigation;
-using Tango.PPC.Browser.ViewContracts;
-using Tango.PPC.Common;
-using Tango.PPC.Common.Navigation;
-using Tango.Touch.Keyboard;
-
-namespace Tango.PPC.Browser.ViewModels
-{
- /// <summary>
- /// Represents the main view VM and entry point for <see cref="Synchronization.MyModule"/>.
- /// </summary>
- /// <seealso cref="Tango.PPC.Common.PPCViewModel" />
- public class BrowserViewVM : PPCViewModel<IBrowserView>, INavigationObjectReceiver<BrowserNavigationRequest>
- {
- private bool _isFromObject;
-
- private String _address;
- public String Address
- {
- get { return _address; }
- set { _address = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _displayAddressBar;
- public bool DisplayAddressBar
- {
- get { return _displayAddressBar; }
- set { _displayAddressBar = value; RaisePropertyChangedAuto(); }
- }
-
- public RelayCommand GoCommand { get; set; }
-
- public BrowserViewVM()
- {
- DisplayAddressBar = true;
-
- GoCommand = new RelayCommand(Go);
- }
-
- public override void OnViewAttached()
- {
- base.OnViewAttached();
- View.AddressChanged += View_AddressChanged;
- }
-
- private void View_AddressChanged(object sender, string address)
- {
- Address = address;
- }
-
- public override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
-
- KeyboardView.Default.OutputMode = KeyboardOutputMode.Windows;
-
- if (!_isFromObject)
- {
- DisplayAddressBar = true;
- }
-
- _isFromObject = false;
- }
-
- public override void OnNavigatedFrom()
- {
- base.OnNavigatedFrom();
- KeyboardView.Default.OutputMode = KeyboardOutputMode.Wpf;
- }
-
- public override Task<bool> OnNavigateBackRequest()
- {
- if (View != null && View.CanGoBack())
- {
- View.GoBack();
- return Task.FromResult(false);
- }
- else
- {
- return Task.FromResult(true);
- }
- }
-
- /// <summary>
- /// Called when the application has been started
- /// </summary>
- public override void OnApplicationStarted()
- {
-
- }
-
- public override void OnApplicationShuttingDown()
- {
- base.OnApplicationShuttingDown();
-
- try
- {
- Cef.Shutdown();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error shutting down cef.");
- }
- }
-
- private void Go()
- {
- if (View != null)
- {
- View.NavigateTo(Address);
- }
- }
-
- public void OnNavigatedToWithObject(BrowserNavigationRequest obj)
- {
- _isFromObject = true;
-
- DisplayAddressBar = obj.DisplayAddressBar;
-
- if (obj.Address != null)
- {
- Address = obj.Address;
- Go();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml
deleted file mode 100644
index ce28d660e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml
+++ /dev/null
@@ -1,77 +0,0 @@
-<UserControl x:Class="Tango.PPC.Browser.Views.BrowserView"
- 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:vm="clr-namespace:Tango.PPC.Browser.ViewModels"
- xmlns:wpf="clr-namespace:CefSharp.Wpf;assembly=CefSharp.Wpf"
- xmlns:experimental="clr-namespace:CefSharp.Wpf.Experimental;assembly=CefSharp.Wpf"
- xmlns:global="clr-namespace:Tango.PPC.Browser"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:keyboard="clr-namespace:Tango.Touch.Keyboard;assembly=Tango.Touch"
- xmlns:local="clr-namespace:Tango.PPC.Browser.Views"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:BrowserViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BrowserViewVM}" Background="{StaticResource TangoPrimaryBackgroundBrush}">
- <Grid>
- <DockPanel>
- <Border DockPanel.Dock="Top" Padding="10" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0 0 0 1" Visibility="{Binding DisplayAddressBar,Converter={StaticResource BooleanToVisibilityConverter}}">
- <DockPanel>
- <touch:TouchButton x:Name="btnGo" Command="{Binding GoCommand}" DockPanel.Dock="Right" Padding="10" Width="150" CornerRadius="20" Margin="20 0 0 0">
- <touch:TouchIcon Icon="ArrowRightBold" Height="20" />
- </touch:TouchButton>
- <Grid>
- <Border Background="{StaticResource TangoMidBackgroundBrush}" Padding="2" BorderBrush="{StaticResource TangoLightBorderBrush}" BorderThickness="1" CornerRadius="20">
- <TextBox x:Name="txtAddress" PreviewMouseDoubleClick="TxtAddress_PreviewMouseDoubleClick" GotFocus="TxtAddress_GotFocus" PreviewMouseUp="TxtAddress_MouseUp" LostFocus="TxtAddress_LostFocus" KeyDown="TxtAddress_KeyDown" VerticalContentAlignment="Center" Text="{Binding Address,UpdateSourceTrigger=PropertyChanged}" BorderThickness="0" FontSize="{StaticResource TangoDefaultFontSize}" Padding="5" Background="Transparent"></TextBox>
- </Border>
- <Border CornerRadius="20" IsHitTestVisible="False" Visibility="{Binding ElementName=Browser,Path=IsLoading,Converter={StaticResource BooleanToVisibilityConverter}}">
- <Border.Background>
- <LinearGradientBrush>
- <GradientStop Offset="0" Color="Transparent" />
- <GradientStop Offset="0.5" Color="#7612D433" />
- <GradientStop Offset="1" Color="Transparent" />
- </LinearGradientBrush>
- </Border.Background>
- <Border.Style>
- <Style TargetType="Border">
- <Style.Triggers>
- <DataTrigger Binding="{Binding ElementName=Browser,Path=IsLoading}" Value="True">
- <DataTrigger.EnterActions>
- <BeginStoryboard Name="loadingStory">
- <Storyboard>
- <DoubleAnimation Storyboard.TargetProperty="Background.GradientStops[1].Offset" From="0" To="1" AutoReverse="True" RepeatBehavior="Forever" />
- </Storyboard>
- </BeginStoryboard>
- </DataTrigger.EnterActions>
- <DataTrigger.ExitActions>
- <RemoveStoryboard BeginStoryboardName="loadingStory" />
- </DataTrigger.ExitActions>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Border.Style>
- </Border>
- </Grid>
- </DockPanel>
- </Border>
-
- <Grid>
- <experimental:ChromiumWebBrowserWithTouchSupport x:Name="Browser" />
- <Grid Background="White" IsHitTestVisible="False" Visibility="Hidden" x:Name="gridError">
- <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
- <touch:TouchIcon Icon="Alert" Foreground="{StaticResource TangoGrayTextBrush}" Width="100" Height="100" />
- <TextBlock HorizontalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" FontSize="40" Margin="0 20 0 0">Page Not Found</TextBlock>
- <TextBlock Margin="0 10 0 0" Foreground="{StaticResource TangoGrayTextBrush}" HorizontalAlignment="Center" Width="600" TextAlignment="Center" TextWrapping="Wrap">
- <Run>The page at '</Run><Run Text="{Binding ElementName=txtAddress,Path=Text,Mode=OneWay}"></Run><Run>'</Run>
- <Run>could not be reached.</Run>
- <LineBreak/>
- <Run>Please check your internet connection.</Run>
- <LineBreak/>
- <LineBreak/>
- <Run x:Name="runError" Text="Unspecified"></Run>
- </TextBlock>
- </StackPanel>
- </Grid>
- </Grid>
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml.cs
deleted file mode 100644
index e7fe1ca27..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/BrowserView.xaml.cs
+++ /dev/null
@@ -1,211 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Diagnostics;
-using System.Linq;
-using System.Text;
-using System.Text.RegularExpressions;
-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 System.Windows.Threading;
-using CefSharp;
-using CefSharp.Wpf;
-using Tango.Core.DI;
-using Tango.Core.Helpers;
-using Tango.Logging;
-using Tango.PPC.Browser.BoundsObjects;
-using Tango.PPC.Browser.ViewContracts;
-using Tango.PPC.Common.Helpers;
-using Tango.Touch.Keyboard;
-
-namespace Tango.PPC.Browser.Views
-{
- /// <summary>
- /// Interaction logic for MainView.xaml
- /// </summary>
- public partial class BrowserView : UserControl, IBrowserView
- {
- public event EventHandler<string> AddressChanged;
-
- public static BrowserView Instance { get; set; }
-
- public BrowserView()
- {
- try
- {
- var settings = new CefSettings();
- settings.BrowserSubprocessPath = @"x86\CefSharp.BrowserSubprocess.exe";
- settings.UserAgent = "Mozilla/5.0 (iPad; CPU OS 12_2 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148";
-
- Cef.Initialize(settings, performDependencyCheck: false, browserProcessHandler: null);
- }
- catch (Exception ex)
- {
- LogManager.Default.Log(ex, "Error loading cef.");
- }
-
- InitializeComponent();
-
- Instance = this;
-
- TangoIOC.Default.Register<IBrowserView>(this);
-
- Helpers.BoundObjectsHelper.RegisterAllBoundObjects(Browser, Dispatcher);
-
- KeyboardView.Default.KeyboardOpened += Default_KeyboardOpened;
- KeyboardView.Default.KeyboardClosed += Default_KeyboardClosed;
-
- var handler = new RequestHandlers.ChromiumRequestHandler();
- handler.AddressChanged += Handler_AddressChanged;
- Browser.RequestHandler = handler;
- Browser.LoadError += Browser_LoadError;
- Browser.LoadingStateChanged += Browser_LoadingStateChanged;
- }
-
- private void Browser_LoadError(object sender, LoadErrorEventArgs e)
- {
- //if (e.ErrorCode == CefErrorCode.ConnectionTimedOut || e.ErrorCode == CefErrorCode.NameNotResolved)
- //{
- InvokeUI(() =>
- {
- runError.Text = e.ErrorText;
- gridError.Visibility = Visibility.Visible;
- });
- //}
- }
-
- private void Browser_LoadingStateChanged(object sender, LoadingStateChangedEventArgs e)
- {
- if (!e.IsLoading)
- {
- InvokeUI(() =>
- {
- KeyboardHelper.CloseKeyboard();
- });
- }
- else
- {
- InvokeUI(() =>
- {
- gridError.Visibility = Visibility.Hidden;
- });
- }
- }
-
- private void Handler_AddressChanged(object sender, string address)
- {
- InvokeUI(() =>
- {
- AddressChanged?.Invoke(this, address);
- });
- }
-
- private void Default_KeyboardClosed(object sender, EventArgs e)
- {
- Browser.VerticalAlignment = VerticalAlignment.Stretch;
- Browser.Height = double.NaN;
- }
-
- private void Default_KeyboardOpened(object sender, EventArgs e)
- {
- Browser.VerticalAlignment = VerticalAlignment.Top;
- Browser.Height = 780;
- }
-
- public bool CanGoBack()
- {
- return Browser.CanGoBack;
- }
-
- public void NavigateTo(string address)
- {
- if (Browser.Address != address)
- {
- String uri;
-
- if (ValidHttpURL(address, out uri))
- {
- Browser.Address = uri;
- }
- else
- {
- Browser.Address = $"google.com/search?q={address.Replace(" ", "+")}";
- }
- }
- else
- {
- Browser.Reload();
- }
- }
-
- public static bool ValidHttpURL(string s, out string result)
- {
- if (Uri.IsWellFormedUriString(s, UriKind.Absolute))
- {
- result = s;
- return true;
- }
- else if (s.StartsWith("www."))
- {
- result = "http://" + s;
- return true;
- }
-
- result = s;
- return false;
- }
-
- public void GoBack()
- {
- if (Browser.CanGoBack)
- {
- Browser.Back();
- }
- }
-
- private async void TxtAddress_GotFocus(object sender, RoutedEventArgs e)
- {
- KeyboardHelper.OpenKeyboard(KeyboardActionKeyMode.Go);
- await Task.Delay(100);
- txtAddress.SelectAll();
- }
-
- private void TxtAddress_LostFocus(object sender, RoutedEventArgs e)
- {
- KeyboardHelper.CloseKeyboard();
- }
-
- private void TxtAddress_KeyDown(object sender, KeyEventArgs e)
- {
- if (e.Key == Key.Return)
- {
- KeyboardHelper.CloseKeyboard();
- NavigateTo(txtAddress.Text);
- }
- }
-
- private void TxtAddress_MouseUp(object sender, MouseButtonEventArgs e)
- {
- KeyboardHelper.OpenKeyboard(KeyboardActionKeyMode.Go);
- }
-
- private async void TxtAddress_PreviewMouseDoubleClick(object sender, MouseButtonEventArgs e)
- {
- KeyboardHelper.OpenKeyboard(KeyboardActionKeyMode.Go);
- await Task.Delay(100);
- txtAddress.SelectAll();
- }
-
- private void InvokeUI(Action action)
- {
- Dispatcher.BeginInvoke(action);
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml
deleted file mode 100644
index 25e3381ba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml
+++ /dev/null
@@ -1,23 +0,0 @@
-<UserControl x:Class="Tango.PPC.Browser.Views.ErrorView"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:vm="clr-namespace:Tango.PPC.Browser.ViewModels"
- xmlns:global="clr-namespace:Tango.PPC.Browser"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:Tango.PPC.Browser.Views"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:BrowserViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.BrowserViewVM}" Background="{StaticResource TangoPrimaryBackgroundBrush}">
- <Grid>
- <Grid Background="White" IsHitTestVisible="False">
- <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
- <touch:TouchIcon Icon="Alert" Foreground="{StaticResource TangoGrayTextBrush}" Width="100" Height="100" />
- <TextBlock HorizontalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" FontSize="40" Margin="0 20 0 0">Browser Not Loaded</TextBlock>
- <TextBlock Margin="0 10 0 0" Foreground="{StaticResource TangoGrayTextBrush}" HorizontalAlignment="Center" Width="600" TextAlignment="Center" TextWrapping="Wrap">
- The browser module was not loaded properly or has caused some error.
- </TextBlock>
- </StackPanel>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml.cs
deleted file mode 100644
index 0d59b80f0..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/Views/ErrorView.xaml.cs
+++ /dev/null
@@ -1,29 +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.Browser.ViewContracts;
-
-namespace Tango.PPC.Browser.Views
-{
- /// <summary>
- /// Interaction logic for ErrorView.xaml
- /// </summary>
- public partial class ErrorView : UserControl
- {
- public ErrorView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/app.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/app.config
deleted file mode 100644
index cf33970a7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/app.config
+++ /dev/null
@@ -1,90 +0,0 @@
-<?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">
- <!--Required for cefCharp-->
- <probing privatePath="x86"/>
- <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>
- <dependentAssembly>
- <assemblyIdentity name="Microsoft.IdentityModel.Clients.ActiveDirectory" publicKeyToken="31bf3856ad364e35" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-5.0.5.0" newVersion="5.0.5.0" />
- </dependentAssembly>
- <dependentAssembly>
- <assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31bf3856ad364e35" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-5.6.4.0" newVersion="5.6.4.0" />
- </dependentAssembly>
- <dependentAssembly>
- <assemblyIdentity name="Microsoft.Data.Services.Client" publicKeyToken="31bf3856ad364e35" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-5.6.4.0" newVersion="5.6.4.0" />
- </dependentAssembly>
- <dependentAssembly>
- <assemblyIdentity name="Microsoft.Data.OData" publicKeyToken="31bf3856ad364e35" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-5.6.4.0" newVersion="5.6.4.0" />
- </dependentAssembly>
- <dependentAssembly>
- <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="9.0.0.0" />
- </dependentAssembly>
- <dependentAssembly>
- <assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" culture="neutral" />
- <bindingRedirect oldVersion="0.0.0.0-1.5.2.14234" newVersion="1.5.2.14234" />
- </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.Browser/packages.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/packages.config
deleted file mode 100644
index f7fe1b9a2..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Browser/packages.config
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<packages>
- <package id="cef.redist.x64" version="75.1.14" targetFramework="net461" />
- <package id="cef.redist.x86" version="75.1.14" targetFramework="net461" />
- <package id="CefSharp.Common" version="75.1.143" targetFramework="net461" />
- <package id="CefSharp.Wpf" version="75.1.143" targetFramework="net461" />
- <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.BugReporting/BugReportingModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/BugReportingModule.cs
index 659ffe732..e65b44698 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/BugReportingModule.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/BugReportingModule.cs
@@ -17,7 +17,7 @@ namespace Tango.PPC.BugReporting
/// Represents a PPC <see cref="BugReportingModule"/>.
/// </summary>
/// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(6)]
+ [PPCModule(5)]
public class BugReportingModule : PPCModuleBase
{
/// <summary>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/TFS/TeamFoundationServicePPCClient.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/TFS/TeamFoundationServicePPCClient.cs
index b84d11c37..26d6425bf 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/TFS/TeamFoundationServicePPCClient.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/TFS/TeamFoundationServicePPCClient.cs
@@ -13,8 +13,6 @@ using Tango.PPC.Common.Connection;
using Tango.TFS;
using Tango.Core.ExtensionMethods;
using Tango.Core.Helpers;
-using Tango.Settings;
-using Tango.PPC.Common;
namespace Tango.PPC.BugReporting.TFS
{
@@ -55,21 +53,6 @@ namespace Tango.PPC.BugReporting.TFS
}
}
- private string[] GetLogFiles(FileLogger logger)
- {
- string[] fileEntries = new string[1];
- fileEntries[0] = logger.LogFile;
- string fileName = Path.GetFileNameWithoutExtension(logger.LogFile);
- int indexPos = fileName.IndexOf(FileLogger.FILE_SET_EXTENSION);
- if (indexPos > 0)
- {
- string extension = Path.GetExtension(logger.LogFile);
- fileName = fileName.Substring(0, indexPos);
- fileEntries = Directory.GetFiles(logger.Folder, $"{fileName}*{extension}").Where(x => Path.GetFileName(x).StartsWith(logger.Tag)).OrderBy(x => x.Length).ThenBy(x => x).ToArray();
- }
- return fileEntries;
- }
-
public async Task SubmitBug(String title, String steps, TeamMember createdBy, TeamMember assignedTo, Severity severity)
{
LogManager.Log("Submitting bug report...");
@@ -97,7 +80,6 @@ namespace Tango.PPC.BugReporting.TFS
item.Severity = severity;
item.State = State.New;
item.Type = WorkItemType.Bug;
- item.Environment = SettingsManager.Default.GetOrCreate<PPCSettings>().DeploymentSlot.ToDescription();
FileLogger appFileLogger = LogManager.Default.RegisteredLoggers.FirstOrDefault(x => x.GetType() == typeof(FileLogger)) as FileLogger;
FileLogger embeddedFileLogger = MachineOperator.EmbeddedLogManager.RegisteredLoggers.FirstOrDefault(x => x.GetType() == typeof(FileLogger)) as FileLogger;
@@ -105,54 +87,31 @@ namespace Tango.PPC.BugReporting.TFS
if (appFileLogger != null)
{
LogManager.Log($"Attaching application log file ${appFileLogger.LogFile}");
- string[] logFiles = GetLogFiles(appFileLogger);
- foreach (string file in logFiles)
+
+ var appLogFile = tempFolder.CreateImaginaryFile();
+ File.Copy(appFileLogger.LogFile, appLogFile.Path);
+
+ item.Attachments.Add(new Attachment()
{
- var appLogFile = tempFolder.CreateImaginaryFile();
- File.Copy(file, appLogFile.Path);
- item.Attachments.Add(new Attachment()
- {
- Description = "Application Log File",
- FilePath = appLogFile.Path,
- Name = Path.GetFileName(file),
- });
- }
+ Description = "Application Log File",
+ FilePath = appLogFile.Path,
+ Name = Path.GetFileName(appFileLogger.LogFile),
+ });
}
if (embeddedFileLogger != null && File.Exists(embeddedFileLogger.LogFile))
{
LogManager.Log($"Attaching embedded log file ${embeddedFileLogger.LogFile}");
- string[] logFiles = GetLogFiles(embeddedFileLogger);
- foreach (string file in logFiles)
- {
- var embeddedLogFile = tempFolder.CreateImaginaryFile();
- File.Copy(file, embeddedLogFile.Path);
- item.Attachments.Add(new Attachment()
- {
- Description = "Embedded Log File",
- FilePath = embeddedLogFile.Path,
- Name = Path.GetFileName(file),
- });
- }
- }
+ var embeddedLogFile = tempFolder.CreateImaginaryFile();
+ File.Copy(embeddedFileLogger.LogFile, embeddedLogFile.Path);
- //Add session log file..
- if (MachineOperator.EnableSessionLogFile)
- {
- var file = MachineOperator.SessionLogger.LogFile;
-
- if (file != null && File.Exists(file))
+ item.Attachments.Add(new Attachment()
{
- var sessionLogFile = tempFolder.CreateImaginaryFile();
- File.Copy(file, sessionLogFile.Path);
- item.Attachments.Add(new Attachment()
- {
- Description = "Session Log File",
- FilePath = sessionLogFile.Path,
- Name = Path.GetFileName(file),
- });
- }
+ Description = "Embedded Log File",
+ FilePath = embeddedLogFile.Path,
+ Name = Path.GetFileName(embeddedFileLogger.LogFile),
+ });
}
SystemInformationModel sysModel = new SystemInformationModel();
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/Tango.PPC.BugReporting_txujxqrg_wpftmp.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/Tango.PPC.BugReporting_txujxqrg_wpftmp.csproj
deleted file mode 100644
index 3b897aa71..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/Tango.PPC.BugReporting_txujxqrg_wpftmp.csproj
+++ /dev/null
@@ -1,235 +0,0 @@
-<?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>{8146FA0A-0725-4A1A-82E6-696C58F33A2B}</ProjectGuid>
- <OutputType>library</OutputType>
- <RootNamespace>Tango.PPC.BugReporting</RootNamespace>
- <AssemblyName>Tango.PPC.BugReporting</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>
- </ItemGroup>
- <ItemGroup>
- </ItemGroup>
- <ItemGroup>
- <Compile Include="..\..\..\Versioning\GlobalVersionInfo.cs">
- <Link>GlobalVersionInfo.cs</Link>
- </Compile>
- <Compile Include="BugReportingModule.cs" />
- <Compile Include="BugReportingSettings.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="TFS\SystemInformationModel.cs" />
- <Compile Include="TFS\TeamFoundationServicePPCClient.cs" />
- <Compile Include="ViewModelLocator.cs" />
- <Compile Include="ViewModels\MainViewVM.cs" />
- <Compile Include="Views\MainView.xaml.cs">
- <DependentUpon>MainView.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>
- <EmbeddedResource Include="TFS\SystemInformationTemplate.cshtml" />
- </ItemGroup>
- <ItemGroup>
- <ProjectReference Include="..\..\..\Tango.BL\Tango.BL.csproj">
- <Project>{f441feee-322a-4943-b566-110e12fd3b72}</Project>
- <Name>Tango.BL</Name>
- </ProjectReference>
- <ProjectReference Include="..\..\..\Tango.CodeGeneration\Tango.CodeGeneration.csproj">
- <Project>{caedae94-11ed-473c-888a-268a6d38cd20}</Project>
- <Name>Tango.CodeGeneration</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.Integration\Tango.Integration.csproj">
- <Project>{4206ac58-3b57-4699-8835-90bf6db01a61}</Project>
- <Name>Tango.Integration</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.TFS\Tango.TFS.csproj">
- <Project>{998f8471-dc1b-41b6-9d96-354e1b4e7a32}</Project>
- <Name>Tango.TFS</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.Web\Tango.Web.csproj">
- <Project>{5001990f-977b-48ff-b217-0236a5022ad8}</Project>
- <Name>Tango.Web</Name>
- </ProjectReference>
- <ProjectReference Include="..\..\Tango.PPC.Common\Tango.PPC.Common.csproj">
- <Project>{0be74eee-22cb-4dba-b896-793b9e1a3ac0}</Project>
- <Name>Tango.PPC.Common</Name>
- </ProjectReference>
- </ItemGroup>
- <ItemGroup>
- </ItemGroup>
- <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>
- <ItemGroup>
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\packages\EntityFramework.6.0.0\lib\net45\EntityFramework.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\packages\EntityFramework.6.0.0\lib\net45\EntityFramework.SqlServer.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\packages\FontAwesome.WPF.4.7.0.9\lib\net40\FontAwesome.WPF.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\packages\Google.Protobuf.3.4.1\lib\net45\Google.Protobuf.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Microsoft.CSharp.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\mscorlib.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\PresentationCore.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\PresentationFramework.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.ComponentModel.DataAnnotations.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Core.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Data.DataSetExtensions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Data.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Net.Http.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\packages\Expression.Blend.Sdk.1.0.2\lib\net45\System.Windows.Interactivity.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Xaml.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Xml.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\System.Xml.Linq.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.BL.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.CodeGeneration.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Core.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.DragAndDrop.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Integration.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Logging.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.PMR.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\PPC\Debug\Tango.PPC.Common.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Settings.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.SharedUI.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.TFS.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Touch.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Transport.dll" />
- <ReferencePath Include="C:\DATA\Development\Tango\Software\Visual_Studio\Build\Core\Debug\Tango.Web.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\WindowsBase.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Collections.Concurrent.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Collections.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ComponentModel.Annotations.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ComponentModel.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ComponentModel.EventBasedAsync.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Diagnostics.Contracts.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Diagnostics.Debug.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Diagnostics.Tools.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Diagnostics.Tracing.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Dynamic.Runtime.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Globalization.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.IO.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Linq.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Linq.Expressions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Linq.Parallel.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Linq.Queryable.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Net.NetworkInformation.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Net.Primitives.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Net.Requests.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Net.WebHeaderCollection.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ObjectModel.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.Emit.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.Emit.ILGeneration.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.Emit.Lightweight.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.Extensions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Reflection.Primitives.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Resources.ResourceManager.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Extensions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Handles.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.InteropServices.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.InteropServices.WindowsRuntime.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Numerics.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Serialization.Json.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Serialization.Primitives.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Runtime.Serialization.Xml.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Security.Principal.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ServiceModel.Duplex.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ServiceModel.Http.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ServiceModel.NetTcp.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ServiceModel.Primitives.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.ServiceModel.Security.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Text.Encoding.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Text.Encoding.Extensions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Text.RegularExpressions.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Threading.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Threading.Tasks.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Threading.Tasks.Parallel.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Threading.Timer.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Xml.ReaderWriter.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Xml.XDocument.dll" />
- <ReferencePath Include="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6.1\Facades\System.Xml.XmlSerializer.dll" />
- </ItemGroup>
- <ItemGroup>
- <Compile Include="C:\DATA\Development\Tango\Software\Visual_Studio\PPC\Modules\Tango.PPC.BugReporting\obj\Debug\App.g.cs" />
- <Compile Include="C:\DATA\Development\Tango\Software\Visual_Studio\PPC\Modules\Tango.PPC.BugReporting\obj\Debug\Views\MainView.g.cs" />
- </ItemGroup>
-</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/ViewModelLocator.cs
index 24b222370..1f71ca2c1 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/ViewModelLocator.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.BugReporting/ViewModelLocator.cs
@@ -16,7 +16,7 @@ namespace Tango.PPC.BugReporting
/// </summary>
static ViewModelLocator()
{
- TangoIOC.Default.Register<TeamFoundationServicePPCClient>(new TeamFoundationServicePPCClient("https://twinetfs.visualstudio.com", String.Empty, "pyulwgs7m3v7pizz3oxusypdkdfw43txggo5mjwu2ouyv2qwprhq"));
+ TangoIOC.Default.Register<TeamFoundationServicePPCClient>(new TeamFoundationServicePPCClient("https://twinetfs.visualstudio.com", String.Empty, "szzfokrceo4rhd4eqi5qpmxn3pa5iwl3q7tlqd36l2m7smz2ynoa"));
TangoIOC.Default.Register<MainViewVM>();
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Converters/MachineEventToViewConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Converters/MachineEventToViewConverter.cs
index 56d7149d3..47c9e0ddf 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Converters/MachineEventToViewConverter.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Converters/MachineEventToViewConverter.cs
@@ -18,17 +18,10 @@ namespace Tango.PPC.Events.Converters
static MachineEventToViewConverter()
{
- //Jobs
_eventViews.Add(EventTypes.JOB_STARTED, typeof(JobEventView));
_eventViews.Add(EventTypes.JOB_ABORTED, typeof(JobEventView));
_eventViews.Add(EventTypes.JOB_COMPLETED, typeof(JobEventView));
_eventViews.Add(EventTypes.JOB_FAILED, typeof(JobEventView));
-
- //Thread Break
- _eventViews.Add(EventTypes.THREAD_BREAK, typeof(ThreadBreakView));
- _eventViews.Add(EventTypes.THREAD_TENSION_CONTROL_FAILURE_FEEDER_DANCER, typeof(ThreadBreakView));
- _eventViews.Add(EventTypes.THREAD_TENSION_CONTROL_FAILURE_PULLER_DANCER, typeof(ThreadBreakView));
- _eventViews.Add(EventTypes.THREAD_TENSION_CONTROL_FAILURE_WINDER_DANCER, typeof(ThreadBreakView));
}
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml
deleted file mode 100644
index 71c4ced07..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml
+++ /dev/null
@@ -1,26 +0,0 @@
-<UserControl x:Class="Tango.PPC.Events.EventsViews.ThreadBreakView"
- 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:entities="clr-namespace:Tango.BL.Entities;assembly=Tango.BL"
- xmlns:local="clr-namespace:Tango.PPC.Events.EventsViews"
- mc:Ignorable="d"
- d:DesignHeight="220" d:DesignWidth="750" d:DataContext="{d:DesignInstance Type=entities:MachinesEvent, IsDesignTimeCreatable=False}">
- <Grid Background="{StaticResource TangoPrimaryBackgroundBrush}">
- <DockPanel>
- <Image Stretch="None" Margin="20" DockPanel.Dock="Right" Source="../Images/machine_small.png" RenderOptions.BitmapScalingMode="Fant" />
- <DockPanel Margin="35 20 20 20">
- <TextBlock FontSize="{StaticResource TangoTitleFontSize}" FontWeight="SemiBold" DockPanel.Dock="Top" Text="{Binding EventType.Title,FallbackValue='Unknown Event'}"></TextBlock>
-
- <StackPanel Margin="0 30 0 0">
- <TextBlock TextWrapping="Wrap" FontWeight="SemiBold" Text="{Binding EventType.Description,FallbackValue='No Description'}"></TextBlock>
- <Rectangle Margin="0 5 0 10" StrokeThickness="2" Stroke="{StaticResource TangoDividerBrush}" />
-
- <touch:TouchButton x:Name="btnLoadThreadBreakWizard" Margin="0 10 0 0" Height="55" Style="{StaticResource TangoHollowButton}" Width="280" HorizontalAlignment="Left">LOAD THREAD BREAK WIZARD</touch:TouchButton>
- </StackPanel>
- </DockPanel>
- </DockPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml.cs
deleted file mode 100644
index 7e8337514..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/EventsViews/ThreadBreakView.xaml.cs
+++ /dev/null
@@ -1,49 +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.Core.DI;
-using Tango.PPC.Common.ThreadLoading;
-
-namespace Tango.PPC.Events.EventsViews
-{
- /// <summary>
- /// Interaction logic for ThreadBreakView.xaml
- /// </summary>
- public partial class ThreadBreakView : UserControl
- {
- public ThreadBreakView()
- {
- InitializeComponent();
-
- btnLoadThreadBreakWizard.Click += BtnLoadThreadBreakWizard_Click;
- }
-
- private void BtnLoadThreadBreakWizard_Click(object sender, RoutedEventArgs e)
- {
- try
- {
- var threadLoadingService = TangoIOC.Default.GetInstance<IThreadLoadingService>();
-
- if (threadLoadingService != null)
- {
- threadLoadingService.StartThreadBreakWizard();
- }
- }
- catch (Exception ex)
- {
- Logging.LogManager.Default.Log(ex, "Error loading the thread break wizard.");
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Resources/Styles.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Resources/Styles.xaml
index eaf621571..53102d8ec 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Resources/Styles.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Resources/Styles.xaml
@@ -18,11 +18,11 @@
<Setter Property="Height" Value="68"></Setter>
<Setter Property="Margin" Value="5 0 5 5"></Setter>
<Setter Property="CornerRadius" Value="5"></Setter>
- <!--<Setter Property="Effect">
+ <Setter Property="Effect">
<Setter.Value>
<DropShadowEffect BlurRadius="5" ShadowDepth="1" Color="Silver" />
</Setter.Value>
- </Setter>-->
+ </Setter>
</Style>
<Style TargetType="{x:Type touch:LightTouchDataGridRow}">
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Tango.PPC.Events.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Tango.PPC.Events.csproj
index e8d4683ee..e2133e585 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Tango.PPC.Events.csproj
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Tango.PPC.Events.csproj
@@ -76,10 +76,6 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
- <Page Include="EventsViews\ThreadBreakView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
<Page Include="Resources\Styles.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
@@ -102,9 +98,6 @@
<Compile Include="EventsViews\JobEventView.xaml.cs">
<DependentUpon>JobEventView.xaml</DependentUpon>
</Compile>
- <Compile Include="EventsViews\ThreadBreakView.xaml.cs">
- <DependentUpon>ThreadBreakView.xaml</DependentUpon>
- </Compile>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
@@ -187,7 +180,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/Modules/Tango.PPC.Events/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/ViewModels/MainViewVM.cs
index a6e6b7a4e..d2a730cd7 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/ViewModels/MainViewVM.cs
@@ -127,31 +127,15 @@ namespace Tango.PPC.Events.ViewModels
{
if (ev.NotificationTime != EventTypeNotificationTimes.None)
{
- if (!ev.EventType.Persistent)
- {
- CurrentEvents.Insert(0, ev);
- }
- else
- {
- HistoryEvents.Insert(0, ev);
- }
+ CurrentEvents.Insert(0, ev);
var notificationItem = new MessageNotificationItem();
- notificationItem.CanClose = ev.EventType.Persistent;
+ notificationItem.CanClose = false;
notificationItem.Message = ev.EventType.Title;
notificationItem.ExpandedMessage = ev.EventType.Description;
notificationItem.Pressed += async (_, __) =>
{
- if (!ev.EventType.Persistent)
- {
- SelectedEventsSource = EventsSource.CURRENT;
- }
- else
- {
- SelectedEventsSource = EventsSource.HISTORY;
- notificationItem.Dispose();
- }
-
+ SelectedEventsSource = EventsSource.CURRENT;
SelectedEvent = ev;
await NavigationManager.NavigateTo<EventsModule>();
};
@@ -160,23 +144,15 @@ namespace Tango.PPC.Events.ViewModels
{
case EventTypeCategories.Info:
notificationItem.MessageType = MessageNotificationItem.MessageNotificationItemTypes.Info;
- notificationItem.Priority = NotificationItem.NotificationPriority.Normal;
break;
case EventTypeCategories.Warning:
notificationItem.MessageType = MessageNotificationItem.MessageNotificationItemTypes.Warning;
- notificationItem.Priority = NotificationItem.NotificationPriority.High;
break;
case EventTypeCategories.Error:
notificationItem.MessageType = MessageNotificationItem.MessageNotificationItemTypes.Error;
- notificationItem.Priority = NotificationItem.NotificationPriority.VeryHigh;
break;
case EventTypeCategories.Critical:
notificationItem.MessageType = MessageNotificationItem.MessageNotificationItemTypes.Critical;
- notificationItem.Priority = NotificationItem.NotificationPriority.Critical;
- break;
- case EventTypeCategories.Success:
- notificationItem.MessageType = MessageNotificationItem.MessageNotificationItemTypes.Success;
- notificationItem.Priority = NotificationItem.NotificationPriority.VeryHigh;
break;
}
@@ -195,7 +171,7 @@ namespace Tango.PPC.Events.ViewModels
{
InvokeUI(() =>
{
- if (ev.NotificationTime != EventTypeNotificationTimes.None && !ev.EventType.Persistent)
+ if (ev.NotificationTime != EventTypeNotificationTimes.None)
{
CurrentEvents.Remove(ev);
HistoryEvents.Insert(0, ev);
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Views/MainView.xaml
index f0ae4b128..af42a5576 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Views/MainView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Events/Views/MainView.xaml
@@ -143,8 +143,8 @@
<touch:TouchIcon Width="32" Height="32" IsHitTestVisible="False">
<touch:TouchIcon.Style>
<Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Information"/>
- <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"/>
+ <Setter Property="Icon" Value="CheckCircleOutline"/>
+ <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"/>
<Style.Triggers>
<DataTrigger Binding="{Binding Category,Mode=OneWay}" Value="Warning">
<Setter Property="Icon" Value="AlertCircleOutline"/>
@@ -158,10 +158,6 @@
<Setter Property="Icon" Value="Alert"/>
<Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"/>
</DataTrigger>
- <DataTrigger Binding="{Binding Category,Mode=OneWay}" Value="Success">
- <Setter Property="Icon" Value="CheckCircleOutline"/>
- <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"/>
- </DataTrigger>
</Style.Triggers>
</Style>
</touch:TouchIcon.Style>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppBarItems/JobProgressAppBarItemView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppBarItems/JobProgressAppBarItemView.xaml
index 16c6a42be..cdc28335d 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppBarItems/JobProgressAppBarItemView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppBarItems/JobProgressAppBarItemView.xaml
@@ -5,12 +5,11 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
xmlns:local="clr-namespace:Tango.PPC.Jobs.AppBarItems"
- mc:Ignorable="d"
- d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:JobProgressAppBarItem, IsDesignTimeCreatable=False}">
+ mc:Ignorable="d" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:JobProgressAppBarItem, IsDesignTimeCreatable=False}">
<Grid>
<touch:TouchButton Style="{StaticResource TangoFlatButton}" Command="{Binding PressedCommand}" Padding="0">
<StackPanel VerticalAlignment="Center">
- <TextBlock Text="{Binding MachineProvider.MachineOperator.RunningJob.Name,FallbackValue='Job Name'}" FontSize="{StaticResource TangoTitleFontSize}" TextTrimming="CharacterEllipsis"></TextBlock>
+ <TextBlock Text="{Binding MachineProvider.MachineOperator.RunningJob.Name,FallbackValue='Job Name'}" FontSize="{StaticResource TangoTitleFontSize}"></TextBlock>
<ProgressBar Maximum="{Binding MachineProvider.MachineOperator.RunningJobStatus.TotalProgressMinusSettingUp}" Value="{Binding MachineProvider.MachineOperator.RunningJobStatus.ProgressMinusSettingUp}" Margin="0 10 0 5" Background="{StaticResource TangoGrayBrush}" Height="5" Foreground="{StaticResource TangoPrimaryAccentBrush}" BorderThickness="0" />
<DockPanel LastChildFill="False">
<TextBlock DockPanel.Dock="Left">
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppButtons/StartPrintingButton.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppButtons/StartPrintingButton.cs
index 4d6050639..001888c92 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppButtons/StartPrintingButton.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/AppButtons/StartPrintingButton.cs
@@ -15,12 +15,12 @@ namespace Tango.PPC.Jobs.AppButtons
{
op.StatusChanged += Op_StatusChanged;
- Op_StatusChanged(op, op.Status);
+ Op_StatusChanged(this, op.Status);
}
private void Op_StatusChanged(object sender, MachineStatuses status)
{
- IsEnabled = (sender as IMachineOperator).CanPrint;
+ IsEnabled = status == MachineStatuses.ReadyToDye;
}
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobOutlineControl.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobOutlineControl.cs
deleted file mode 100644
index 78f8c90a1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobOutlineControl.cs
+++ /dev/null
@@ -1,319 +0,0 @@
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Reflection;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Media;
-using System.Windows.Shapes;
-using Tango.PMR.Printing;
-using Tango.Touch.Controls;
-
-namespace Tango.PPC.Jobs
-{
- public class JobOutlineControl : Control
- {
- #region Members
-
- private Size _sizeControl = new Size(0, 0);
- ScrollViewer _parentScrollViewer = null;
- public struct LevelOffset
- {
- public const double level_0 = 0.0;
- public const double level_1 = 10.0;
- public const double level_2 = 20.0;
- public const double level_3 = 37.0;
- public const double level_4 = 50.0;
- public const double level_5 = 60.0;
- public const double level_6 = 77.0;
- public const double level_7 = 90.0;
- public const double level_8 = 100.0;
- }
- private double _verticalOffset = 0;
- private double _viewportHeight = 0;
- private const double HEADER_FONT_HEIGHT = 35;
- private const double TITLE_FONT_HEIGHT = 22;
- private const double SUB_TITLE_FONT_HEIGHT = 19;
- private const double NORMAL_FONT_HEIGHT = 17;
- private const double WIDTH = 330;
-
- #endregion members
-
- public JobOutlineControl() : base()
- {
- Unloaded += JobOutlineControl_Unloaded;
- DataContextChanged += JobOutlineControl_DataContextChanged;
- Width = WIDTH;
- }
-
- private void JobOutlineControl_DataContextChanged(object sender, DependencyPropertyChangedEventArgs e)
- {
- if (DataContext == null)
- {
- return;
- }
-
- if (_parentScrollViewer != null)
- {
- _parentScrollViewer.ScrollToTop();
- }
-
- InvalidateVisual();
- }
-
- #region events
- private void JobOutlineControl_Unloaded(object sender, RoutedEventArgs e)
- {
- if (_parentScrollViewer != null)
- {
- _parentScrollViewer.ScrollChanged -= ScrollViewer_ScrollChanged;
- }
- }
-
- private void ScrollViewer_ScrollChanged(object sender, ScrollChangedEventArgs e)
- {
- if (e.VerticalChange == 0.0)
- return;
-
- _verticalOffset = _parentScrollViewer.VerticalOffset;
- _viewportHeight = _parentScrollViewer.ViewportHeight;
- InvalidateVisual();
- }
- #endregion events
-
- #region render
- protected override void OnRender(DrawingContext drawingContext)
- {
- base.OnRender(drawingContext);
-
- if (!(DataContext is JobTicket job)) return;
- if (_parentScrollViewer == null)
- {
- _parentScrollViewer = this.FindAncestor<ScrollViewer>();
- _parentScrollViewer.ScrollChanged += ScrollViewer_ScrollChanged;
- }
- else if (_viewportHeight == 0)
- {
- _viewportHeight = _parentScrollViewer.ActualHeight;
- }
- _sizeControl = new Size();
- _sizeControl.Height += 10;
- DrawHeaderText(drawingContext, "JOB OUTLINE", 30, LevelOffset.level_0);
- _sizeControl.Height += HEADER_FONT_HEIGHT;
-
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "BASIC", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- var basicProps = GetNameValueList(job);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_1, TouchIconKind.Pencil);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- //JobTicket.Spool
- if (job.Spool != null)
- {
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "SPOOL", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- basicProps = GetNameValueList(job.Spool);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_1, TouchIconKind.Pencil);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- }
- //JobTicket.ProcessParameters
- if (job.ProcessParameters != null)
- {
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "PROCESS PARAMETERS", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- basicProps = GetNameValueList(job.ProcessParameters);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_1, TouchIconKind.Settings);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- }
- //JobTicket.ThreadParameters
- if (job.ThreadParameters != null)
- {
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "THREAD PARAMETERS", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- basicProps = GetNameValueList(job.ThreadParameters);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_1, TouchIconKind.Settings);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- }
- //JobTicket.HeadCleaningParameters
- if (job.HeadCleaningParameters != null)
- {
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "HEAD CLEANING PARAMETERS", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- basicProps = GetNameValueList(job.HeadCleaningParameters);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_1, TouchIconKind.Settings);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- }
- //JobTicket.Segments
- if (job.Segments != null)
- {
- _sizeControl.Height += 20;
- DrawHeaderText(drawingContext, "SEGMENTS", 17, LevelOffset.level_0);
- _sizeControl.Height += TITLE_FONT_HEIGHT;
- _sizeControl.Height += 10.0;
- int index = 0;
- foreach (JobSegment seg in job.Segments)
- {
- DrawHeaderText(drawingContext, string.Format("#{0} SEGMENT", ++index), 14, LevelOffset.level_1);
- _sizeControl.Height += SUB_TITLE_FONT_HEIGHT;
- basicProps = GetNameValueList(seg);
- foreach (var prop in basicProps)
- {
- DrawNameValueText(drawingContext, prop, LevelOffset.level_2, TouchIconKind.Pencil);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- //BrushStops
- DrawHeaderText(drawingContext, "BRUSH STOPS", 12, LevelOffset.level_3);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- int indexBrush = 0;
- foreach (JobBrushStop brushstop in seg.BrushStops)
- {
- _sizeControl.Height += 5.0;
- DrawHeaderText(drawingContext, string.Format("#{0} STOP", ++indexBrush), 11, LevelOffset.level_4);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- var brushStops = GetNameValueList(brushstop);
- foreach (var brushstopprop in brushStops)
- {
- DrawNameValueText(drawingContext, brushstopprop, LevelOffset.level_5, TouchIconKind.Pencil);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- DrawHeaderText(drawingContext, "DISPENSERS", 12, LevelOffset.level_6);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- _sizeControl.Height += 5.0;
- int indexDispenser = 0;
- foreach (JobDispenser disp in brushstop.Dispensers)
- {
- DrawHeaderText(drawingContext, string.Format("#{0} DISPENSER", ++indexDispenser), 11, LevelOffset.level_6);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- var dispProperties = GetNameValueList(disp);
- foreach (var dispprop in dispProperties)
- {
- DrawNameValueText(drawingContext, dispprop, LevelOffset.level_7, TouchIconKind.ArrowRightBoldCircle);
- _sizeControl.Height += NORMAL_FONT_HEIGHT;
- }
- }
- }
- }
- }
-
- if (Height != _sizeControl.Height)
- {
- Height = _sizeControl.Height;
- }
- }
- public IEnumerable<Tuple<String, String>> GetNameValueList(object value)
- {
- if (value != null)
- {
- var properties = value.GetType().GetProperties(BindingFlags.Public | BindingFlags.Instance).Where(x => (!x.PropertyType.IsClass && !typeof(IEnumerable).IsAssignableFrom(x.PropertyType)) || x.PropertyType == typeof(String)).ToList();
- return properties.Select(x => new Tuple<string, string>(x.Name, x.GetValue(value).ToString()));
- }
- else
- {
- return null;
- }
- }
- #endregion render
-
- #region drawing
- protected void DrawNameValueText(DrawingContext drawingContext, Tuple<string, string> text, double levelOfOffset, TouchIconKind? icon)
- {
- if (IsInViewPort())
- {
- FormattedText formattedName = new FormattedText(text.Item1 + ": ", System.Globalization.CultureInfo.InvariantCulture, System.Windows.FlowDirection.LeftToRight, new Typeface(this.FontFamily, FontStyles.Normal, FontWeights.Normal, FontStretches.Normal),
- 12, Foreground);
- DrawIconTextIfVisible(drawingContext, levelOfOffset, formattedName, icon);
- double widthOfNameText = formattedName.WidthIncludingTrailingWhitespace + 17 + levelOfOffset;//17 pix for draw icon before text
-
- FormattedText formattedValue = new FormattedText(text.Item2, System.Globalization.CultureInfo.InvariantCulture, System.Windows.FlowDirection.LeftToRight, new Typeface(this.FontFamily, FontStyles.Normal, FontWeights.SemiBold, FontStretches.Normal),
- 12, Foreground);
- DrawIconTextIfVisible(drawingContext, widthOfNameText, formattedValue);
- _sizeControl.Width = Math.Max(_sizeControl.Width, (widthOfNameText + formattedValue.WidthIncludingTrailingWhitespace));
- }
- }
-
- private bool IsInViewPort()
- {
- return (_sizeControl.Height >= _verticalOffset && _sizeControl.Height <= (_verticalOffset + _viewportHeight + 5));
- }
-
- protected void DrawHeaderText(DrawingContext drawingContext, string text, int fontSize, double levelOfOffset)
- {
- if (IsInViewPort())
- {
- FormattedText formattedtext = new FormattedText(text, System.Globalization.CultureInfo.InvariantCulture, System.Windows.FlowDirection.LeftToRight, new Typeface(this.FontFamily, FontStyles.Normal, FontWeights.SemiBold, FontStretches.Normal),
- fontSize, Foreground);
- DrawIconTextIfVisible(drawingContext, levelOfOffset, formattedtext);
- _sizeControl.Width = Math.Max(_sizeControl.Width, (formattedtext.Width + levelOfOffset));
- }
- }
-
- private void DrawIconTextIfVisible(DrawingContext drawingContext, double levelOfOffset, FormattedText formattedText, TouchIconKind? icon = null)
- {
- if (icon is TouchIconKind)
- {
- DrawIcon(drawingContext, (TouchIconKind)icon, new Point(levelOfOffset, _sizeControl.Height));
- levelOfOffset += 17;
- }
- drawingContext.DrawText(formattedText, new Point(levelOfOffset, _sizeControl.Height));
- }
- private void DrawIcon(DrawingContext drawingContext, TouchIconKind kind, Point point)
- {
- GeometryGroup group = GetGeometryByIcon(kind);
- SetGeometryPosition(group, point);
- drawingContext.DrawGeometry(Foreground, new Pen(Brushes.White, 1), group);
-
- }
- private GeometryGroup GetGeometryByIcon(TouchIconKind kind)
- {
- Geometry geometry = Geometry.Parse(TouchIcon.Icons[kind]);
- GeometryGroup group = new GeometryGroup();
- group.Children.Add(geometry);
-
- TransformGroup tg = new TransformGroup();
- tg.Children.Add(new ScaleTransform()
- {
- ScaleX = 10d / geometry.Bounds.Width,
- ScaleY = 10d / geometry.Bounds.Height,
- });
- tg.Children.Add(new TranslateTransform() { });
-
- group.Transform = tg;
- return group;
- }
- private void SetGeometryPosition(GeometryGroup group, Point point)
- {
- TransformGroup tg = group.Transform as TransformGroup;
- (tg.Children[1] as TranslateTransform).X = point.X;
- (tg.Children[1] as TranslateTransform).Y = point.Y + 1;
- }
- #endregion drawing
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobSummeryViewer.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobSummeryViewer.xaml
index afe331145..ba6c13e91 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobSummeryViewer.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/JobSummeryViewer.xaml
@@ -66,9 +66,6 @@
</RectangleGeometry.Rect>
</RectangleGeometry>
</Border.Clip>
- <Border.Background>
- <ImageBrush ImageSource="../Images/JobView/transparent_small.jpg" Stretch="None" TileMode="Tile" AlignmentX="Left" ViewportUnits="Absolute" Viewport="0,0,94,30" />
- </Border.Background>
<Grid>
<ItemsControl ClipToBounds="False" ItemsSource="{Binding EffectiveSegments,IsAsync=True}">
<ItemsControl.ItemsPanel>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/RunningJobViewer.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/RunningJobViewer.xaml
index 5d3f3f1fc..97aedcf89 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/RunningJobViewer.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Controls/RunningJobViewer.xaml
@@ -57,9 +57,6 @@
</ItemsControl>
<Border Grid.Row="1" x:Name="brush_border" ClipToBounds="False" CornerRadius="10" Margin="0 5 0 0">
- <Border.Background>
- <ImageBrush ImageSource="../Images/JobView/transparent_small.jpg" Stretch="None" TileMode="Tile" AlignmentX="Left" ViewportUnits="Absolute" Viewport="0,0,94,30" />
- </Border.Background>
<Border.Clip>
<RectangleGeometry RadiusX="10" RadiusY="10">
<RectangleGeometry.Rect>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Converters/ColorSpaceToVisibilityConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Converters/ColorSpaceToVisibilityConverter.cs
index b1be93793..a8ba66eda 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Converters/ColorSpaceToVisibilityConverter.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Converters/ColorSpaceToVisibilityConverter.cs
@@ -18,17 +18,9 @@ namespace Tango.PPC.Jobs.Converters
if (colorSpace != null)
{
- if (String.IsNullOrWhiteSpace(parameter.ToStringSafe()))
+ if (colorSpace.Space == BL.Enumerations.ColorSpaces.Catalog)
{
- if (colorSpace.Space == BL.Enumerations.ColorSpaces.Catalog)
- {
- return Visibility.Collapsed;
- }
- }
- else
- {
- String[] spaces = parameter.ToString().Split(',');
- return spaces.Contains(colorSpace.Space.ToString()) ? Visibility.Visible : Visibility.Collapsed;
+ return Visibility.Collapsed;
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
index da6989ff6..69eb1fd72 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
@@ -19,85 +19,23 @@
</Grid.RowDefinitions>
<Grid>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoMessageBoxTitleFontSize}">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Text" Value="Color is out of range"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsOutOfGamut}" Value="False">
- <Setter Property="Text" Value="Closest Alternatives"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
- <Setter Property="Margin" Value="20 0 0 0"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
+ <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoMessageBoxTitleFontSize}" Foreground="{StaticResource TangoErrorBrush}">Color is out of range</TextBlock>
<touch:TouchIconButton Command="{Binding CloseCommand}" HorizontalAlignment="Right" Icon="Close" CornerRadius="50" RippleBrush="{StaticResource TangoRippleDarkBrush}" Foreground="{StaticResource TangoDarkForegroundBrush}" Padding="22" />
</Grid>
<StackPanel Orientation="Horizontal" Grid.Row="1" VerticalAlignment="Center">
- <Image Source="../Images/JobView/error.png" Stretch="None" Visibility="{Binding IsOutOfGamut,Converter={StaticResource BooleanToVisibilityConverter}}" />
+ <Image Source="../Images/JobView/error.png" Stretch="None" />
<Ellipse Width="60" Height="60" Margin="20 0 0 0" Fill="{Binding InvalidBrushStop.Brush}" />
<TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Margin="20 0 0 0">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding InvalidBrushStop.BrushColorSpace}" Value="RGB">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
<Run Text="{Binding InvalidBrushStop.Red}"></Run><Run>,</Run>
<Run Text="{Binding InvalidBrushStop.Green}"></Run><Run>,</Run>
<Run Text="{Binding InvalidBrushStop.Blue}"></Run>
</TextBlock>
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Margin="20 0 0 0">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding InvalidBrushStop.BrushColorSpace}" Value="LAB">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- <Run Text="{Binding InvalidBrushStop.L,StringFormat=0.00}"></Run><Run>,</Run>
- <Run Text="{Binding InvalidBrushStop.A,StringFormat=0.00}"></Run><Run>,</Run>
- <Run Text="{Binding InvalidBrushStop.B,StringFormat=0.00}"></Run>
- </TextBlock>
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Margin="20 0 0 0" Text="{Binding InvalidBrushStop.LiquidVolumesOrderedPigmentedString,Mode=OneWay}">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding InvalidBrushStop.BrushColorSpace}" Value="Volume">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
</StackPanel>
<DockPanel Grid.Row="2" Margin="0 0 0 0">
- <TextBlock DockPanel.Dock="Top" Margin="40 0 0 0">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Text" Value="Please select the best alternative"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsOutOfGamut}" Value="False">
- <Setter Property="Text" Value="Please select an alternative"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
+ <TextBlock DockPanel.Dock="Top" Margin="40 0 0 0">Please select the best alternative</TextBlock>
<hive:HexList Width="330" Height="460" Margin="0 20 0 0" RowCount="6" ColumnCount="5" ItemsSource="{Binding Suggestions}" SelectedItem="{Binding SelectedSuggestion,Mode=TwoWay}">
<hive:HexList.ItemContainerStyle>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionViewVM.cs
index db8573322..887e62dd7 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionViewVM.cs
@@ -14,6 +14,6 @@ namespace Tango.PPC.Jobs.Dialogs
/// <seealso cref="Tango.PPC.Jobs.Dialogs.BasicColorCorrectionViewVM" />
public class AdvancedColorCorrectionViewVM : BasicColorCorrectionViewVM
{
- public bool IsOutOfGamut { get; set; }
+
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/BasicColorCorrectionView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/BasicColorCorrectionView.xaml
index bd31b88ce..4c100c2fc 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/BasicColorCorrectionView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/BasicColorCorrectionView.xaml
@@ -59,7 +59,7 @@
</StackPanel>
<DockPanel Grid.Row="2" Margin="0 0 0 0">
- <TextBlock DockPanel.Dock="Top" Margin="40 0 0 0">Please use the closest alternative</TextBlock>
+ <TextBlock DockPanel.Dock="Top" Margin="40 0 0 0">Please select an alternative</TextBlock>
<touch:TouchListBox SelectionMode="Single" Style="{StaticResource TangoNoRippleListBox}" ItemsSource="{Binding Suggestions}" SelectedItem="{Binding SelectedSuggestion,Mode=TwoWay}" Margin="0 20 0 0">
<touch:TouchListBox.ItemContainerStyle>
@@ -81,7 +81,7 @@
</Setter>
<Setter Property="Effect">
<Setter.Value>
- <DropShadowEffect Color="{StaticResource TangoGrayColor}" ShadowDepth="0" BlurRadius="10" Opacity="0" />
+ <DropShadowEffect Color="{StaticResource TangoDarkForegroundColor}" ShadowDepth="0" BlurRadius="10" Opacity="0" />
</Setter.Value>
</Setter>
<Style.Triggers>
@@ -147,10 +147,7 @@
<DockPanel Grid.Row="3" Margin="40 10 20 0" LastChildFill="False">
<touch:TouchButton Command="{Binding MoreOptionsCommand}" VerticalAlignment="Top" Style="{StaticResource TangoLinkButton}" DockPanel.Dock="Left" Foreground="{StaticResource TangoPrimaryAccentBrush}">
- <StackPanel Orientation="Horizontal">
- <Image Source="../Images/color-picker.png" Stretch="None" VerticalAlignment="Center" />
- <TextBlock Margin="5 0 0 0" VerticalAlignment="Center">More Options</TextBlock>
- </StackPanel>
+ More Options
</touch:TouchButton>
<touch:TouchButton Command="{Binding OKCommand}" CornerRadius="25" Style="{StaticResource TangoHollowButton}" DockPanel.Dock="Right" Width="170" Height="50" VerticalAlignment="Bottom">
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/CatalogSelectionView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/CatalogSelectionView.xaml
index 128a93548..ded395e08 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/CatalogSelectionView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/CatalogSelectionView.xaml
@@ -56,7 +56,7 @@
<DataTemplate>
<StackPanel Orientation="Vertical" HorizontalAlignment="Center">
<Image Stretch="Fill" Width="32" Height="32" RenderOptions.BitmapScalingMode="Fant" Source="../Images/NewJob/twine.png"></Image>
- <TextBlock HorizontalAlignment="Center" Margin="0 10 0 0" TextAlignment="Center" Text="{Binding Name}" TextWrapping="Wrap" TextTrimming="CharacterEllipsis"></TextBlock>
+ <TextBlock HorizontalAlignment="Center" Margin="0 10 0 0" Text="{Binding Name}"></TextBlock>
</StackPanel>
</DataTemplate>
</touch:TouchStaticListBox.ItemTemplate>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/ImportJobView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/ImportJobView.xaml
index da51bba27..ac27cc00d 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/ImportJobView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/ImportJobView.xaml
@@ -18,7 +18,7 @@
<TextBlock HorizontalAlignment="Center" Margin="0 20 0 0" FontSize="{StaticResource TangoHeaderFontSize}">IMPORT JOB</TextBlock>
<TextBlock Margin="20 10" HorizontalAlignment="Center" TextWrapping="Wrap" TextAlignment="Center">A job file has been selected from the storage device. press 'IMPORT' to add the job to your job list.</TextBlock>
- <touch:TouchCheckBox IsChecked="{Binding ImportAndEdit}" Margin="40 50 0 0" Visibility="Collapsed">Edit this job after import</touch:TouchCheckBox>
+ <touch:TouchCheckBox IsChecked="{Binding ImportAndEdit}" Margin="40 50 0 0">Edit this job after import</touch:TouchCheckBox>
</StackPanel>
</DockPanel>
</Grid>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent.jpg b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent.jpg
deleted file mode 100644
index cf1d94d12..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent.jpg
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent_small.jpg b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent_small.jpg
deleted file mode 100644
index c682a4c7e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/JobView/transparent_small.jpg
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/color-picker.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/color-picker.png
deleted file mode 100644
index d8d6f8470..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/color-picker.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync.png
deleted file mode 100644
index 46059c5c0..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync_job.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync_job.png
deleted file mode 100644
index 4e46ee447..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Images/sync_job.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItem.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItem.cs
deleted file mode 100644
index 4e3137e1c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItem.cs
+++ /dev/null
@@ -1,32 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common.Notifications;
-
-namespace Tango.PPC.Jobs.NotificationItems
-{
- /// <summary>
- /// Represents a simple text message notification item which can be inserted into the application notifications panel.
- /// </summary>
- /// <seealso cref="Tango.PPC.Common.Notifications.NotificationItem" />
- public class NewSynchronizardJobsNotificationItem : NotificationItem
- {
- /// <summary>
- /// Initializes a new instance of the <see cref="UpdateAvailableNotificationItem"/> class.
- /// </summary>
- public NewSynchronizardJobsNotificationItem()
- {
- CanClose = true;
- }
-
- /// <summary>
- /// Gets or sets the view type.
- /// </summary>
- public override Type ViewType
- {
- get { return typeof(NewSynchronizardJobsNotificationItemView); }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml
deleted file mode 100644
index 5a57e3db7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml
+++ /dev/null
@@ -1,30 +0,0 @@
-<UserControl x:Class="Tango.PPC.Jobs.NotificationItems.NewSynchronizardJobsNotificationItemView"
- 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:local="clr-namespace:Tango.PPC.Jobs.NotificationItems"
- xmlns:common="clr-namespace:Tango.PPC.Common.Converters"
- mc:Ignorable="d"
- x:Name="MessageNotificationItemControl"
- d:DesignHeight="60" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:NewSynchronizardJobsNotificationItem, IsDesignTimeCreatable=False}" MinHeight="90" Height="90" MaxHeight="150" Background="White">
-
- <UserControl.Resources>
- <BitmapImage x:Key="icon" UriSource="../Images/sync_job.png" />
- </UserControl.Resources>
-
- <Grid>
- <Border BorderThickness="0 0 0 2" BorderBrush="{StaticResource TangoPrimaryAccentBrush}" Padding="15">
- <DockPanel>
- <Image Source="{StaticResource icon}" MaxHeight="50" />
-
- <Grid>
- <TextBlock Margin="20 0 0 0" VerticalAlignment="Center">
- New job definitions were synchronized with your machine. Tap to refresh your job list.
- </TextBlock>
- </Grid>
- </DockPanel>
- </Border>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml.cs
deleted file mode 100644
index 33db09386..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/NotificationItems/NewSynchronizardJobsNotificationItemView.xaml.cs
+++ /dev/null
@@ -1,30 +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;
-
-namespace Tango.PPC.Jobs.NotificationItems
-{
- /// <summary>
- /// Represents the <see cref="UpdateAvailableNotificationItemView"/> view.
- /// </summary>
- /// <seealso cref="System.Windows.Controls.UserControl" />
- /// <seealso cref="System.Windows.Markup.IComponentConnector" />
- public partial class NewSynchronizardJobsNotificationItemView : UserControl
- {
- public NewSynchronizardJobsNotificationItemView()
- {
- InitializeComponent();
- }
- }
-}
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 33b9de808..aedf09ce7 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
@@ -124,10 +124,6 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
- <Page Include="NotificationItems\NewSynchronizardJobsNotificationItemView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
<Page Include="Resources\Styles.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -167,7 +163,6 @@
</Compile>
<Compile Include="AppButtons\StartPrintingButton.cs" />
<Compile Include="AppButtons\StopPrintingButton.cs" />
- <Compile Include="Controls\JobOutlineControl.cs" />
<Compile Include="Controls\RunningJobViewer.xaml.cs">
<DependentUpon>RunningJobViewer.xaml</DependentUpon>
</Compile>
@@ -232,10 +227,6 @@
<Compile Include="NavigationObjects\JobNavigationObject.cs" />
<Compile Include="NavigationObjects\JobSummeryNavigationObject.cs" />
<Compile Include="NavigationObjects\TwineCatalogNavigationObject.cs" />
- <Compile Include="NotificationItems\NewSynchronizardJobsNotificationItem.cs" />
- <Compile Include="NotificationItems\NewSynchronizardJobsNotificationItemView.xaml.cs">
- <DependentUpon>NewSynchronizardJobsNotificationItemView.xaml</DependentUpon>
- </Compile>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
@@ -491,25 +482,10 @@
<Resource Include="Images\small-cards-view - blue.png" />
<Resource Include="Images\small-cards-view.png" />
</ItemGroup>
- <ItemGroup>
- <Resource Include="Images\color-picker.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\sync.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\JobView\transparent.jpg" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\JobView\transparent_small.jpg" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\sync_job.png" />
- </ItemGroup>
<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/Modules/Tango.PPC.Jobs/ViewModels/JobProgressViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobProgressViewVM.cs
index 8d5bd284d..103a10b28 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobProgressViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobProgressViewVM.cs
@@ -6,10 +6,8 @@ using System.Threading.Tasks;
using Tango.BL.Entities;
using Tango.Core.Commands;
using Tango.Integration.Operation;
-using Tango.PMR.Printing;
using Tango.PPC.Common;
using Tango.PPC.Common.Navigation;
-using Tango.PPC.Common.Notifications;
using Tango.PPC.Jobs.AppBarItems;
using Tango.PPC.Jobs.AppButtons;
using Tango.PPC.Jobs.Dialogs;
@@ -49,26 +47,6 @@ namespace Tango.PPC.Jobs.ViewModels
set { _runningJobStatus = value; RaisePropertyChangedAuto(); }
}
- private bool _isDisplayJobOutline;
- /// <summary>
- /// Gets or sets a value indicating whether to display the job outline.
- /// </summary>
- public bool IsDisplayJobOutline
- {
- get { return _isDisplayJobOutline; }
- set { _isDisplayJobOutline = value; RaisePropertyChangedAuto(); }
- }
-
- private JobTicket _jobOutlineTicket;
- /// <summary>
- /// Gets or sets the job outline ticket.
- /// </summary>
- public JobTicket JobOutlineTicket
- {
- get { return _jobOutlineTicket; }
- set { _jobOutlineTicket = value; RaisePropertyChangedAuto(); }
- }
-
#endregion
#region Commands
@@ -81,16 +59,6 @@ namespace Tango.PPC.Jobs.ViewModels
/// </value>
public RelayCommand GoToJobCommand { get; set; }
- /// <summary>
- /// Gets or sets the display job outline command.
- /// </summary>
- public RelayCommand DisplayJobOutlineCommand { get; set; }
-
- /// <summary>
- /// Gets or sets the hide job outline command.
- /// </summary>
- public RelayCommand HideJobOutlineCommand { get; set; }
-
#endregion
public JobProgressViewVM()
@@ -99,21 +67,14 @@ namespace Tango.PPC.Jobs.ViewModels
_stop_job_btn.Pressed += _stop_job_btn_Pressed;
GoToJobCommand = new RelayCommand(GoToJob);
- DisplayJobOutlineCommand = new RelayCommand(DisplayJobOutline);
- HideJobOutlineCommand = new RelayCommand(HideJobOutline);
}
- #region Private Methods
-
- private void HideJobOutline()
- {
- IsDisplayJobOutline = false;
- }
-
- private void DisplayJobOutline()
+ private void _stop_job_btn_Pressed()
{
- JobOutlineTicket = _handler.JobTicket;
- IsDisplayJobOutline = true;
+ if (_handler != null)
+ {
+ _handler.Cancel();
+ }
}
private void GoToJob()
@@ -122,8 +83,6 @@ namespace Tango.PPC.Jobs.ViewModels
NavigationManager.ClearHistoryExcept<JobsView>();
}
- #endregion
-
#region Override Methods
/// <summary>
@@ -135,32 +94,41 @@ namespace Tango.PPC.Jobs.ViewModels
}
/// <summary>
+ /// Called when the navigation system has navigated from this VM view.
+ /// </summary>
+ public override void OnNavigatedFrom()
+ {
+ base.OnNavigatedFrom();
+
+ if (MachineProvider.MachineOperator.IsPrinting && _handler != null && !_handler.IsCanceled)
+ {
+ NotificationProvider.PushAppBarItem<JobProgressAppBarItem>().Pressed += (_, __) =>
+ {
+ NotificationProvider.CurrentAppBarItem.Close();
+ NavigationManager.NavigateTo<JobsModule>(nameof(JobProgressView));
+ };
+ }
+ }
+
+ /// <summary>
/// Called when the navigation system has navigated to this VM view.
/// </summary>
public override void OnNavigatedTo()
{
base.OnNavigatedTo();
- IsDisplayJobOutline = false;
-
- if (_handler != null && !_handler.Status.IsFailed)
+ if (NotificationProvider.HasAppBarItem && NotificationProvider.CurrentAppBarItem is JobProgressAppBarItem)
{
- _stop_job_btn.Push();
+ NotificationProvider.CurrentAppBarItem.Close();
}
+
+ _stop_job_btn.Push();
}
#endregion
#region Event Handlers
- private void _stop_job_btn_Pressed()
- {
- if (_handler != null)
- {
- _handler.Cancel();
- }
- }
-
/// <summary>
/// Handles the PrintingStarted event of the MachineOperator.
/// </summary>
@@ -173,10 +141,8 @@ namespace Tango.PPC.Jobs.ViewModels
e.JobHandler.StatusChanged += JobHandler_StatusChanged;
e.JobHandler.SpoolChangeRequired += JobHandler_SpoolChangeRequired;
e.JobHandler.Stopped += JobHandler_Stopped;
- e.JobHandler.CanCancelChanged += JobHandler_CanCancelChanged;
_stop_job_btn.Push();
- _stop_job_btn.IsEnabled = true;
}
/// <summary>
@@ -206,18 +172,12 @@ namespace Tango.PPC.Jobs.ViewModels
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
private void JobHandler_Stopped(object sender, EventArgs e)
{
- if (_stop_job_btn != null)
+ if (NotificationProvider.HasAppBarItem && NotificationProvider.CurrentAppBarItem is JobProgressAppBarItem)
{
- _stop_job_btn.Pop();
+ NotificationProvider.CurrentAppBarItem.Close();
}
- if (_handler != null)
- {
- _handler.StatusChanged -= JobHandler_StatusChanged;
- _handler.SpoolChangeRequired -= JobHandler_SpoolChangeRequired;
- _handler.Stopped -= JobHandler_Stopped;
- _handler.CanCancelChanged -= JobHandler_CanCancelChanged;
- }
+ _stop_job_btn.Pop();
}
/// <summary>
@@ -233,16 +193,6 @@ namespace Tango.PPC.Jobs.ViewModels
});
}
- /// <summary>
- /// Handles the CanCancelChanged event of the JobHandler control.
- /// </summary>
- /// <param name="sender">The source of the event.</param>
- /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
- private void JobHandler_CanCancelChanged(object sender, EventArgs e)
- {
- _stop_job_btn.IsEnabled = _handler.CanCancel;
- }
-
#endregion
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobSummeryViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobSummeryViewVM.cs
index a2acf5893..bff6beff5 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobSummeryViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobSummeryViewVM.cs
@@ -26,7 +26,6 @@ namespace Tango.PPC.Jobs.ViewModels
{
private ObservablesContext _context;
private bool _canStartJob;
- private bool _startingJob;
private bool _isPreparingJob;
/// <summary>
@@ -60,6 +59,7 @@ namespace Tango.PPC.Jobs.ViewModels
set { _estimatedDuration = value; RaisePropertyChangedAuto(); }
}
+
/// <summary>
/// Gets or sets the dye command.
/// </summary>
@@ -96,20 +96,12 @@ namespace Tango.PPC.Jobs.ViewModels
/// </summary>
private async void StartJob()
{
- if (_startingJob) return;
-
- _startingJob = true;
- _canStartJob = false;
- InvalidateRelayCommands();
- NavigationManager.IsBackEnabled = false;
-
try
{
LogManager.Log("Start job command pressed. Starting job and navigating to job progress view...");
await PrintingManager.Print(Job, _context);
await NavigationManager.NavigateTo<JobsModule>(false, nameof(JobProgressView));
- _startingJob = false;
}
catch (InsufficientLiquidQuantityException)
{
@@ -120,13 +112,6 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log(ex, "Could not start the current job.");
await NotificationProvider.ShowError($"{ex.Message}");
}
- finally
- {
- _startingJob = false;
- _canStartJob = true;
- NavigationManager.IsBackEnabled = true;
- InvalidateRelayCommands();
- }
}
/// <summary>
@@ -145,6 +130,16 @@ namespace Tango.PPC.Jobs.ViewModels
_context = obj.Context;
Job = obj.Job;
+ if (Job.ColorSpace.Space == BL.Enumerations.ColorSpaces.Catalog)
+ {
+ if (_context.ColorCatalogs.SingleOrDefault(x => x.Guid == Job.ColorCatalogGuid) == null)
+ {
+ await NotificationProvider.ShowError("The selected color catalog for this job could not be found.\nCannot load job.");
+ await NavigationManager.NavigateBack();
+ return;
+ }
+ }
+
IsPreparingJob = true;
Job = await new JobBuilder(_context).Set(Job.Guid)
@@ -155,15 +150,7 @@ namespace Tango.PPC.Jobs.ViewModels
.WithBrushStops()
.BuildAsync();
- if (Job.ColorSpace.Space == BL.Enumerations.ColorSpaces.Catalog)
- {
- if (_context.ColorCatalogs.SingleOrDefault(x => x.Guid == Job.ColorCatalogGuid) == null)
- {
- await NotificationProvider.ShowError("The selected color catalog for this job could not be found.\nCannot load job.");
- await NavigationManager.NavigateBack();
- return;
- }
- }
+ await Task.Delay(2000);
await Task.Factory.StartNew(() =>
{
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 5e90d3b5b..4e1e58dba 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
@@ -56,7 +56,6 @@ namespace Tango.PPC.Jobs.ViewModels
private ActionTimer _volumeConversionTimer;
private IColorConverter _converter;
private string _current_job_string;
- private bool startingJob = false;
#region Properties
@@ -413,7 +412,7 @@ namespace Tango.PPC.Jobs.ViewModels
RepeatSampleDyeCommand = new RelayCommand(RepeatSampleDye);
AnotherSampleCommand = new RelayCommand(DyeAnotherSample);
InvokeFineTuningPaletteCommand = new RelayCommand<FineTuneItem>(InvokeFineTuningPalette);
- ResetFineTuningCommand = new RelayCommand(() => ResetFineTuning(true));
+ ResetFineTuningCommand = new RelayCommand(ResetFineTuning);
StartFineTuningCommand = new RelayCommand(StartFineTuning, () => FineTuneItems.Any(x => x.IsSelected) && CanStartJob());
RepeatFineTuningCommand = new RelayCommand(RepeatFineTuning);
ApproveFineTuningCommand = new RelayCommand(ApproveFineTuning);
@@ -469,7 +468,7 @@ namespace Tango.PPC.Jobs.ViewModels
Job.ValidateOnPropertyChanged = true;
LogManager.Log("Loading RMLS...");
- Rmls = (await new RmlsCollectionBuilder(_db).SetAll().WithActiveParametersGroup().WithCAT(Job.MachineGuid).WithCCT().WithLiquidFactors().WithSpools().ForHeadType(MachineProvider.Machine.MachineHeadType).ForSite(MachineProvider.Machine.SiteGuid).BuildAsync()).ToList();
+ Rmls = (await new RmlsCollectionBuilder(_db).SetAll().WithActiveParametersGroup().WithCAT(Job.MachineGuid).WithCCT().WithLiquidFactors().BuildAsync()).ToList();
LogManager.Log("Loading Color Spaces...");
ColorSpaces = await _db.ColorSpaces.ToListAsync();
LogManager.Log("Loading Spool Types...");
@@ -479,7 +478,7 @@ namespace Tango.PPC.Jobs.ViewModels
if (Job.ColorSpace.Space == BL.Enumerations.ColorSpaces.Catalog)
{
- SelectedCatalog = await new CatalogBuilder(_db).Set(Job.ColorCatalogGuid).WithGroups().WithItems().BuildAsync();
+ SelectedCatalog = await new ColorCatalogBuilder(_db).Set(Job.ColorCatalogGuid).WithGroups().WithItems().BuildAsync();
if (SelectedCatalog != null)
{
@@ -546,15 +545,18 @@ namespace Tango.PPC.Jobs.ViewModels
}
catch (Exception ex)
{
- IsFree = true;
- LogManager.Log(ex, $"Error loading job '{(_job_to_load != null ? _job_to_load.Name : "null")}'");
+ LogManager.Log(ex, $"Error loading job '{_job_to_load.Name}'");
await NotificationProvider.ShowError("An error occurred while trying to load the selected job.");
_can_navigate_back = true;
await NavigationManager.NavigateBack();
}
finally
{
- IsFree = true;
+ InvokeUI(() =>
+ {
+ IsFree = true;
+ //NotificationProvider.ReleaseGlobalBusyMessage();
+ });
}
}
@@ -591,9 +593,7 @@ namespace Tango.PPC.Jobs.ViewModels
}
Job.LastUpdated = DateTime.UtcNow;
- Job.IsSynchronized = false;
Job.JobStatus = BL.Enumerations.JobStatuses.Draft;
- Job.MarkModified(_db);
await _db.SaveChangesAsync();
_current_job_string = Job.ToJobFileWhenLoaded().ToString();
@@ -645,16 +645,11 @@ namespace Tango.PPC.Jobs.ViewModels
/// </summary>
private async void StartJob()
{
- if (startingJob) return;
-
try
{
- Debug.WriteLine("Job Starting...");
- startingJob = true;
LogManager.Log("Start job command pressed. Starting job and navigating to job progress view...");
- var handler = await PrintingManager.Print(Job, _db);
+ await PrintingManager.Print(Job, _db);
await NavigationManager.NavigateTo<JobsModule>(nameof(JobProgressView));
- startingJob = false;
}
catch (InsufficientLiquidQuantityException)
{
@@ -665,10 +660,6 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log(ex, "Could not start the current job.");
await NotificationProvider.ShowError($"{ex.Message}.");
}
- finally
- {
- startingJob = false;
- }
}
/// <summary>
@@ -677,7 +668,8 @@ namespace Tango.PPC.Jobs.ViewModels
private bool CanStartJob()
{
return
- Job != null && Job.Validate(_db) && !Job.Segments.SelectMany(x => x.BrushStops).Where(x => !x.IsTransparent && !x.IsWhite).ToList().Exists(x => x.IsOutOfGamut || x.IsLiquidVolumesOutOfRange);
+ Job != null && Job.Validate(_db) &&
+ !Job.Segments.SelectMany(x => x.BrushStops).ToList().Exists(x => x.IsOutOfGamut);
}
#endregion
@@ -717,7 +709,7 @@ namespace Tango.PPC.Jobs.ViewModels
try
{
LogManager.Log("Adding new solid segment...");
- var s = Job.AddSolidSegment(Settings.DefaultSegmentLength > 0 ? Settings.DefaultSegmentLength : 10);
+ var s = Job.AddSolidSegment(MachineProvider.Machine.DefaultSegmentLength > 0 ? MachineProvider.Machine.DefaultSegmentLength : 10);
SetSegmentLiquidVolumesIfVolume(s);
return s;
}
@@ -737,7 +729,7 @@ namespace Tango.PPC.Jobs.ViewModels
try
{
LogManager.Log("Adding new gradient segment...");
- var s = Job.AddGradientSegment(Settings.DefaultSegmentLength > 0 ? Settings.DefaultSegmentLength : 10);
+ var s = Job.AddGradientSegment(MachineProvider.Machine.DefaultSegmentLength > 0 ? MachineProvider.Machine.DefaultSegmentLength : 10);
SetSegmentLiquidVolumesIfVolume(s);
return s;
}
@@ -767,7 +759,14 @@ namespace Tango.PPC.Jobs.ViewModels
draggedSegment.SegmentIndex = droppedSegment.SegmentIndex + 1;
}
- ArrangeSegmentsIndices();
+ int index = 1;
+
+ foreach (var segment in Job.Segments.OrderBy(x => x.SegmentIndex))
+ {
+ segment.SegmentIndex = index++;
+ }
+
+ SegmentsCollectionView.Refresh();
}
/// <summary>
@@ -830,14 +829,10 @@ namespace Tango.PPC.Jobs.ViewModels
private void ArrangeSegmentsIndices()
{
- int index = 1;
-
- foreach (var segment in Job.Segments.OrderBy(x => x.SegmentIndex))
+ for (int i = 0; i < Job.Segments.Count; i++)
{
- segment.SegmentIndex = index++;
+ Job.Segments[i].SegmentIndex = i + 1;
}
-
- SegmentsCollectionView.Refresh();
}
#endregion
@@ -885,55 +880,23 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log($"Invoking triplet color adjustment dialog for brush stop {brushStop.StopIndex} at segment {brushStop.Segment.SegmentIndex}.");
LogManager.Log("Retrieving color conversion suggestions for brush stop...");
- PMR.ColorLab.ConversionOutput conversionOutput = null;
-
- if (brushStop.IsOutOfGamut)
- {
- conversionOutput = _converter.Convert(brushStop, false);
- }
+ var conversionOutput = _converter.Convert(brushStop, true);
BasicColorCorrectionViewVM vm = null;
- List<ColorConversionSuggestion> suggestions = null;
- if (brushStop.IsOutOfGamut)
+ vm = await NotificationProvider.ShowDialog<BasicColorCorrectionViewVM>(new BasicColorCorrectionViewVM()
{
- vm = await NotificationProvider.ShowDialog<BasicColorCorrectionViewVM>(new BasicColorCorrectionViewVM()
- {
- InvalidBrushStop = brushStop,
- Suggestions = new List<ColorConversionSuggestion>() { new ColorConversionSuggestion(conversionOutput.SingleCoordinates, 0, 0) },
- });
- }
+ InvalidBrushStop = brushStop,
+ Suggestions = conversionOutput.CreateTrippletSuggestions(),
+ });
- if (vm == null || vm.Result == BasicColorCorrectionViewVM.ColorCorrectionDialogResult.MoreOptions)
+ if (vm.Result == BasicColorCorrectionViewVM.ColorCorrectionDialogResult.MoreOptions)
{
- NotificationProvider.SetGlobalBusyMessage("Generating color hive...");
-
- await Task.Factory.StartNew(() =>
- {
- conversionOutput = _converter.Convert(brushStop, true);
-
- suggestions = conversionOutput.CreateHiveSuggestions();
-
- if (vm == null)
- {
- var center = suggestions.GetCenterSuggestion();
- center.Coordinates.Red = brushStop.Red;
- center.Coordinates.Green = brushStop.Green;
- center.Coordinates.Blue = brushStop.Blue;
-
- center.Coordinates.L = brushStop.L;
- center.Coordinates.A = brushStop.A;
- center.Coordinates.B = brushStop.B;
- }
- });
-
- NotificationProvider.ReleaseGlobalBusyMessage();
LogManager.Log("Invoking hive color conversion dialog...");
vm = await NotificationProvider.ShowDialog<AdvancedColorCorrectionViewVM>(new AdvancedColorCorrectionViewVM()
{
InvalidBrushStop = brushStop,
- Suggestions = suggestions,
- IsOutOfGamut = brushStop.IsOutOfGamut,
+ Suggestions = conversionOutput.CreateHiveSuggestions(),
});
}
@@ -953,13 +916,6 @@ namespace Tango.PPC.Jobs.ViewModels
brushStop.A = vm.SelectedSuggestion.Coordinates.A;
brushStop.B = vm.SelectedSuggestion.Coordinates.B;
}
- else if (brushStop.BrushColorSpace == BL.Enumerations.ColorSpaces.Volume)
- {
- if (vm.SelectedSuggestion != suggestions.GetCenterSuggestion())
- {
- vm.SelectedSuggestion.ApplyOnBrushStop(brushStop);
- }
- }
brushStop.Corrected = true;
brushStop.IsOutOfGamut = false;
@@ -971,11 +927,6 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log(ex, "Error while invoking color adjustment dialog.");
await NotificationProvider.ShowError("An error occurred while trying to convert the selected color.");
}
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- DyeCommand.RaiseCanExecuteChanged();
- }
}
/// <summary>
@@ -985,7 +936,7 @@ namespace Tango.PPC.Jobs.ViewModels
[HandleProcessCorruptedStateExceptions]
public void OnBrushStopFieldValueChanged(BrushStop stop)
{
- if (stop != null && stop.ColorSpace != null)
+ if (stop != null)
{
stop.Corrected = false;
stop.OutOfGamutChecked = false;
@@ -1003,11 +954,6 @@ namespace Tango.PPC.Jobs.ViewModels
stop.Blue = output.SingleCoordinates.Blue;
stop.Corrected = true;
stop.IsOutOfGamut = false;
-
- InvokeUI(() =>
- {
- DyeCommand.RaiseCanExecuteChanged();
- });
}
catch (Exception ex)
{
@@ -1128,7 +1074,7 @@ namespace Tango.PPC.Jobs.ViewModels
/// <summary>
/// Synchronizes the fine tune items to brush stops.
/// </summary>
- private async void SyncFineTuneItemsToBrushStops(bool displayBusy = false)
+ private void SyncFineTuneItemsToBrushStops()
{
try
{
@@ -1140,27 +1086,18 @@ namespace Tango.PPC.Jobs.ViewModels
}
else
{
- if (displayBusy)
- {
- NotificationProvider.SetGlobalBusyMessage("Generating suggestions...");
- }
-
FineTuneItems.Clear();
- foreach (var stop in Job.Segments.SelectMany(x => x.BrushStops).Where(x => !x.IsTransparent).Where(x => x.ColorSpace.Space == BL.Enumerations.ColorSpaces.RGB || x.ColorSpace.Space == BL.Enumerations.ColorSpaces.LAB).DistinctBy(x => x.Color))
+ foreach (var stop in Job.Segments.SelectMany(x => x.BrushStops).Where(x => x.ColorSpace.Space == BL.Enumerations.ColorSpaces.RGB || x.ColorSpace.Space == BL.Enumerations.ColorSpaces.LAB).DistinctBy(x => x.Color))
{
- var conversionoutput = await _converter.ConvertAsync(stop, true);
- FineTuneItem item = new FineTuneItem(conversionoutput);
- item.BrushStop = stop;
+ FineTuneItem item = new FineTuneItem(_converter.Convert(stop, true));
item.BrushStops = Job.Segments.SelectMany(x => x.BrushStops).Where(x => x.Color == stop.Color).ToList();
- item.SelectedSuggestion = item.Suggestions.GetCenterSuggestion();
+ item.SelectedSuggestion = item.Suggestions[item.Suggestions.Count / 2];
item.SelectedChanged += () => StartFineTuningCommand.RaiseCanExecuteChanged();
FineTuneItems.Add(item);
}
_jobs_fine_tune_items[Job.Guid] = FineTuneItems.ToList();
-
- NotificationProvider.ReleaseGlobalBusyMessage();
}
ApprovalFineTuneItems = FineTuneItems.Where(x => x.IsSelected).ToObservableCollection();
@@ -1172,10 +1109,6 @@ namespace Tango.PPC.Jobs.ViewModels
{
LogManager.Log(ex, "Error while trying to synchronize fine tuning items with brush stops.");
}
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- }
}
/// <summary>
@@ -1202,23 +1135,19 @@ namespace Tango.PPC.Jobs.ViewModels
LogManager.Log(ex, "Error invoking the fine tunning palette");
await NotificationProvider.ShowError("An error occurred while trying to display the fine tunning palette.");
}
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- }
}
/// <summary>
/// Resets the fine tuning.
/// </summary>
- private void ResetFineTuning(bool displayBusy = false)
+ private void ResetFineTuning()
{
if (Job != null && _jobs_fine_tune_items.ContainsKey(Job.Guid))
{
_jobs_fine_tune_items.Remove(Job.Guid);
}
- SyncFineTuneItemsToBrushStops(displayBusy);
+ SyncFineTuneItemsToBrushStops();
}
/// <summary>
@@ -1428,8 +1357,6 @@ namespace Tango.PPC.Jobs.ViewModels
{
bool result = true;
- if (!IsFree) return false;
-
if (!_can_navigate_back)
{
bool jobChainged = false;
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobsViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobsViewVM.cs
index 64931cbe3..a7b06f6eb 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobsViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobsViewVM.cs
@@ -36,9 +36,6 @@ using System.Windows.Media.Imaging;
using Tango.Touch.Components;
using Tango.PPC.Jobs.ViewContracts;
using Tango.Core.ExtensionMethods;
-using Tango.PPC.Common.Synchronization;
-using Tango.PPC.Jobs.NotificationItems;
-using Tango.PPC.Storage.Models;
namespace Tango.PPC.Jobs.ViewModels
{
@@ -49,10 +46,7 @@ namespace Tango.PPC.Jobs.ViewModels
public class JobsViewVM : PPCViewModel<IJobsView>
{
private ObservablesContext _db; //Holds the db context for the job list.
- private ObservableCollection<ColorCatalog> _catalogs; //Holds the available color catalogs for the site.
- private ObservableCollection<Rml> _rmls; //Holds the available RML for the site.
- private List<ColorSpace> _colorSpaces; //Holds the available color spaces.
- private bool _isJobsSynchronizationNotificationActive;
+ private ObservableCollection<ColorCatalog> _catalogs; //Holds the available color catalogs.
public enum JobsCategory
{
@@ -324,7 +318,7 @@ namespace Tango.PPC.Jobs.ViewModels
RaiseMessage(new JobSelectedMessage() { Job = job, Context = _db });
- if (!directlyToEdit && MachineProvider.MachineOperator.CanPrint)
+ if (!directlyToEdit && MachineProvider.MachineOperator.Status == Integration.Operation.MachineStatuses.ReadyToDye)
{
await NavigationManager.NavigateWithObject<JobsModule, JobSummeryView, JobSummeryNavigationObject>(new JobSummeryNavigationObject()
{
@@ -355,8 +349,6 @@ namespace Tango.PPC.Jobs.ViewModels
_db = ObservablesContext.CreateDefault();
- _colorSpaces = _db.ColorSpaces.ToList();
-
var jobs = new JobsCollectionBuilder(_db).Set(x => x.MachineGuid == MachineProvider.Machine.Guid).WithSegments().WithBrushStops().WithCustomer().WithColorSpace().Build();
InvokeUI(() =>
@@ -415,15 +407,10 @@ namespace Tango.PPC.Jobs.ViewModels
var machine = MachineProvider.Machine;
JobCreationViewVM vm = new JobCreationViewVM(
- Settings.SupportedJobTypes.Count > 0 ? Settings.SupportedJobTypes : Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToList(),
- Settings.SupportedColorSpaces.Count > 0 ? Settings.SupportedColorSpaces : Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace() || (ApplicationManager.IsInTechnicianMode && x == ColorSpaces.Volume)).ToList()
+ machine.SupportedJobTypes.Count > 0 ? machine.SupportedJobTypes : Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToList(),
+ machine.SupportedColorSpaces.Count > 0 ? machine.SupportedColorSpaces : Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace() || (ApplicationManager.IsInTechnicianMode && x == ColorSpaces.Volume)).ToList()
);
- if (_catalogs.Count == 0)
- {
- vm.SupportedColorSpaces.Remove(ColorSpaces.Catalog);
- }
-
CatalogSelectionViewVM catalogVM = new CatalogSelectionViewVM(_catalogs.ToList(), _catalogs.ToList().SingleOrDefault(x => x.Guid == settings.LastSelectedCatalogGuid));
if (settings.LastJobType != null)
@@ -432,7 +419,7 @@ namespace Tango.PPC.Jobs.ViewModels
}
else
{
- vm.SelectedJobType = Settings.SupportedJobTypes.FirstOrDefault();
+ vm.SelectedJobType = machine.SupportedJobTypes.FirstOrDefault();
}
if (settings.LastJobColorSpace != null)
@@ -441,7 +428,7 @@ namespace Tango.PPC.Jobs.ViewModels
}
else
{
- var space = Settings.SupportedColorSpaces.FirstOrDefault();
+ var space = machine.SupportedColorSpaces.FirstOrDefault();
vm.SelectedColorSpace = space.IsUserSpace() ? space : ColorSpaces.Catalog;
}
@@ -459,7 +446,7 @@ namespace Tango.PPC.Jobs.ViewModels
if (twnFile == null)
{
- if (Settings.SupportedJobTypes.Count != 1 || Settings.SupportedColorSpaces.Count != 1)
+ if (machine.SupportedJobTypes.Count != 1 || machine.SupportedColorSpaces.Count != 1)
{
vm = await NotificationProvider.ShowDialog<JobCreationViewVM>(vm);
if (!vm.DialogResult) return;
@@ -489,14 +476,14 @@ namespace Tango.PPC.Jobs.ViewModels
}
else
{
- vm.SelectedJobType = Settings.SupportedJobTypes.First();
- vm.SelectedColorSpace = Settings.SupportedColorSpaces.First();
+ vm.SelectedJobType = machine.SupportedJobTypes.First();
+ vm.SelectedColorSpace = machine.SupportedColorSpaces.First();
}
}
settings.LastJobType = vm.SelectedJobType;
settings.LastJobColorSpace = vm.SelectedColorSpace;
-
+
if (vm.SelectedColorSpace == ColorSpaces.Catalog)
{
settings.LastSelectedCatalogGuid = catalogVM.SelectedCatalog.Guid;
@@ -505,8 +492,6 @@ namespace Tango.PPC.Jobs.ViewModels
settings.Save();
Job job = new Job();
- job.LastUpdated = DateTime.UtcNow;
- job.JobSource = JobSource.Local;
job.Name = "untitled";
job.NumberOfHeads = 1;
job.NumberOfUnits = 1;
@@ -516,12 +501,11 @@ namespace Tango.PPC.Jobs.ViewModels
job.JobType = vm.SelectedJobType;
job.EnableLubrication = true;
job.ColorSpaceGuid = Adapter.ColorSpaces.FirstOrDefault(x => x.Code == vm.SelectedColorSpace.ToInt32()).Guid;
- job.ColorSpace = _colorSpaces.SingleOrDefault(x => x.Guid == job.ColorSpaceGuid);
job.MachineGuid = MachineProvider.Machine.Guid;
- job.UserGuid = null;
- job.RmlGuid = (Settings.DefaultRmlGuid != null && _rmls.Select(x => x.Guid).Contains(Settings.DefaultRmlGuid)) ? Settings.DefaultRmlGuid : _rmls.FirstOrDefault().Guid;
+ job.UserGuid = AuthenticationProvider.CurrentUser.Guid;
+ job.RmlGuid = machine.DefaultRml != null ? machine.DefaultRmlGuid : Adapter.Rmls.FirstOrDefault().Guid;
job.WindingMethodGuid = Adapter.WindingMethods.FirstOrDefault().Guid;
- job.SpoolTypeGuid = Settings.DefaultSpoolTypeGuid != null ? Settings.DefaultSpoolTypeGuid : Adapter.SpoolTypes.FirstOrDefault().Guid;
+ job.SpoolTypeGuid = machine.DefaultSpoolType != null ? machine.DefaultSpoolTypeGuid : Adapter.SpoolTypes.FirstOrDefault().Guid;
if (vm.SelectedColorSpace == ColorSpaces.Catalog)
{
@@ -535,11 +519,11 @@ namespace Tango.PPC.Jobs.ViewModels
if (colorProfile == null)
{
- job.AddSolidSegment(Settings.DefaultSegmentLength > 0 ? Settings.DefaultSegmentLength : 100);
+ job.AddSolidSegment(machine.DefaultSegmentLength > 0 ? machine.DefaultSegmentLength : 100);
}
else
{
- job.AddSolidSegment(colorProfile.Value, Settings.DefaultSegmentLength > 0 ? Settings.DefaultSegmentLength : 100);
+ job.AddSolidSegment(colorProfile.Value, machine.DefaultSegmentLength > 0 ? machine.DefaultSegmentLength : 100);
job.Name = $"SnapMatch {colorProfile.Value.R}, {colorProfile.Value.G}, {colorProfile.Value.B}";
}
@@ -740,13 +724,10 @@ namespace Tango.PPC.Jobs.ViewModels
StorageProvider.RegisterFileHandler(ExplorerFileDefinition.Pulse.Extension, HandlePulseFileLoaded);
//Load catalogs.
- using (ObservablesContext db = ObservablesContext.CreateDefault())
+ using (ObservablesContext c = ObservablesContext.CreateDefault())
{
- _catalogs = await new CatalogsCollectionBuilder(db).SetAll().ForSite(MachineProvider.Machine.SiteGuid).BuildAsync();
- _rmls = await new RmlsCollectionBuilder(db).SetAll().ForHeadType(MachineProvider.Machine.MachineHeadType).ForSite(MachineProvider.Machine.SiteGuid).BuildAsync();
+ _catalogs = (await c.ColorCatalogs.ToListAsync()).ToObservableCollection();
}
-
- MachineDataSynchronizer.SynchronizationEnded += MachineDataSynchronizer_SynchronizationEnded;
}
public override void OnNavigatedTo()
@@ -764,64 +745,37 @@ namespace Tango.PPC.Jobs.ViewModels
var selected_job = SelectedJobs.FirstOrDefault();
if (selected_job == null) return;
- var selectedJobs = SelectedJobs.ToList();
-
ClearSelection();
var result = await NavigationManager.
NavigateForResult<StorageModule,
Storage.Views.MainView, ExplorerFileItem,
- StorageNavigationRequest>(
- new StorageNavigationRequest()
+ Storage.Models.StorageNavigationRequest>(
+ new Storage.Models.StorageNavigationRequest()
{
- Intent = selectedJobs.Count == 1 ? StorageNavigationIntent.SaveFile : StorageNavigationIntent.SaveFiles,
+ Intent = Storage.Models.StorageNavigationIntent.SaveFile,
DefaultFileName = selected_job.Name,
Filter = ExplorerFileDefinition.Job.Extension,
- Title = selectedJobs.Count == 1 ? "Save Job File" : "Save Job Files",
+ Title = "Save Job File",
});
if (result != null)
{
- if (selectedJobs.Count == 1)
+ try
{
- try
- {
- var jobFile = await selected_job.ToJobFile();
+ var jobFile = await selected_job.ToJobFile();
- using (FileStream fs = new FileStream(result.Path + ExplorerFileDefinition.Job.Extension, FileMode.Create))
- {
- jobFile.WriteTo(fs);
- }
-
- await NotificationProvider.ShowSuccess("Job saved successfully.");
- }
- catch (Exception ex)
+ using (FileStream fs = new FileStream(result.Path + ExplorerFileDefinition.Job.Extension, FileMode.Create))
{
- LogManager.Log(ex, $"Error saving job {selected_job.Name} to file.");
- await NotificationProvider.ShowError($"An error occurred while trying to save the job.\n{ex.Message}");
+ jobFile.WriteTo(fs);
}
+
+ await NotificationProvider.ShowSuccess("Job saved successfully.");
}
- else
+ catch (Exception ex)
{
- foreach (var job in selectedJobs)
- {
- try
- {
- var jobFile = await job.ToJobFile();
-
- using (FileStream fs = new FileStream(Path.Combine(result.Path, jobFile.Name.ToValidFileName()) + ExplorerFileDefinition.Job.Extension, FileMode.Create))
- {
- jobFile.WriteTo(fs);
- }
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, $"Error saving job {job.Name} to file.");
- await NotificationProvider.ShowError($"An error occurred while trying to save the job.\n{ex.Message}");
- }
- }
-
- await NotificationProvider.ShowSuccess("Jobs saved successfully.");
+ LogManager.Log(ex, $"Error saving job {selected_job.Name} to file.");
+ await NotificationProvider.ShowError($"An error occurred while trying to save the job.\n{ex.Message}");
}
}
}
@@ -830,7 +784,7 @@ namespace Tango.PPC.Jobs.ViewModels
#region Handle Job File Loading From Storage
- private async void HandleJobFileLoaded(List<ExplorerFileItem> jobFiles)
+ private async void HandleJobFileLoaded(ExplorerFileItem jobFile)
{
var vm = await NotificationProvider.ShowDialog<ImportJobViewVM>();
@@ -838,35 +792,29 @@ namespace Tango.PPC.Jobs.ViewModels
{
using (ObservablesContext jobContext = ObservablesContext.CreateDefault())
{
- foreach (var jobFile in jobFiles)
+ try
{
- try
+ JobFile jFile = JobFile.Parser.ParseFrom(File.ReadAllBytes(jobFile.Path));
+ var job = await Job.FromJobFile(jFile, MachineProvider.Machine.Guid, AuthenticationProvider.CurrentUser.Guid);
+ jobContext.Jobs.Add(job);
+ await jobContext.SaveChangesAsync();
+ LoadJobs(() =>
{
- JobFile jFile = JobFile.Parser.ParseFrom(File.ReadAllBytes(jobFile.Path));
- var job = await Job.FromJobFile(jFile, MachineProvider.Machine.Guid, null);
- job.JobSource = JobSource.Local;
- jobContext.Jobs.Add(job);
- await jobContext.SaveChangesAsync();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, $"Error occurred while trying to import job from file {jobFile.Path}.");
- await NotificationProvider.ShowError($"An error occurred while trying to import the selected job file.\n{ex.Message}");
- }
+ if (vm.ImportAndEdit)
+ {
+ var postJob = Jobs.SingleOrDefault(x => x.Guid == job.Guid);
+ if (postJob != null)
+ {
+ SelectJob(postJob, true);
+ }
+ }
+ });
}
-
- LoadJobs(() =>
+ catch (Exception ex)
{
- //Editing of a job is currently deprecated due to enabling multiple job imports.
- //if (vm.ImportAndEdit)
- //{
- // var postJob = Jobs.SingleOrDefault(x => x.Guid == job.Guid);
- // if (postJob != null)
- // {
- // SelectJob(postJob, true);
- // }
- //}
- });
+ LogManager.Log(ex, $"Error occurred while trying to import job from file {jobFile.Path}.");
+ await NotificationProvider.ShowError($"An error occurred while trying to import the selected job file.\n{ex.Message}");
+ }
}
}
}
@@ -875,10 +823,8 @@ namespace Tango.PPC.Jobs.ViewModels
#region Handle TCC File Loading From Storage
- private async void HandleColorProfileFileLoaded(List<ExplorerFileItem> tccFiles)
+ private async void HandleColorProfileFileLoaded(ExplorerFileItem tccFile)
{
- var tccFile = tccFiles.FirstOrDefault();
-
try
{
DetectionColorFile tcc = DetectionColorFile.Parser.ParseFrom(File.ReadAllBytes(tccFile.Path));
@@ -907,10 +853,8 @@ namespace Tango.PPC.Jobs.ViewModels
#region Handle Pulse TWN Loading From Storage
- private async void HandlePulseFileLoaded(List<ExplorerFileItem> twnFiles)
+ private async void HandlePulseFileLoaded(ExplorerFileItem twnFile)
{
- var twnFile = twnFiles.FirstOrDefault();
-
TwnFile twn = TwnFile.FromFile(twnFile.Path);
BitmapSource preview = twn.Thumbnail.ToBitmapSource();
@@ -927,32 +871,6 @@ namespace Tango.PPC.Jobs.ViewModels
#endregion
- #region Handle New Synchronized Jobs
-
- private void MachineDataSynchronizer_SynchronizationEnded(object sender, SynchronizationEndedEventArgs e)
- {
- if (e.NewChangedJobs > 0 && !_isJobsSynchronizationNotificationActive)
- {
- _isJobsSynchronizationNotificationActive = true;
-
- var item = NotificationProvider.PushNotification<NewSynchronizardJobsNotificationItem>();
- item.Pressed += (_, __) =>
- {
- _isJobsSynchronizationNotificationActive = false;
- LoadJobs(() =>
- {
- NotificationProvider.ShowSuccess("Your job list is now synchronized.");
- });
- };
- item.Closed += (_, __) =>
- {
- _isJobsSynchronizationNotificationActive = false;
- };
- }
- }
-
- #endregion
-
#region Color Profile Request
private void ExternalBridgeService_ColorProfileRequest(object sender, ColorProfileRequestEventArgs e)
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/MainViewVM.cs
index 579e1e2f7..ed1e28f55 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/MainViewVM.cs
@@ -11,7 +11,6 @@ using Tango.Integration.Operation;
using Tango.PPC.Common;
using Tango.PPC.Common.Notifications;
using Tango.PPC.Common.Notifications.NotificationItems;
-using Tango.PPC.Jobs.AppBarItems;
using Tango.PPC.Jobs.Messages;
using Tango.PPC.Jobs.NavigationObjects;
using Tango.PPC.Jobs.Views;
@@ -25,9 +24,6 @@ namespace Tango.PPC.Jobs.ViewModels
public class MainViewVM : PPCViewModel
{
private NotificationItem _last_failed_job_notification;
- private JobHandler _handler;
- private bool resuming;
- private JobProgressAppBarItem _appBarItem;
/// <summary>
/// Called when the application has been started.
@@ -37,42 +33,23 @@ namespace Tango.PPC.Jobs.ViewModels
MachineProvider.MachineOperator.PrintingCompleted += MachineOperator_PrintingCompleted;
MachineProvider.MachineOperator.PrintingFailed += MachineOperator_PrintingFailed;
MachineProvider.MachineOperator.ResumingJob += MachineOperator_ResumingJob;
- MachineProvider.MachineOperator.PrintingStarted += MachineOperator_PrintingStarted;
- MachineProvider.MachineOperator.PrintingEnded += MachineOperator_PrintingEnded;
- NavigationManager.CurrentVMChanged += NavigationManager_CurrentVMChanged;
}
- private void MachineOperator_PrintingEnded(object sender, PrintingEventArgs e)
+ private async void MachineOperator_ResumingJob(object sender, ResumingJobEventArgs e)
{
- _appBarItem?.Close();
- _appBarItem = null;
- }
+ LogManager.Log($"Trying to resume job '{e.JobGuid}'...");
- private void NavigationManager_CurrentVMChanged(object sender, PPCViewModel vm)
- {
- if (vm.GetType() == typeof(JobProgressViewVM))
- {
- _appBarItem?.Close();
- _appBarItem = null;
- }
- else if (vm.GetType() != typeof(JobSummeryViewVM) && _appBarItem == null && MachineProvider.MachineOperator.IsPrinting && _handler != null && !_handler.IsCanceled)
+ try
{
- _appBarItem = NotificationProvider.PushAppBarItem<JobProgressAppBarItem>();
- _appBarItem.Pressed += (_, __) =>
- {
- _appBarItem?.Close();
- NavigationManager.NavigateTo<JobsModule>(nameof(JobProgressView));
- };
- }
- }
+ var job = await new JobBuilder(ObservablesContext.CreateDefault()).Set(e.JobGuid)
+ .WithConfiguration()
+ .WithRML()
+ .WithUser()
+ .WithSegments()
+ .WithBrushStops()
+ .BuildAsync();
- private void MachineOperator_PrintingStarted(object sender, PrintingEventArgs e)
- {
- _handler = e.JobHandler;
-
- if (resuming)
- {
- resuming = false;
+ e.Approve(job);
InvokeUI(() =>
{
@@ -85,17 +62,6 @@ namespace Tango.PPC.Jobs.ViewModels
}
});
}
- }
-
- private void MachineOperator_ResumingJob(object sender, ResumingJobEventArgs e)
- {
- LogManager.Log($"Job resume request '{e.JobGuid}' approving...");
-
- try
- {
- e.Approve();
- resuming = true;
- }
catch (Exception ex)
{
LogManager.Log(ex, "An error occurred while trying to resume the job.");
@@ -113,15 +79,13 @@ namespace Tango.PPC.Jobs.ViewModels
/// <param name="e">The <see cref="Integration.Operation.PrintingFailedEventArgs"/> instance containing the event data.</param>
private void MachineOperator_PrintingFailed(object sender, PrintingFailedEventArgs e)
{
- String message = $"{e.Exception.FlattenMessage()}";
-
_last_failed_job_notification = NotificationProvider.PushNotification(new MessageNotificationItem(
- $"'{e.Job.Name}' failed at position {e.JobHandler.Status.ProgressMinusSettingUp.ToString("0.0")} out of {e.JobHandler.Status.TotalProgressMinusSettingUp.ToString("0.0")} meters.",
- message, MessageNotificationItem.MessageNotificationItemTypes.Error, () =>
+ String.Format("'{0}' failed.", e.Job.Name),
+ String.Format("The job '{1}' has failed due to unexpected error.{0}{2}{0}{0}Tap to view this job details.", Environment.NewLine, e.Job.Name, e.Exception), MessageNotificationItem.MessageNotificationItemTypes.Error, () =>
{
NavigationManager.NavigateWithObject<JobsModule, JobView, Job>(e.Job);
NavigationManager.ClearHistoryExcept<JobsView>();
- }, NotificationItem.NotificationPriority.VeryHigh));
+ }));
}
/// <summary>
@@ -155,7 +119,7 @@ namespace Tango.PPC.Jobs.ViewModels
{
NavigationManager.NavigateWithObject<JobsModule, JobView, JobNavigationObject>(new JobNavigationObject() { Job = e.Job });
NavigationManager.ClearHistoryExcept<JobsView>();
- }, NotificationItem.NotificationPriority.VeryHigh));
+ }));
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobProgressView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobProgressView.xaml
index 40cfc40f9..3b92581bc 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobProgressView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobProgressView.xaml
@@ -19,7 +19,7 @@
<Grid>
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0 100 0 0">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
- <TextBlock FontSize="{StaticResource TangoHeaderFontSize}" Text="{Binding Job.Name,FallbackValue='Job Name'}" TextWrapping="Wrap" MaxWidth="700"></TextBlock>
+ <TextBlock FontSize="{StaticResource TangoHeaderFontSize}" Text="{Binding Job.Name,FallbackValue='Job Name'}"></TextBlock>
<TextBlock FontSize="{StaticResource TangoTitleFontSize}" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Center" Margin="10 0 0 0" Visibility="{Binding Job.Designation,Converter={StaticResource EnumToVisibilityConverter},ConverterParameter='SampleDye'}">(Sample)</TextBlock>
<TextBlock FontSize="{StaticResource TangoTitleFontSize}" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Center" Margin="10 0 0 0" Visibility="{Binding Job.Designation,Converter={StaticResource EnumToVisibilityConverter},ConverterParameter='FineTuning'}">(Fine Tuning)</TextBlock>
</StackPanel>
@@ -38,8 +38,6 @@
<Setter Property="Visibility" Value="Visible"></Setter>
</DataTrigger>
<DataTrigger Binding="{Binding RunningJobStatus.IsCompleted}" Value="True">
- <Setter Property="Maximum" Value="100"></Setter>
- <Setter Property="Value" Value="99.9999999"></Setter>
<Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"></Setter>
</DataTrigger>
<DataTrigger Binding="{Binding RunningJobStatus.IsCanceled}" Value="True">
@@ -100,7 +98,7 @@
<StackPanel Height="90" Visibility="{Binding RunningJobStatus.IsSettingUp,Converter={StaticResource BooleanToVisibilityConverter}}">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<Image Source="../Images/JobProgressView/drop.png" Stretch="None" />
- <TextBlock Margin="5 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Getting Ready...</TextBlock>
+ <TextBlock Margin="5 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Getting ready...</TextBlock>
</StackPanel>
</StackPanel>
@@ -119,8 +117,8 @@
</Grid>
<Grid Margin="0 150 0 0">
- <StackPanel MaxWidth="600">
- <Canvas Height="80" Margin="0">
+ <StackPanel>
+ <Canvas Height="80" Margin="5 0">
<StackPanel>
<StackPanel.Style>
<Style TargetType="StackPanel">
@@ -140,58 +138,64 @@
</Style.Triggers>
</Style>
</StackPanel.Style>
- <StackPanel Margin="-20 20 0 0">
- <StackPanel>
- <Canvas HorizontalAlignment="Center">
- <TextBlock Margin="0 -25 0 0" Canvas.Left="{Binding RelativeSource={RelativeSource Mode=Self},Path=ActualWidth,Converter={StaticResource MathOperatorConverter},ConverterParameter='*-0.5'}" HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Text" Value="Now Dyeing"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding RunningJobStatus.IsSettingUp}" Value="True">
- <Setter Property="Text" Value="Getting Ready"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding RunningJobStatus.IsCanceled}" Value="True">
- <Setter Property="Text" Value="Job Canceled"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding RunningJobStatus.IsFailed}" Value="True">
- <Setter Property="Text" Value="Job Failed"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding RunningJobStatus.IsCompleted}" Value="True">
- <Setter Property="Text" Value="Job Completed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
- </Canvas>
- <touch:TouchIcon Margin="0 8 0 0" HorizontalAlignment="Center" Width="40" Height="40">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon" BasedOn="{StaticResource {x:Type touch:TouchIcon}}">
- <Setter Property="Angle" Value="180"></Setter>
- <Setter Property="Icon" Value="Water"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding RunningJobStatus.IsCanceled}" Value="True">
- <Setter Property="Angle" Value="0"></Setter>
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding RunningJobStatus.IsFailed}" Value="True">
- <Setter Property="Angle" Value="0"></Setter>
- <Setter Property="Icon" Value="AlertOctagon"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding RunningJobStatus.IsCompleted}" Value="True">
- <Setter Property="Angle" Value="0"></Setter>
- <Setter Property="Icon" Value="Check"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </StackPanel>
+ <StackPanel Margin="-50 0 0 0">
+ <ContentControl>
+ <ContentControl.Style>
+ <Style TargetType="ContentControl">
+ <Setter Property="Content">
+ <Setter.Value>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">
+ <TextBlock.Style>
+ <Style TargetType="TextBlock">
+ <Setter Property="Text" Value="now dyeing"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding RunningJobStatus.IsSettingUp}" Value="True">
+ <Setter Property="Text" Value="getting ready"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </TextBlock.Style>
+ </TextBlock>
+ <touch:TouchIcon Margin="0 8 0 0" HorizontalAlignment="Center" Icon="Water" Angle="180" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="40" Height="40" />
+ </StackPanel>
+ </Setter.Value>
+ </Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding RunningJobStatus.IsCanceled}" Value="True">
+ <Setter Property="Content">
+ <Setter.Value>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">job canceled</TextBlock>
+ <touch:TouchIcon Margin="0 8 0 0" HorizontalAlignment="Center" Icon="Alert" Foreground="{StaticResource TangoWarningBrush}" Width="40" Height="40" />
+ </StackPanel>
+ </Setter.Value>
+ </Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding RunningJobStatus.IsFailed}" Value="True">
+ <Setter Property="Content">
+ <Setter.Value>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">job failed</TextBlock>
+ <touch:TouchIcon Margin="0 8 0 0" HorizontalAlignment="Center" Icon="AlertOctagon" Foreground="{StaticResource TangoErrorBrush}" Width="40" Height="40" />
+ </StackPanel>
+ </Setter.Value>
+ </Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding RunningJobStatus.IsCompleted}" Value="True">
+ <Setter Property="Content">
+ <Setter.Value>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">job completed</TextBlock>
+ <touch:TouchIcon Margin="0 8 0 0" HorizontalAlignment="Center" Icon="Check" Foreground="{StaticResource TangoSuccessBrush}" Width="40" Height="40" />
+ </StackPanel>
+ </Setter.Value>
+ </Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </ContentControl.Style>
+ </ContentControl>
</StackPanel>
</StackPanel>
</Canvas>
@@ -210,23 +214,5 @@
Go to job
</touch:TouchButton>
</StackPanel>
-
- <touch:TouchButton Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}" VerticalAlignment="Bottom" Margin="0 100 0 0" Command="{Binding DisplayJobOutlineCommand}" Style="{StaticResource TangoLinkButton}" Height="60" FontSize="{StaticResource TangoTitleFontSize}">
- Display Job Outline
- </touch:TouchButton>
-
- <Grid Visibility="{Binding IsDisplayJobOutline,Converter={StaticResource BooleanToVisibilityConverter}}" Background="{StaticResource TangoPrimaryBackgroundBrush}" Opacity="0.8"/>
-
- <Grid Margin="0 -10 0 0" Visibility="{Binding IsDisplayJobOutline,Converter={StaticResource BooleanToVisibilityConverter}}">
- <Grid>
- <touch:TouchScrollViewer BorderThickness="0" Padding="10" Margin="0 0 0 100">
- <global:JobOutlineControl BorderThickness="0" Margin="20" DataContext="{Binding JobOutlineTicket}" HorizontalAlignment="Left" />
- </touch:TouchScrollViewer>
- </Grid>
-
- <touch:TouchButton Background="{StaticResource TangoPrimaryBackgroundBrush}" VerticalAlignment="Bottom" Margin="0 100 0 0" Command="{Binding HideJobOutlineCommand}" Style="{StaticResource TangoLinkButton}" Height="60" FontSize="{StaticResource TangoTitleFontSize}">
- Hide Job Outline
- </touch:TouchButton>
- </Grid>
</Grid>
</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobSummeryView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobSummeryView.xaml
index 4785805a6..80a427714 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobSummeryView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobSummeryView.xaml
@@ -54,7 +54,7 @@
<RowDefinition Height="300*"/>
</Grid.RowDefinitions>
- <TextBlock FontSize="{StaticResource TangoHeaderFontSize}" Text="{Binding Job.Name}" HorizontalAlignment="Center" VerticalAlignment="Center" TextWrapping="Wrap"></TextBlock>
+ <TextBlock FontSize="{StaticResource TangoHeaderFontSize}" Text="{Binding Job.Name}" HorizontalAlignment="Center" VerticalAlignment="Center"></TextBlock>
<Grid Grid.Row="1" Width="360" Height="360">
<touch:TouchBusyIndicator Opacity="0.6" IsIndeterminate="False" Foreground="{StaticResource TangoGrayBrush}" StrokeThickness="10" Minimum="0" Maximum="100" Value="99.999" Width="Auto" Height="Auto">
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
index 6a94034db..57101569a 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
@@ -26,8 +26,6 @@
<BitmapImage x:Key="Image_Out_Of_Gamut" UriSource="../Images/JobView/error.png" />
<BitmapImage x:Key="Image_Replace_Color" UriSource="../Images/JobView/replace-color.png" />
<BitmapImage x:Key="Image_Color_Picker" UriSource="../Images/JobView/color-picker.png" />
- <BitmapImage x:Key="Image_Transparent" UriSource="../Images/JobView/transparent.jpg" />
- <BitmapImage x:Key="Image_TransparentSmall" UriSource="../Images/JobView/transparent_small.jpg" />
<Style TargetType="FrameworkElement" x:Key="Level1Container">
@@ -113,24 +111,9 @@
<StackPanel>
<StackPanel Orientation="Horizontal">
<Border Width="48" Height="48" CornerRadius="5" BorderThickness="1" BorderBrush="{StaticResource TangoGrayBrush}">
- <Border.Style>
- <Style TargetType="Border">
- <Setter Property="Background">
- <Setter.Value>
- <SolidColorBrush Color="{Binding Color,IsAsync=True}" />
- </Setter.Value>
- </Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True" >
- <Setter Property="Background">
- <Setter.Value>
- <ImageBrush ImageSource="{StaticResource Image_TransparentSmall}" Stretch="None" />
- </Setter.Value>
- </Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Border.Style>
+ <Border.Background>
+ <SolidColorBrush Color="{Binding Color,IsAsync=True}"></SolidColorBrush>
+ </Border.Background>
</Border>
<TextBlock Margin="30 0 0 0" FontSize="{StaticResource TangoTitleFontSize}">
@@ -164,17 +147,6 @@
<DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Volume">
<Setter Property="ContentTemplate" Value="{StaticResource Volume_Template}" />
</DataTrigger>
- <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True">
- <Setter Property="ContentTemplate">
- <Setter.Value>
- <DataTemplate>
- <Grid Height="40">
- <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayBrush}">Transparent</TextBlock>
- </Grid>
- </DataTemplate>
- </Setter.Value>
- </Setter>
- </DataTrigger>
</Style.Triggers>
</Style>
</ContentControl.Style>
@@ -200,10 +172,7 @@
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0 0 -130 0" HorizontalAlignment="Right" VerticalAlignment="Top">
- <StackPanel Orientation="Horizontal" Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,IsAsync=True,Converter={StaticResource BooleanToVisibilityInverseConverter}}">
- <!--<touch:TouchToggleIconButton Padding="15" Width="60" Height="60" CornerRadius="30" Icon="EyeOutline" CheckedIcon="EyeOffOutline" Foreground="{StaticResource TangoGrayBrush}" CheckedForeground="{StaticResource TangoGrayBrush}" IsChecked="{Binding IsTransparent,IsAsync=True}"></touch:TouchToggleIconButton>-->
- <touch:TouchImageButton Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand,IsAsync=True}" CommandParameter="{Binding}" Visibility="{Binding ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter},IsAsync=True}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30"></touch:TouchImageButton>
- </StackPanel>
+ <touch:TouchImageButton Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand,IsAsync=True}" CommandParameter="{Binding}" Visibility="{Binding IsOutOfGamut,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30"></touch:TouchImageButton>
<touch:TouchIconButton Margin="0 0 50 0" Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter}}" Command="{Binding ElementName=view,Path=DataContext.RemoveBrushStopCommand,IsAsync=True}" CommandParameter="{Binding}" EnableDropShadow="False" Icon="TrashAltRegular" Padding="12" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="50" Height="50" RippleBrush="{StaticResource TangoRippleDarkBrush}" CornerRadius="30" />
</StackPanel>
</Grid>
@@ -245,11 +214,7 @@
</Style.Triggers>
</Style>
</DockPanel.Style>
-
- <Border DockPanel.Dock="Left" BorderThickness="0 0 1 0" BorderBrush="{StaticResource TangoLightBorderBrush}">
- <Border.Background>
- <ImageBrush ImageSource="{StaticResource Image_Transparent}" Stretch="None" />
- </Border.Background>
+ <Border DockPanel.Dock="Left" Background="{Binding SegmentBrush}" BorderThickness="0 0 1 0" BorderBrush="{StaticResource TangoLightBorderBrush}">
<Border.Style>
<Style TargetType="Border">
<Setter Property="CornerRadius" Value="8 0 0 8"></Setter>
@@ -268,26 +233,6 @@
</Style.Triggers>
</Style>
</Border.Style>
- <Border Background="{Binding SegmentBrush}">
- <Border.Style>
- <Style TargetType="Border">
- <Setter Property="CornerRadius" Value="8 0 0 8"></Setter>
- <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,IsAsync=True}"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding ElementName=toggle_small_list,Path=IsChecked,IsAsync=True}" Value="True">
- <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,Converter={StaticResource MathOperatorConverter},ConverterParameter='*2',IsAsync=True}"></Setter>
- </DataTrigger>
- <MultiDataTrigger>
- <MultiDataTrigger.Conditions>
- <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True"></Condition>
- <Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True"></Condition>
- </MultiDataTrigger.Conditions>
- <Setter Property="CornerRadius" Value="8 0 0 0"></Setter>
- </MultiDataTrigger>
- </Style.Triggers>
- </Style>
- </Border.Style>
- </Border>
</Border>
<Grid>
@@ -302,90 +247,77 @@
</TextBlock>
</StackPanel>
- <Grid>
- <StackPanel Margin="0 30 0 0" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="300" Visibility="{Binding ElementName=toggle_large_list,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}">
- <DockPanel LastChildFill="False">
- <DockPanel.Style>
- <Style TargetType="DockPanel">
- <Setter Property="Visibility" Value="Visible"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </DockPanel.Style>
- <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Color code:"></TextBlock>
+ <StackPanel Margin="0 30 0 0" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="300" Visibility="{Binding ElementName=toggle_large_list,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}">
+ <DockPanel LastChildFill="False">
+ <DockPanel.Style>
+ <Style TargetType="DockPanel">
+ <Setter Property="Visibility" Value="Visible"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True">
+ <Setter Property="Visibility" Value="Collapsed"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </DockPanel.Style>
+ <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Color code:"></TextBlock>
- <Grid DockPanel.Dock="Right" DataContext="{Binding BrushStops[0],IsAsync=True}">
- <StackPanel>
- <ContentControl Focusable="False" FocusVisualStyle="{x:Null}" d:DataContext="{d:DesignInstance Type=entities:BrushStop, IsDesignTimeCreatable=False}" Content="{Binding}" Width="180">
- <ContentControl.Style>
- <Style TargetType="ContentControl">
- <Setter Property="ContentTemplate">
- <Setter.Value>
- <DataTemplate>
+ <Grid DockPanel.Dock="Right" DataContext="{Binding BrushStops[0],IsAsync=True}">
+ <StackPanel>
+ <ContentControl Focusable="False" FocusVisualStyle="{x:Null}" d:DataContext="{d:DesignInstance Type=entities:BrushStop, IsDesignTimeCreatable=False}" Content="{Binding}" Width="180">
+ <ContentControl.Style>
+ <Style TargetType="ContentControl">
+ <Setter Property="ContentTemplate">
+ <Setter.Value>
+ <DataTemplate>
- </DataTemplate>
- </Setter.Value>
- </Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="RGB">
- <Setter Property="ContentTemplate" Value="{StaticResource RGB_Template}" />
- </DataTrigger>
- <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="CMYK">
- <Setter Property="ContentTemplate" Value="{StaticResource CMYK_Template}" />
- </DataTrigger>
- <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="LAB">
- <Setter Property="ContentTemplate" Value="{StaticResource LAB_Template}" />
- </DataTrigger>
- <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Catalog">
- <Setter Property="ContentTemplate" Value="{StaticResource CATALOG_Template}" />
- </DataTrigger>
- <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Volume">
- <Setter Property="ContentTemplate" Value="{StaticResource Volume_Template}" />
- </DataTrigger>
- <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True">
- <Setter Property="ContentTemplate">
- <Setter.Value>
- <DataTemplate>
- <Grid Height="40">
- <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayBrush}">Transparent</TextBlock>
- </Grid>
- </DataTemplate>
- </Setter.Value>
- </Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </ContentControl.Style>
- </ContentControl>
- </StackPanel>
- </Grid>
- </DockPanel>
- <Canvas>
- <Canvas.Style>
- <Style TargetType="Canvas">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <MultiDataTrigger>
- <MultiDataTrigger.Conditions>
- <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="False" />
- <Condition Binding="{Binding BrushStops[0].IsOutOfGamut,IsAsync=True}" Value="True" />
- </MultiDataTrigger.Conditions>
- <Setter Property="Visibility" Value="Visible"></Setter>
- </MultiDataTrigger>
- </Style.Triggers>
- </Style>
- </Canvas.Style>
- <TextBlock Canvas.Top="2" Foreground="{StaticResource TangoErrorBrush}" FontSize="{StaticResource TangoSmallFontSize}" Text="Color is out of gamut. Modify color or select an alternative."></TextBlock>
- </Canvas>
- <DockPanel LastChildFill="False" Margin="0 20 0 0">
- <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Length (m):"></TextBlock>
- <touch:TouchNumericTextBox Width="180" DockPanel.Dock="Right" Value="{Binding Length}" StringFormat="0.0" AutoCalculateJogStep="False" HasDecimalPoint="True" Minimum="1" Maximum="100000" KeyboardContainer="{Binding ElementName=Container}" />
- </DockPanel>
- </StackPanel>
- </Grid>
+ </DataTemplate>
+ </Setter.Value>
+ </Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="RGB">
+ <Setter Property="ContentTemplate" Value="{StaticResource RGB_Template}" />
+ </DataTrigger>
+ <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="CMYK">
+ <Setter Property="ContentTemplate" Value="{StaticResource CMYK_Template}" />
+ </DataTrigger>
+ <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="LAB">
+ <Setter Property="ContentTemplate" Value="{StaticResource LAB_Template}" />
+ </DataTrigger>
+ <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Catalog">
+ <Setter Property="ContentTemplate" Value="{StaticResource CATALOG_Template}" />
+ </DataTrigger>
+ <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Volume">
+ <Setter Property="ContentTemplate" Value="{StaticResource Volume_Template}" />
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </ContentControl.Style>
+ </ContentControl>
+ </StackPanel>
+ </Grid>
+ </DockPanel>
+ <Canvas>
+ <Canvas.Style>
+ <Style TargetType="Canvas">
+ <Setter Property="Visibility" Value="Collapsed"></Setter>
+ <Style.Triggers>
+ <MultiDataTrigger>
+ <MultiDataTrigger.Conditions>
+ <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="False" />
+ <Condition Binding="{Binding BrushStops[0].IsOutOfGamut,IsAsync=True}" Value="True" />
+ </MultiDataTrigger.Conditions>
+ <Setter Property="Visibility" Value="Visible"></Setter>
+ </MultiDataTrigger>
+ </Style.Triggers>
+ </Style>
+ </Canvas.Style>
+ <TextBlock Canvas.Top="2" Foreground="{StaticResource TangoErrorBrush}" FontSize="{StaticResource TangoSmallFontSize}" Text="Color is out of gamut. Modify color or select an alternative."></TextBlock>
+ </Canvas>
+ <DockPanel LastChildFill="False" Margin="0 20 0 0">
+ <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Length (m):"></TextBlock>
+ <touch:TouchNumericTextBox Width="180" DockPanel.Dock="Right" Value="{Binding Length}" StringFormat="0.0" AutoCalculateJogStep="False" HasDecimalPoint="True" Minimum="1" Maximum="100000" KeyboardContainer="{Binding ElementName=Container}" />
+ </DockPanel>
+ </StackPanel>
</DockPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 10 10 0">
@@ -402,27 +334,23 @@
</TextBlock.Style>
</TextBlock>
- <StackPanel Orientation="Horizontal">
- <StackPanel.Style>
- <Style TargetType="StackPanel">
+ <touch:TouchImageButton Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand}" CommandParameter="{Binding BrushStops[0]}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30">
+ <touch:TouchImageButton.Style>
+ <Style TargetType="{x:Type touch:TouchImageButton}" BasedOn="{StaticResource {x:Type touch:TouchImageButton}}">
<Setter Property="Visibility" Value="Collapsed"></Setter>
<Style.Triggers>
<MultiDataTrigger>
<MultiDataTrigger.Conditions>
- <Condition Binding="{Binding ElementName=toggleEdit,Path=IsChecked,IsAsync=True}" Value="False" />
<Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True" />
<Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="False" />
+ <Condition Binding="{Binding BrushStops[0].IsOutOfGamut,IsAsync=True}" Value="True" />
</MultiDataTrigger.Conditions>
<Setter Property="Visibility" Value="Visible"></Setter>
</MultiDataTrigger>
</Style.Triggers>
</Style>
- </StackPanel.Style>
-
- <!--<touch:TouchToggleIconButton Padding="15" Width="60" Height="60" CornerRadius="30" Icon="EyeOutline" CheckedIcon="EyeOffOutline" Foreground="{StaticResource TangoGrayBrush}" CheckedForeground="{StaticResource TangoGrayBrush}" IsChecked="{Binding BrushStops[0].IsTransparent,IsAsync=True}"></touch:TouchToggleIconButton>-->
-
- <touch:TouchImageButton Visibility="{Binding BrushStops[0].ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter},IsAsync=True}" Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand}" CommandParameter="{Binding BrushStops[0]}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30"></touch:TouchImageButton>
- </StackPanel>
+ </touch:TouchImageButton.Style>
+ </touch:TouchImageButton>
<StackPanel Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}" Orientation="Horizontal">
@@ -526,9 +454,9 @@
<touch:TouchComboBox ItemsSource="{Binding Rmls}" SelectedItem="{Binding Job.Rml}" DisplayMemberPath="Name" Title="Select Thread" />
<TextBlock>Comment:</TextBlock>
- <touch:TouchMultiLineTextBox Margin="20 0 0 -42" Text="{Binding Job.Description}" Height="60" keyboard:KeyboardView.Container="{Binding ElementName=Container}">
+ <TextBox Margin="20 0 0 -42" Text="{Binding Job.Description}" FocusVisualStyle="{x:Null}" BorderBrush="{StaticResource TangoDividerBrush}" Foreground="{StaticResource TangoDarkForegroundBrush}" AcceptsReturn="True" TextWrapping="Wrap" Height="60" Padding="5" keyboard:KeyboardView.Container="{Binding ElementName=Container}" keyboard:KeyboardView.Mode="AlphaNumeric">
- </touch:TouchMultiLineTextBox>
+ </TextBox>
</controls:TableGrid>
<Grid HorizontalAlignment="Center" Margin="0 20 0 0" TextElement.Foreground="{StaticResource TangoGrayTextBrush}">
@@ -631,6 +559,7 @@
<touch:TouchToggleImageButton x:Name="toggleEdit" UncheckedImage="../Images/pencil-gray.png"
CheckedImage="../Images/pencil-blue.png"
DockPanel.Dock="Right"
+ IsChecked="{Binding IsSelected}"
Padding="8" CornerRadius="30" Width="40" Height="40">
</touch:TouchToggleImageButton>
<!--<touch:TouchToggleIconButton x:Name="toggleEdit" DockPanel.Dock="Right" Icon="Pencil" CheckedIcon="Pencil" Padding="8" CornerRadius="20" />-->
@@ -718,61 +647,63 @@
</touch:TouchDropShadowBorder>
</touch:TouchVirtualizedContentControl>
- <touch:TouchDropShadowBorder Padding="0 20 0 50" Margin="0 0 0 15">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
- <Image Source="../Images/JobView/job-summary.png" Width="39" />
- <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Job Summary</TextBlock>
- </StackPanel>
+ <touch:TouchVirtualizedContentControl Margin="0 20 0 0" >
+ <touch:TouchDropShadowBorder Padding="0 0 0 50">
+ <StackPanel>
+ <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
+ <Image Source="../Images/JobView/job-summary.png" Width="39" />
+ <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Job Summary</TextBlock>
+ </StackPanel>
- <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
- <Grid>
- <localControls:JobSummeryViewer DataContext="{Binding Job,IsAsync=True}" Height="40"/>
- </Grid>
+ <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
+ <Grid>
+ <localControls:JobSummeryViewer DataContext="{Binding Job,IsAsync=True}" Height="40"/>
+ </Grid>
- <DockPanel Margin="0 30 0 0" LastChildFill="False">
+ <DockPanel Margin="0 30 0 0" LastChildFill="False">
- <StackPanel Orientation="Horizontal" DockPanel.Dock="Left" VerticalAlignment="Center">
- <TextBlock>
+ <StackPanel Orientation="Horizontal" DockPanel.Dock="Left" VerticalAlignment="Center">
+ <TextBlock>
<Run Text="Job length (m):"></Run>
<Run Text="{Binding Job.Length,Mode=OneWay}"></Run>
- </TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Job.LengthPercentageFactor,Converter={StaticResource GreaterThanToBooleanConverter},ConverterParameter=0}" Value="True">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
+ </TextBlock>
+ <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
+ <TextBlock.Style>
+ <Style TargetType="TextBlock">
+ <Setter Property="Visibility" Value="Collapsed"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding Job.LengthPercentageFactor,Converter={StaticResource GreaterThanToBooleanConverter},ConverterParameter=0}" Value="True">
+ <Setter Property="Visibility" Value="Visible"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </TextBlock.Style>
<Run>(</Run><Run Text="{Binding Job.Length,Mode=OneWay}"></Run><Run>+</Run><Run Text="{Binding Job.LengthPercentageFactor,Mode=OneWay}"></Run><Run>%</Run><Run>)</Run>
- </TextBlock>
- </StackPanel>
+ </TextBlock>
+ </StackPanel>
- <StackPanel DockPanel.Dock="Right" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0 -20 5 0">
- <TextBlock Margin="0 3 0 0" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Bottom">
+ <StackPanel DockPanel.Dock="Right" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0 -20 5 0">
+ <TextBlock Margin="0 3 0 0" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Bottom">
<Run Text="Factor: +"></Run>
- </TextBlock>
+ </TextBlock>
- <touch:TouchNumericTextBox Foreground="{StaticResource TangoGrayTextBrush}" Margin="5 0 0 0" Width="50" HorizontalContentAlignment="Center" Maximum="100" Minimum="0" Value="{Binding Job.LengthPercentageFactor}" KeyboardContainer="{Binding ElementName=Container}" StringFormat="0" FocusSelectionMode="SelectAll" />
+ <touch:TouchNumericTextBox Foreground="{StaticResource TangoGrayTextBrush}" Margin="5 0 0 0" Width="50" HorizontalContentAlignment="Center" Maximum="100" Minimum="0" Value="{Binding Job.LengthPercentageFactor}" KeyboardContainer="{Binding ElementName=Container}" StringFormat="0" FocusSelectionMode="SelectAll" />
- <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayTextBrush}">%</TextBlock>
+ <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayTextBrush}">%</TextBlock>
- <Image Margin="10 0 0 0" Source="../Images/JobView/settings.png" VerticalAlignment="Bottom" />
- </StackPanel>
- </DockPanel>
+ <Image Margin="10 0 0 0" Source="../Images/JobView/settings.png" VerticalAlignment="Bottom" />
+ </StackPanel>
+ </DockPanel>
+ </StackPanel>
</StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
+ </touch:TouchDropShadowBorder>
+ </touch:TouchVirtualizedContentControl>
- <StackPanel Visibility="Collapsed" HorizontalAlignment="Center" Margin="20 40 0 40" Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
+ <StackPanel HorizontalAlignment="Center" Margin="20 40 0 40" Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
<TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Additional Tools</TextBlock>
</StackPanel>
- <!--<touch:TouchVirtualizedContentControl>
+ <touch:TouchVirtualizedContentControl>
<touch:TouchExpander x:Name="expander_sample_dye" Margin="0 0 0 0" Padding="20 15">
<touch:TouchExpander.Header>
<StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0 0 20 0">
@@ -940,7 +871,7 @@
</touch:TouchVirtualizedContentControl>
<touch:TouchVirtualizedContentControl>
- <touch:TouchExpander x:Name="expander_fine_tuning" Margin="0 20 0 120" Padding="20 15" IsExpanded="{Binding IsFineTuneExpanded,Mode=TwoWay}" Visibility="{Binding Job.ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter},ConverterParameter='RGB,LAB'}">
+ <touch:TouchExpander x:Name="expander_fine_tuning" Margin="0 20 0 120" Padding="20 15" IsExpanded="{Binding IsFineTuneExpanded,Mode=TwoWay}" Visibility="{Binding Job.ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter}}">
<touch:TouchExpander.Header>
<StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0 0 20 0">
<Image Source="../Images/JobView/color-fine-tuning.png" Width="39" />
@@ -1171,7 +1102,7 @@
</ContentControl>
</StackPanel>
</touch:TouchExpander>
- </touch:TouchVirtualizedContentControl>-->
+ </touch:TouchVirtualizedContentControl>
</StackPanel>
</StackPanel>
</touch:LightTouchScrollViewer>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml.cs
index 86a8d2a37..880aa8a3a 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml.cs
@@ -54,16 +54,16 @@ namespace Tango.PPC.Jobs.Views
public async void DisplaySampleDye()
{
- //expander_sample_dye.IsExpanded = true;
- //await Task.Delay(500);
- //scrollViewer.ScrollToElement(expander_sample_dye);
+ expander_sample_dye.IsExpanded = true;
+ await Task.Delay(500);
+ scrollViewer.ScrollToElement(expander_sample_dye);
}
public async void DisplayFineTuning()
{
- //expander_fine_tuning.IsExpanded = true;
- //await Task.Delay(500);
- //scrollViewer.ScrollToElement(expander_fine_tuning);
+ expander_fine_tuning.IsExpanded = true;
+ await Task.Delay(500);
+ scrollViewer.ScrollToElement(expander_fine_tuning);
}
public void OnNavigatedFrom()
@@ -94,10 +94,6 @@ namespace Tango.PPC.Jobs.Views
borderEditDock.Visibility = Visibility.Collapsed;
}
}
- else if (_is_edit_docked)
- {
- FloatEditing();
- }
}
private void DockEditing()
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobsView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobsView.xaml
index 94abe6b83..c615583bc 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobsView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobsView.xaml
@@ -214,14 +214,14 @@
<touch:LightTouchDataGridColumn Width="1*" Header="Name" SortMember="Name" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding Name,Converter={StaticResource StringEllipsisConverter},ConverterParameter='40'}"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding Name,IsAsync=True}"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="117" Header="Length (m)" SortMember="Length">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding Length,StringFormat=0.0}"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding Length,StringFormat=0.0,IsAsync=True}"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
@@ -235,7 +235,7 @@
<touch:LightTouchDataGridColumn Width="100" Header="Updated" SortMember="LastUpdated">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding LastUpdated,Converter={StaticResource DateTimeUTCToShortDateConverter}}"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding LastUpdated,Converter={StaticResource DateTimeUTCToShortDateConverter},IsAsync=True}"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
@@ -314,21 +314,21 @@
<touch:LightTouchDataGridColumn Width="100" Header="Status" SortMember="JobStatus" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding JobStatus,Converter={StaticResource EnumToDescriptionConverter}}" HorizontalAlignment="Left" VerticalAlignment="Center"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding JobStatus,Converter={StaticResource EnumToDescriptionConverter},IsAsync=True}" HorizontalAlignment="Left" VerticalAlignment="Center"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="1*" Header="Name" SortMember="Name" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding Name,Converter={StaticResource StringEllipsisConverter},ConverterParameter='40'}" HorizontalAlignment="Left" VerticalAlignment="Center"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding Name,IsAsync=True}" HorizontalAlignment="Left" VerticalAlignment="Center"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="117" Header="Length (m)" SortMember="Length">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding Length,StringFormat=0.0}"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding Length,StringFormat=0.0,IsAsync=True}"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
@@ -342,7 +342,7 @@
<touch:LightTouchDataGridColumn Width="100" Header="Updated" SortMember="LastUpdated">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
- <TextBlock IsHitTestVisible="False" Text="{Binding LastUpdated,Converter={StaticResource DateTimeUTCToShortDateConverter}}"></TextBlock>
+ <controls:FastTextBlock IsHitTestVisible="False" Text="{Binding LastUpdated,Converter={StaticResource DateTimeUTCToShortDateConverter},IsAsync=True}"></controls:FastTextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
index 807a70b10..477340357 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
@@ -15,7 +15,7 @@ namespace Tango.PPC.MachineSettings
/// Represents a PPC <see cref="MachineSettingsModule"/>.
/// </summary>
/// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(4)]
+ [PPCModule(2)]
public class MachineSettingsModule : PPCModuleBase
{
/// <summary>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs
index 20cfd6bf4..8ed512670 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs
@@ -9,7 +9,6 @@ using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;
using Tango.BL;
-using Tango.BL.Builders;
using Tango.BL.Entities;
using Tango.BL.Enumerations;
using Tango.Core.Commands;
@@ -19,8 +18,6 @@ using Tango.PPC.Common;
using Tango.PPC.Common.Connection;
using Tango.PPC.Common.ExternalBridge;
using Tango.PPC.Common.Messages;
-using Tango.PPC.Common.OS;
-using Tango.PPC.Common.UWF;
using Tango.SharedUI.Components;
using Tango.WiFi;
@@ -32,17 +29,8 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// <seealso cref="Tango.PPC.Common.PPCViewModel" />
public class MainViewVM : PPCViewModel
{
- private TimeZoneInfo _previousTimeZone;
- private bool _previousEnableUWF;
-
#region Properties
- [TangoInject]
- private IOperationSystemManager OperationSystemManager { get; set; }
-
- [TangoInject]
- private IUnifiedWriteFilterManager UnifiedWriteFilterManager { get; set; }
-
private Machine _machine;
public Machine Machine
{
@@ -64,13 +52,6 @@ namespace Tango.PPC.MachineSettings.ViewModels
set { _selectedColorSpaces = value; RaisePropertyChangedAuto(); }
}
- private ObservableCollection<Rml> _rmls;
- public ObservableCollection<Rml> Rmls
- {
- get { return _rmls; }
- set { _rmls = value; RaisePropertyChangedAuto(); }
- }
-
private bool _enableHotSpot;
public bool EnableHotSpot
{
@@ -127,69 +108,6 @@ namespace Tango.PPC.MachineSettings.ViewModels
set { _lockScreenPassword = value; RaisePropertyChangedAuto(); }
}
- private Rml _defaultRML;
- public Rml DefaultRML
- {
- get { return _defaultRML; }
- set { _defaultRML = value; RaisePropertyChangedAuto(); }
- }
-
- private SpoolType _defaultSpoolType;
- public SpoolType DefaultSpoolType
- {
- get { return _defaultSpoolType; }
- set { _defaultSpoolType = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _synchronizeJobs;
- public bool SynchronizeJobs
- {
- get { return _synchronizeJobs; }
- set { _synchronizeJobs = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private bool _synchronizeDiagnostics;
- public bool SynchronizeDiagnostics
- {
- get { return _synchronizeDiagnostics; }
- set { _synchronizeDiagnostics = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private bool _autoCheckForUpdates;
- public bool AutoCheckForUpdates
- {
- get { return _autoCheckForUpdates; }
- set { _autoCheckForUpdates = value; RaisePropertyChangedAuto(); }
- }
-
- private List<TimeZoneInfo> _timeZones;
- /// <summary>
- /// Gets or sets the available time zones.
- /// </summary>
- public List<TimeZoneInfo> TimeZones
- {
- get { return _timeZones; }
- set { _timeZones = value; RaisePropertyChangedAuto(); }
- }
-
- private TimeZoneInfo _selectedTimeZone;
- /// <summary>
- /// Gets or sets the selected time zone.
- /// </summary>
- public TimeZoneInfo SelectedTimeZone
- {
- get { return _selectedTimeZone; }
- set { _selectedTimeZone = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _enableUWF;
- public bool EnableUWF
- {
- get { return _enableUWF; }
- set { _enableUWF = value; RaisePropertyChangedAuto(); }
- }
-
-
#endregion
#region Commands
@@ -204,18 +122,12 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// </summary>
public RelayCommand DiscardCommand { get; set; }
- /// <summary>
- /// Gets or sets the synchronize command.
- /// </summary>
- public RelayCommand SynchronizeCommand { get; set; }
-
#endregion
public MainViewVM()
{
SaveCommand = new RelayCommand(Save);
DiscardCommand = new RelayCommand(Discard);
- SynchronizeCommand = new RelayCommand(Synchronize, () => !MachineDataSynchronizer.IsSynchronizing && IsFree);
}
private void Discard()
@@ -227,9 +139,9 @@ namespace Tango.PPC.MachineSettings.ViewModels
{
if (Validate())
{
- Settings.SupportedJobTypes = SelectedJobTypes.SynchedSource.ToList();
- Settings.SupportedColorSpaces = SelectedColorSpaces.SynchedSource.ToList();
- Machine.MapPropertiesTo(MachineProvider.Machine, MappingFlags.NoReferenceTypes);
+ Machine.SupportedJobTypes = SelectedJobTypes.SynchedSource.ToList();
+ Machine.SupportedColorSpaces = SelectedColorSpaces.SynchedSource.ToList();
+ Machine.MapPrimitivesWithStrings(MachineProvider.Machine);
Settings.EnableHotSpot = EnableHotSpot;
Settings.HotSpotPassword = HotSpotPassword;
@@ -238,73 +150,10 @@ namespace Tango.PPC.MachineSettings.ViewModels
Settings.EnableLockScreen = EnableLockScreen;
Settings.LockScreenTimeout = TimeSpan.FromMinutes(LockScreenTimeoutMinutes);
Settings.LockScreenPassword = LockScreenPassword;
- Settings.DefaultRmlGuid = DefaultRML?.Guid;
- Settings.DefaultSpoolTypeGuid = DefaultSpoolType?.Guid;
- Settings.SynchronizeJobs = SynchronizeJobs;
- Settings.SynchronizeDiagnostics = SynchronizeDiagnostics;
- Settings.AutoCheckForUpdates = AutoCheckForUpdates;
-
- MachineDataSynchronizer.IsEnabled = SynchronizeJobs || SynchronizeDiagnostics;
-
Settings.Save();
await MachineProvider.SaveMachine();
-
- bool isRestarting = false;
-
- if (_previousTimeZone.ToStringSafe() != SelectedTimeZone.ToStringSafe())
- {
- if (await NotificationProvider.ShowQuestion("Changing the time zone requires the application to restart. Do you wish to restart the application?"))
- {
- try
- {
- LogManager.Log($"Setting new time zone to '{SelectedTimeZone.ToString()}'.");
- NotificationProvider.SetGlobalBusyMessage("Setting new time zone...");
- await OperationSystemManager.ChangeTimeZone(SelectedTimeZone);
- NotificationProvider.ReleaseGlobalBusyMessage();
- isRestarting = true;
- ApplicationManager.Restart();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error changing the time zone.");
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowError($"Error setting timezone.\n{ex.FlattenMessage()}");
- }
- }
- }
-
- if (_previousEnableUWF != EnableUWF)
- {
- await NotificationProvider.ShowWarning("Changes to disk protection (UWF) will take effect only after a full system restart.");
-
- try
- {
- LogManager.Log($"Changing UWF mode to '{EnableUWF}'.");
- if (EnableUWF)
- {
- NotificationProvider.SetGlobalBusyMessage("Enabling disk protection (UWF)...");
- await UnifiedWriteFilterManager.Enable();
- }
- else
- {
- NotificationProvider.SetGlobalBusyMessage("Disabling disk protection (UWF)...");
- await UnifiedWriteFilterManager.Disable();
- }
- NotificationProvider.ReleaseGlobalBusyMessage();
- }
- catch (Exception ex)
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, "Error setting UWF mode.");
- await NotificationProvider.ShowError($"Could not change the disk protection mode\n{ex.FlattenMessage()}");
- }
- }
-
- if (!isRestarting)
- {
- await NavigationManager.NavigateBack();
- }
+ await NavigationManager.NavigateBack();
}
}
@@ -318,29 +167,10 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// </summary>
public override void OnApplicationStarted()
{
- try
- {
- TimeZones = OperationSystemManager.GetAvailableTimeZones().ToList();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error retrieving available time zones.");
- }
- }
-
- public async override void OnApplicationReady()
- {
- base.OnApplicationReady();
- MachineDataSynchronizer.SynchronizationStarted += (_, __) => InvalidateRelayCommands();
- MachineDataSynchronizer.SynchronizationEnded += (_, __) => InvalidateRelayCommands();
- using (ObservablesContext db = ObservablesContext.CreateDefault())
- {
- Rmls = await new RmlsCollectionBuilder(db).SetAll().ForHeadType(MachineProvider.Machine.MachineHeadType).ForSite(MachineProvider.Machine.SiteGuid).BuildAsync();
- }
}
- public async override void OnNavigatedTo()
+ public override void OnNavigatedTo()
{
base.OnNavigatedTo();
@@ -365,29 +195,8 @@ namespace Tango.PPC.MachineSettings.ViewModels
LockScreenTimeoutMinutes = (int)Settings.LockScreenTimeout.TotalMinutes;
LockScreenPassword = Settings.LockScreenPassword;
- SelectedJobTypes = new SelectedObjectCollection<JobTypes>(Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToObservableCollection(), Settings.SupportedJobTypes.ToObservableCollection());
- SelectedColorSpaces = new SelectedObjectCollection<ColorSpaces>(Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace()).ToObservableCollection(), Settings.SupportedColorSpaces.ToObservableCollection());
-
- DefaultRML = Adapter.Rmls.SingleOrDefault(x => x.Guid == Settings.DefaultRmlGuid);
- DefaultSpoolType = Adapter.SpoolTypes.SingleOrDefault(x => x.Guid == Settings.DefaultSpoolTypeGuid);
-
- SynchronizeJobs = Settings.SynchronizeJobs;
- SynchronizeDiagnostics = Settings.SynchronizeDiagnostics;
-
- AutoCheckForUpdates = Settings.AutoCheckForUpdates;
-
- SelectedTimeZone = TimeZones.SingleOrDefault(x => x.StandardName == TimeZone.CurrentTimeZone.StandardName);
- _previousTimeZone = SelectedTimeZone;
-
- try
- {
- EnableUWF = await UnifiedWriteFilterManager.IsEnabled();
- _previousEnableUWF = EnableUWF;
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error getting UWF status.");
- }
+ SelectedJobTypes = new SelectedObjectCollection<JobTypes>(Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToObservableCollection(), Machine.SupportedJobTypes.ToObservableCollection());
+ SelectedColorSpaces = new SelectedObjectCollection<ColorSpaces>(Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace()).ToObservableCollection(), Machine.SupportedColorSpaces.ToObservableCollection());
}
private async void OnEnableRemoteAssistanceChanged()
@@ -462,29 +271,5 @@ namespace Tango.PPC.MachineSettings.ViewModels
{
ExternalBridgeService.Enabled = EnableExternalBridge;
}
-
- private async void Synchronize()
- {
- try
- {
- IsFree = false;
- NotificationProvider.SetGlobalBusyMessage("Synchronizing...");
-
- await MachineDataSynchronizer.Synchronize();
-
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowSuccess("Synchronization completed successfully.");
- }
- catch (Exception ex)
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowError($"Error occurred while trying to synchronize.\n{ex.FlattenMessage()}");
- }
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- IsFree = true;
- }
- }
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
index ba3516be4..dd5f89bb2 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
@@ -5,19 +5,15 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL"
xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:keyboard="clr-namespace:Tango.Touch.Keyboard;assembly=Tango.Touch"
- xmlns:sys="clr-namespace:System.Collections;assembly=mscorlib"
xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
xmlns:vm="clr-namespace:Tango.PPC.MachineSettings.ViewModels"
xmlns:connectivity="clr-namespace:Tango.PPC.Common.Connectivity;assembly=Tango.PPC.Common"
- xmlns:adapters="clr-namespace:Tango.Transport.Adapters;assembly=Tango.Transport"
xmlns:global="clr-namespace:Tango.PPC.MachineSettings"
- xmlns:integrationPMR="clr-namespace:Tango.PMR.Integration;assembly=Tango.PMR"
xmlns:local="clr-namespace:Tango.PPC.MachineSettings.Views"
mc:Ignorable="d"
- d:DesignHeight="4500" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}">
+ d:DesignHeight="2500" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}">
- <Grid Background="{StaticResource TangoMidBackgroundBrush}" IsEnabled="{Binding IsFree}">
+ <Grid Background="{StaticResource TangoMidBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
@@ -87,7 +83,7 @@
</touch:TouchExpander>
<!--JOBS-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Jobs" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
+ <touch:TouchExpander Margin="0 20 0 0" Header="JOBS" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
<StackPanel>
<controls:TableGrid Margin="10" RowHeight="70" MakeFirstColumnVerticalAlignmentBottom="False" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
<TextBlock VerticalAlignment="Center">Supported Job Types</TextBlock>
@@ -140,14 +136,14 @@
</ItemsControl.ItemTemplate>
</ItemsControl>
- <TextBlock VerticalAlignment="Bottom">Default Thread</TextBlock>
- <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Rmls}" SelectedItem="{Binding DefaultRML}" DisplayMemberPath="Name"></touch:TouchComboBox>
+ <TextBlock VerticalAlignment="Bottom">Default Thread Type</TextBlock>
+ <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.Rmls}" SelectedItem="{Binding Machine.DefaultRml}" DisplayMemberPath="Name" ValuePath="Guid"></touch:TouchComboBox>
- <TextBlock VerticalAlignment="Bottom">Default Spool</TextBlock>
- <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.SpoolTypes}" SelectedItem="{Binding DefaultSpoolType}" DisplayMemberPath="Name"></touch:TouchComboBox>
+ <!--<TextBlock VerticalAlignment="Bottom">Default Spool</TextBlock>
+ <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.SpoolTypes}" SelectedItem="{Binding Machine.DefaultSpoolType}" DisplayMemberPath="Name"></touch:TouchComboBox>-->
<TextBlock VerticalAlignment="Bottom">Default Segment Length</TextBlock>
- <touch:TouchNumericTextBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" Minimum="1" Maximum="1000" Value="{Binding Settings.DefaultSegmentLength}" HasDecimalPoint="True" KeyboardContainer="{Binding ElementName=Container}"></touch:TouchNumericTextBox>
+ <touch:TouchNumericTextBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" Minimum="1" Maximum="1000" Value="{Binding Machine.DefaultSegmentLength}" HasDecimalPoint="True" KeyboardContainer="{Binding ElementName=Container}"></touch:TouchNumericTextBox>
</controls:TableGrid>
@@ -199,172 +195,6 @@
</DockPanel>
</StackPanel>
</touch:TouchExpander>
-
- <!--SYNCHRONIZATION-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Cloud Synchronization" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Auto Update Check</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Automatically check for software and database updates.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding AutoCheckForUpdates}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Synchronize Jobs</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Synchronize your jobs with twine's cloud services.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding SynchronizeJobs}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Synchronize Diagnostics Data</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Help us improve your experience using this system.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding SynchronizeDiagnostics}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Once enabled, synchronization occurs automatically in the background. you can choose to synchronize right now.
- </TextBlock>
- </DockPanel>
- <touch:TouchButton Command="{Binding SynchronizeCommand}" IsEnabled="{Binding MachineDataSynchronizer.IsEnabled}" HorizontalAlignment="Left" Margin="25 10 0 0" Style="{StaticResource TangoHollowButton}" FontSize="{StaticResource TangoDefaultFontSize}" Padding="15 10" CornerRadius="22">Synchronize Now</touch:TouchButton>
- </StackPanel>
- </touch:TouchExpander>
-
- <!--DATE & TIME-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Date &amp; Time" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}" Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Time Zone</TextBlock>
- <touch:TouchComboBox Margin="0 10 0 0" ItemsSource="{Binding TimeZones}" SelectedItem="{Binding SelectedTimeZone,Mode=TwoWay}">
-
- </touch:TouchComboBox>
- </StackPanel>
- </DockPanel>
- </StackPanel>
- </touch:TouchExpander>
-
- <!--TECHNICIAN-->
- <touch:TouchExpander Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}" Margin="0 20 0 0" Header="Advanced" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Embedded COM Port</TextBlock>
- <touch:TouchTextBox KeyboardContainer="{Binding ElementName=Container}" Text="{Binding Settings.EmbeddedComPort}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Emergency COM Port</TextBlock>
- <touch:TouchTextBox KeyboardContainer="{Binding ElementName=Container}" Text="{Binding Settings.EmergencyComPort}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Emergency Screen</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableEmergencyNotifications}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Embedded Debug Logs</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableEmbeddedDebugLogs}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Automatic Thread Loading Support</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableAutomaticThreadLoading}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Display PowerUp Screen</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.DisplayPowerUpScreen}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Job Liquid Quantity Validation</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableJobLiquidQuantityValidation}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Always Start in Technician Mode</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableTechnicianModeByDefault}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable External Bridge SignalR</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableExternalBridgeSignalR}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Auto Update Check Interval Minutes</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.AutoUpdateCheckInterval,Converter={StaticResource TimeSpanToMinutesConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Bypass Internet Connectivity Checks</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.BypassInternetConnectivityCheck}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Gradient Resolution CM</TextBlock>
- <touch:TouchNumericTextBox Minimum="10" Maximum="500" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.GradientGenerationResolution}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Insights</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.InsightsEnabled}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Sampling Interval (sec)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="300" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsSamplingInterval,Converter={StaticResource TimeSpanToSecondsConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Storage Cleanup Interval (min)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsStorageCleanupInterval,Converter={StaticResource TimeSpanToMinutesConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Max Storage Duration (days)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsMaxStorageDuration,Converter={StaticResource TimeSpanToDaysConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable UWF (Disk Protection)</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding EnableUWF}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Please restart the application for advanced settings to take effect.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- </touch:TouchExpander>
</StackPanel>
</touch:LightTouchScrollViewer>
</Grid>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/App.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/App.xaml
deleted file mode 100644
index cb7592abd..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/App.xaml
+++ /dev/null
@@ -1,11 +0,0 @@
-<Application x:Class="Tango.PPC.Maintenance.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.Maintenance/Commands/HomingMotorCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/HomingMotorCommand.cs
deleted file mode 100644
index d3f44fe7e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/HomingMotorCommand.cs
+++ /dev/null
@@ -1,80 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public abstract class HomingMotorCommand : MaintenanceCommand<object>
- {
- public HardwareMotorType Motor { get; set; }
-
- public MotorDirection Direction { get; set; }
-
- public double Speed { get; set; }
-
- public String HomingMessage { get; set; }
-
- public String ErrorMessage { get; set; }
-
- public String SuccessMessage { get; set; }
-
- public HomingMotorCommand(HardwareMotorType motor,
- MotorDirection direction,
- double speed,
- string homingMessage,
- string errorMessage,
- string successMessage)
- {
- Motor = motor;
- Direction = direction;
- Speed = speed;
- HomingMessage = homingMessage;
- ErrorMessage = errorMessage;
- SuccessMessage = successMessage;
- }
-
- protected override void OnExecute()
- {
- IsEnabled = false;
-
- try
- {
- NotificationProvider.SetGlobalBusyMessage(HomingMessage);
-
- MachineProvider.MachineOperator.StartMotorHoming(new PMR.Diagnostics.MotorHomingRequest()
- {
- Direction = Direction,
- MotorType = Motor,
- Speed = Speed,
- }).Subscribe((response) =>
- {
- //Next
- }, (ex) =>
- {
- //Error
- IsEnabled = true;
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, ErrorMessage);
- NotificationProvider.ShowError(ex.FlattenMessage());
- }, () =>
- {
- //Complete
- IsEnabled = true;
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowSuccess(SuccessMessage);
- });
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, ErrorMessage);
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowError(ex.FlattenMessage());
- IsEnabled = true;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseDyeingHeadCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseDyeingHeadCommand.cs
deleted file mode 100644
index 5c482e04c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseDyeingHeadCommand.cs
+++ /dev/null
@@ -1,31 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Integration.Operation;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public class OpenCloseDyeingHeadCommand : OpenCloseMotorCommand
- {
- public OpenCloseDyeingHeadCommand() : base(
- HardwareMotorType.MotoDhLid,
- MotorDirection.Backward,
- 400,
- 400,
- MotorState.Closed,
- "Opening dyeing head lid...",
- "Closing dyeing head lid...",
- "Error opening dyeing head lid.",
- "Error closing dyeing head lid.",
- "The dyeing head lid is now opened.",
- "The dyeing head lid is now closed."
- )
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseLeftLeadingWheelsCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseLeftLeadingWheelsCommand.cs
deleted file mode 100644
index b0d8c1dc5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseLeftLeadingWheelsCommand.cs
+++ /dev/null
@@ -1,30 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public class OpenCloseLeftLeadingWheelsCommand : OpenCloseMotorCommand
- {
- public OpenCloseLeftLeadingWheelsCommand() : base(
- HardwareMotorType.MotoLloading,
- MotorDirection.Backward,
- 250,
- 250,
- MotorState.Closed,
- "Opening left leading wheels...",
- "Closing left leading wheels...",
- "Error opening left leading wheels.",
- "Error closing left leading wheels.",
- "The left leading wheels are now opened.",
- "The left leading wheels are now closed."
- )
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseMotorCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseMotorCommand.cs
deleted file mode 100644
index 149c3675d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseMotorCommand.cs
+++ /dev/null
@@ -1,158 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public abstract class OpenCloseMotorCommand : MaintenanceCommand<OpenCloseMotorCommand.MotorState>
- {
- public enum MotorState
- {
- Closed,
- Opened,
- }
-
- public HardwareMotorType Motor { get; set; }
-
- public MotorDirection OpenDirection { get; set; }
-
- public MotorDirection CloseDirection
- {
- get
- {
- return OpenDirection == MotorDirection.Forward ? MotorDirection.Backward : MotorDirection.Forward;
- }
- }
-
- public double OpeningSpeed { get; set; }
-
- public double ClosingSpeed { get; set; }
-
- public String OpeningMessage { get; set; }
-
- public String ClosingMessage { get; set; }
-
- public String OpeningErrorMessage { get; set; }
-
- public String ClosingErrorMessage { get; set; }
-
- public String OpeningSuccessMessage { get; set; }
-
- public String ClosingSuccessMessage { get; set; }
-
- public OpenCloseMotorCommand(
- HardwareMotorType motor,
- MotorDirection openDirection,
- double openingSpeed,
- double closingSpeed,
- MotorState defaultState,
- String openingMessage,
- String closingMessage,
- String openingErrorMessage,
- String closingErrorMessage,
- String openingSuccessMessage,
- String closingSuccessMessage)
- {
-
- Motor = motor;
- OpenDirection = openDirection;
- OpeningSpeed = openingSpeed;
- ClosingSpeed = closingSpeed;
- State = defaultState;
- OpeningMessage = openingMessage;
- ClosingMessage = closingMessage;
- OpeningErrorMessage = openingErrorMessage;
- ClosingErrorMessage = closingErrorMessage;
- OpeningSuccessMessage = openingSuccessMessage;
- ClosingSuccessMessage = closingSuccessMessage;
- }
-
- protected override void OnExecute()
- {
- if (State == MotorState.Closed)
- {
- IsEnabled = false;
-
- try
- {
- NotificationProvider.SetGlobalBusyMessage(OpeningMessage);
-
- MachineProvider.MachineOperator.StartMotorHoming(new PMR.Diagnostics.MotorHomingRequest()
- {
- Direction = OpenDirection,
- MotorType = Motor,
- Speed = OpeningSpeed,
- }).Subscribe((response) =>
- {
- //Next
- }, (ex) =>
- {
- //Error
- IsEnabled = true;
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, OpeningErrorMessage);
- NotificationProvider.ShowError(ex.FlattenMessage());
- }, () =>
- {
- //Complete
- IsEnabled = true;
- State = MotorState.Opened;
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowSuccess(OpeningSuccessMessage);
- });
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, OpeningErrorMessage);
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowError(ex.FlattenMessage());
- IsEnabled = true;
- }
- }
- else
- {
- IsEnabled = false;
-
- try
- {
- NotificationProvider.SetGlobalBusyMessage(ClosingMessage);
-
- MachineProvider.MachineOperator.StartMotorHoming(new PMR.Diagnostics.MotorHomingRequest()
- {
- Direction = CloseDirection,
- MotorType = Motor,
- Speed = ClosingSpeed,
- }).Subscribe((response) =>
- {
- //Next
- }, (ex) =>
- {
- //Error
- IsEnabled = true;
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, ClosingErrorMessage);
- NotificationProvider.ShowError(ex.FlattenMessage());
- }, () =>
- {
- //Complete
- IsEnabled = true;
- State = MotorState.Closed;
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowSuccess(ClosingSuccessMessage);
- });
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, ClosingErrorMessage);
- NotificationProvider.ReleaseGlobalBusyMessage();
- NotificationProvider.ShowError(ex.FlattenMessage());
- IsEnabled = true;
- }
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseRightLeadingWheelsCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseRightLeadingWheelsCommand.cs
deleted file mode 100644
index ced9eea60..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/OpenCloseRightLeadingWheelsCommand.cs
+++ /dev/null
@@ -1,30 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public class OpenCloseRightLeadingWheelsCommand : OpenCloseMotorCommand
- {
- public OpenCloseRightLeadingWheelsCommand() : base(
- HardwareMotorType.MotoRloading,
- MotorDirection.Backward,
- 250,
- 250,
- MotorState.Closed,
- "Opening right leading wheels...",
- "Closing right leading wheels...",
- "Error opening right leading wheels.",
- "Error closing right leading wheels.",
- "The right leading wheels are now opened.",
- "The right leading wheels are now closed."
- )
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/ResetThreadLoadingCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/ResetThreadLoadingCommand.cs
deleted file mode 100644
index 0078cd546..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Commands/ResetThreadLoadingCommand.cs
+++ /dev/null
@@ -1,24 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.Hardware;
-
-namespace Tango.PPC.Maintenance.Commands
-{
- public class ResetThreadLoadingCommand : HomingMotorCommand
- {
- public ResetThreadLoadingCommand() : base(
- HardwareMotorType.MotoDryerLoadarm,
- MotorDirection.Backward,
- 200,
- "Resetting thread loading arm...",
- "Error resetting thread loading arm.",
- "Thread loading arm in now in place.")
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Controls/StateTouchButton.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Controls/StateTouchButton.cs
deleted file mode 100644
index 9a259482b..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Controls/StateTouchButton.cs
+++ /dev/null
@@ -1,109 +0,0 @@
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Collections.Specialized;
-using System.ComponentModel;
-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.Markup;
-using System.Windows.Media;
-using System.Windows.Media.Imaging;
-using System.Windows.Navigation;
-using System.Windows.Shapes;
-using Tango.Touch.Controls;
-
-namespace Tango.PPC.Maintenance.Controls
-{
- public class ButtonState : DependencyObject
- {
- public Object Value
- {
- get { return (Object)GetValue(ValueProperty); }
- set { SetValue(ValueProperty, value); }
- }
- public static readonly DependencyProperty ValueProperty =
- DependencyProperty.Register("Value", typeof(Object), typeof(ButtonState), new PropertyMetadata(null));
-
- public Object Content
- {
- get { return (Object)GetValue(ContentProperty); }
- set { SetValue(ContentProperty, value); }
- }
- public static readonly DependencyProperty ContentProperty =
- DependencyProperty.Register("Content", typeof(Object), typeof(ButtonState), new PropertyMetadata(null));
- }
-
- [ContentProperty(nameof(States))]
- public class StateTouchButton : TouchButton
- {
- public ObservableCollection<Object> States
- {
- get { return (ObservableCollection<Object>)GetValue(StatesProperty); }
- set { SetValue(StatesProperty, value); }
- }
- public static readonly DependencyProperty StatesProperty =
- DependencyProperty.Register("States", typeof(ObservableCollection<Object>), typeof(StateTouchButton), new PropertyMetadata(null, (d, e) => (d as StateTouchButton).OnStatesChanged()));
-
- public Object SelectedState
- {
- get { return (Object)GetValue(SelectedStateProperty); }
- set { SetValue(SelectedStateProperty, value); }
- }
- public static readonly DependencyProperty SelectedStateProperty =
- DependencyProperty.Register("SelectedState", typeof(Object), typeof(StateTouchButton), new PropertyMetadata(null, (d, e) => (d as StateTouchButton).OnSelectedStateChanged()));
-
- public StateTouchButton()
- {
- States = new ObservableCollection<object>();
- }
-
- private void OnStatesChanged()
- {
- if (States != null)
- {
- States.CollectionChanged -= States_CollectionChanged;
- States.CollectionChanged += States_CollectionChanged;
- OnSelectedStateChanged();
- }
- }
-
- private void OnSelectedStateChanged()
- {
- if (SelectedState == null)
- {
- Content = null;
- return;
- }
-
- if (States != null)
- {
- var converter = TypeDescriptor.GetConverter(SelectedState.GetType());
- var matchingState = States.OfType<ButtonState>().ToList().FirstOrDefault(x => x.Value != null && converter.ConvertFrom(x.Value).Equals(SelectedState));
- if (matchingState != null)
- {
- Content = matchingState.Content;
- }
- else
- {
- Content = null;
- }
- }
- else
- {
- Content = null;
- }
- }
-
- private void States_CollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
- {
- OnSelectedStateChanged();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToBrushConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToBrushConverter.cs
deleted file mode 100644
index c33efdca6..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToBrushConverter.cs
+++ /dev/null
@@ -1,74 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Data;
-using System.Windows.Media;
-using System.Windows.Media.Imaging;
-using Tango.BL.Entities;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Converters
-{
- public class LiquidTypeToBrushConverter : IValueConverter
- {
- public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
- {
- if (value is LiquidType)
- {
- LiquidType type = value as LiquidType;
- switch (type.Type)
- {
- case BL.Enumerations.LiquidTypes.Lubricant:
- {
-
- ImageBrush lubricantBrush = new ImageBrush() { Stretch = Stretch.None, TileMode = TileMode.Tile, ViewportUnits = BrushMappingMode.Absolute };
-
- BitmapSource bit_source = ResourceHelper.GetImageFromResources(@"Images/lubricant2.png");
- var targetBitmap = new WriteableBitmap(new TransformedBitmap(bit_source, new ScaleTransform(0.2, 0.2)));
- lubricantBrush.ImageSource = targetBitmap;
- lubricantBrush.Viewport = new System.Windows.Rect(2, 2, targetBitmap.Width, targetBitmap.Height);
- return lubricantBrush;
- }
- case BL.Enumerations.LiquidTypes.Cleaner:
- {
- ImageBrush cleanerBrush = new ImageBrush() { Stretch = Stretch.None, TileMode = TileMode.Tile, ViewportUnits = BrushMappingMode.Absolute };
- BitmapSource bit_source = ResourceHelper.GetImageFromResources(@"Images/cl-full.png");
- var targetBitmap = new WriteableBitmap(new TransformedBitmap(bit_source, new ScaleTransform(0.3, 0.3)));
-
- cleanerBrush.ImageSource = targetBitmap;
- cleanerBrush.Viewport = new System.Windows.Rect(0, 0, targetBitmap.Width, targetBitmap.Height);
- return cleanerBrush;
- }
- case BL.Enumerations.LiquidTypes.Yellow:
- {
- return new SolidColorBrush(Color.FromRgb(232, 225, 12));
- }
- case BL.Enumerations.LiquidTypes.Cyan:
- {
- return new SolidColorBrush(Color.FromRgb(22, 98, 235));
- }
- case BL.Enumerations.LiquidTypes.Magenta:
- {
- return new SolidColorBrush(Color.FromRgb(237, 0, 140));
- }
- }
-
-
- return new SolidColorBrush(type.LiquidTypeColor);
- }
- return null;
-
- }
-
- public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
- {
- throw new NotImplementedException();
- }
-
- }
-}
-
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToShortNameConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToShortNameConverter.cs
deleted file mode 100644
index 15041bf17..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/LiquidTypeToShortNameConverter.cs
+++ /dev/null
@@ -1,41 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Data;
-using Tango.BL.Entities;
-
-namespace Tango.PPC.Maintenance.Converters
-{
- class LiquidTypeToShortNameConverter : IValueConverter
- {
- public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
- {
- if (value is LiquidType)
- {
- LiquidType type = value as LiquidType;
- switch (type.Type)
- {
- case BL.Enumerations.LiquidTypes.Cleaner:
- return "CL";
- case BL.Enumerations.LiquidTypes.TransparentInk:
- return "TI";
- case BL.Enumerations.LiquidTypes.Black:
- return "K";
- }
- return type.Name.First().ToString();
- }
- else
- {
- return value;
- }
- }
-
- public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
- {
- throw new NotImplementedException();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/MidTankLevelToElementHeightConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/MidTankLevelToElementHeightConverter.cs
deleted file mode 100644
index 94d1ed8b8..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/MidTankLevelToElementHeightConverter.cs
+++ /dev/null
@@ -1,34 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Data;
-using Tango.Integration.Operation;
-
-namespace Tango.PPC.Maintenance.Converters
-{
- public class MidTankLevelToElementHeightConverter : IMultiValueConverter
- {
- public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
- {
- try
- {
- double parentActualHeight = (double)values[0];
- double midTankLevel = Math.Min((double)values[1], MachineOperator.MAX_MIDTANK_LITERS);
- //var test = (parentActualHeight - (midTankLevel / MachineOperator.MAX_MIDTANK_LITERS) * parentActualHeight);
- return (parentActualHeight - (midTankLevel / MachineOperator.MAX_MIDTANK_LITERS) * parentActualHeight);
- }
- catch
- {
- return 0d;
- }
- }
-
- public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture)
- {
- throw new NotImplementedException();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/StringToFirstLetterConverter.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/StringToFirstLetterConverter.cs
deleted file mode 100644
index 0922af78d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Converters/StringToFirstLetterConverter.cs
+++ /dev/null
@@ -1,30 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Data;
-
-namespace Tango.PPC.Maintenance.Converters
-{
- public class StringToFirstLetterConverter : IValueConverter
- {
- public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
- {
- if (value != null && value.ToString().Length > 1)
- {
- return value.ToString().First().ToString();
- }
- else
- {
- return value;
- }
- }
-
- public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
- {
- throw new NotImplementedException();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml
deleted file mode 100644
index 98be45608..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml
+++ /dev/null
@@ -1,66 +0,0 @@
-<UserControl x:Class="Tango.PPC.Maintenance.Dialogs.CleanerDispensingView"
- 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:local="clr-namespace:Tango.PPC.Maintenance.Dialogs"
- mc:Ignorable="d"
- Background="{StaticResource TangoPrimaryBackgroundBrush}" d:DesignHeight="555" d:DesignWidth="560" Width="600" Height="950" d:DataContext="{d:DesignInstance Type=local:CleanerDispensingViewVM, IsDesignTimeCreatable=False}">
- <Grid>
- <StackPanel Margin="0 50 0 0" HorizontalAlignment="Center">
- <Image Source="../Images/head_cleaning.png" RenderOptions.BitmapScalingMode="Fant" Stretch="Uniform" Height="120"></Image>
- <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}" Margin="0 30 0 0">Dispense Cleaning Liquid</TextBlock>
-
-
- <DockPanel Margin="20 40" HorizontalAlignment="Center">
- <touch:TouchIcon Icon="Alert" Foreground="{StaticResource TangoErrorBrush}" />
- <TextBlock Margin="5 0 0 0" VerticalAlignment="Center" Foreground="{StaticResource TangoErrorBrush}">Please put on safety glasses</TextBlock>
- </DockPanel>
-
- <Label Margin="20 10" HorizontalAlignment="Center">
- <Label.Style>
- <Style TargetType="Label">
- <Setter Property="Content">
- <Setter.Value>
- <TextBlock LineHeight="30" TextWrapping="Wrap">
- <Run>1. Pull the thread aside and clean with Q tip when the liquid is dispensed.</Run>
- <LineBreak/>
- <Run>2. Dispense again if the liquid isn't enough for cleaning.</Run>
- <LineBreak/>
- <Run>3. When cleaning is completed, return the thread back to the V-Groove and press the 'Close Dyeing Head Lid' button to close the head lid</Run>
- </TextBlock>
- </Setter.Value>
- </Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding MachineProvider.Machine.MachineHeadType}" Value="Arc">
- <Setter Property="Content">
- <Setter.Value>
- <TextBlock LineHeight="30" TextWrapping="Wrap">
- <Run>1. Open the dyeing head lid, pull the thread aside and clean with Q tip when the liquid is dispensed.</Run>
- <LineBreak/>
- <Run>2. Dispense again if the liquid isn't enough for cleaning.</Run>
- <LineBreak/>
- <Run>3. When cleaning is completed, return the thread back to the V-Groove and install the head lid back.</Run>
- </TextBlock>
- </Setter.Value>
- </Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Label.Style>
- </Label>
-
- <Grid>
- <touch:TouchButton Command="{Binding StartCommand}" Margin="0 100 0 0" Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Center" Padding="80 15" CornerRadius="25">START</touch:TouchButton>
- </Grid>
-
- <StackPanel Margin="40 150 40 40">
- <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Status}"></TextBlock>
- <touch:TouchProgressBar Margin="0 5 0 0" VerticalAlignment="Bottom" Height="10" Minimum="0" Maximum="100" Value="0" IsIndeterminate="{Binding IsStarted}">
-
- </touch:TouchProgressBar>
- </StackPanel>
- </StackPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml.cs
deleted file mode 100644
index 6f1ebb4ed..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Maintenance.Dialogs
-{
- /// <summary>
- /// Interaction logic for PowerUpView.xaml
- /// </summary>
- public partial class CleanerDispensingView : UserControl
- {
- public CleanerDispensingView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingViewVM.cs
deleted file mode 100644
index e37be417f..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/CleanerDispensingViewVM.cs
+++ /dev/null
@@ -1,128 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Timers;
-using Tango.BL.Entities;
-using Tango.Core.Commands;
-using Tango.Core.DI;
-using Tango.Integration.Operation;
-using Tango.PMR.Printing;
-using Tango.PPC.Common;
-using Tango.PPC.Common.Connection;
-using Tango.PPC.Common.Notifications;
-using Tango.Settings;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Maintenance.Dialogs
-{
- public class CleanerDispensingViewVM : DialogViewVM
- {
- private const int JOGGING_TIME_SEC = 10;
- private const int JOGGING_SPEED = 400;
-
- [TangoInject]
- public IMachineProvider MachineProvider { get; set; }
-
- [TangoInject]
- private INotificationProvider NotificationProvider { get; set; }
-
- private bool _isStarted;
- public bool IsStarted
- {
- get { return _isStarted; }
- set { _isStarted = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isCompleted;
- public bool IsCompleted
- {
- get { return _isCompleted; }
- set { _isCompleted = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isFailed;
- public bool IsFailed
- {
- get { return _isFailed; }
- set { _isFailed = value; RaisePropertyChangedAuto(); }
- }
-
- private String _status;
- public String Status
- {
- get { return _status; }
- set { _status = value; RaisePropertyChangedAuto(); }
- }
-
- public RelayCommand StartCommand { get; set; }
-
- public CleanerDispensingViewVM()
- {
- Status = "Ready...";
- CanClose = true;
- TangoIOC.Default.Inject(this);
- StartCommand = new RelayCommand(Start, () => !IsStarted);
- }
-
- private async void Start()
- {
- try
- {
- CanClose = false;
- IsStarted = true;
- IsCompleted = false;
- IsFailed = false;
- InvalidateRelayCommands();
-
- Status = "Dispensing cleaner liquid...";
-
- var cleanerPack = MachineProvider.Machine.Configuration.NoneEmptyIdsPacks.FirstOrDefault(x => x.LiquidType.Type == BL.Enumerations.LiquidTypes.Cleaner);
-
- if (cleanerPack == null)
- {
- throw new InvalidOperationException("'Cleaner' liquid type was not found on the machine configuration.");
- }
-
- var cleanerIndex = cleanerPack.PackIndex;
-
- await MachineProvider.MachineOperator.StartDispenserJogging(new PMR.Diagnostics.DispenserJoggingRequest()
- {
- Direction = PMR.Diagnostics.MotorDirection.Forward,
- Speed = JOGGING_SPEED,
- Index = cleanerIndex
- });
-
- await Task.Delay(TimeSpan.FromSeconds(JOGGING_TIME_SEC));
-
- await MachineProvider.MachineOperator.StopDispenserJogging(new PMR.Diagnostics.DispenserAbortJoggingRequest()
- {
- Index = cleanerIndex
- });
-
- IsCompleted = true;
- Status = "Cleaner liquid dispensing completed.";
- }
- catch (Exception ex)
- {
- Status = "Cleaner liquid dispensing failed.";
- IsFailed = true;
- await NotificationProvider.ShowError($"Error occurred while trying to perform the cleaner liquid dispensing.\n{ex.FlattenMessage()}");
- }
- finally
- {
- CanClose = true;
- IsStarted = false;
- }
- }
-
- protected override void Cancel()
- {
- if (CanClose)
- {
- base.Cancel();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml
deleted file mode 100644
index f640d5cec..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml
+++ /dev/null
@@ -1,56 +0,0 @@
-<UserControl x:Class="Tango.PPC.Maintenance.Dialogs.HeadCleaningView"
- 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:local="clr-namespace:Tango.PPC.Maintenance.Dialogs"
- mc:Ignorable="d"
- Background="{StaticResource TangoPrimaryBackgroundBrush}" d:DesignHeight="555" d:DesignWidth="560" Width="600" Height="800" d:DataContext="{d:DesignInstance Type=local:HeadCleaningViewVM, IsDesignTimeCreatable=False}">
- <Grid>
- <StackPanel Margin="0 50 0 0" HorizontalAlignment="Center">
- <Image Source="../Images/head_cleaning.png" RenderOptions.BitmapScalingMode="Fant" Stretch="Uniform" Height="120"></Image>
- <TextBlock HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}" Margin="0 30 0 0">Head Cleaning</TextBlock>
-
- <TextBlock Margin="20 10" HorizontalAlignment="Center" TextWrapping="Wrap" TextAlignment="Center">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Text" Value="Press 'START' to start the head cleaning sequence"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsStarted}" Value="True">
- <Setter Property="Text" Value="Head cleaning in progress"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsAborting}" Value="True">
- <Setter Property="Text" Value="Aborting head cleaning"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsCompleted}" Value="True">
- <Setter Property="Text" Value="Head cleaning completed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- </TextBlock>
-
- <Grid>
- <touch:TouchButton Visibility="{Binding IsStarted,Converter={StaticResource BooleanToVisibilityInverseConverter}}" Command="{Binding StartCommand}" Margin="0 100 0 0" Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Center" Padding="80 15" CornerRadius="25">START</touch:TouchButton>
- <touch:TouchButton Visibility="{Binding IsStarted,Converter={StaticResource BooleanToVisibilityConverter}}" IsEnabled="{Binding IsAborting,Converter={StaticResource BooleanInverseConverter}}" Command="{Binding AbortCommand}" Margin="0 100 0 0" Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Center" Padding="80 15" CornerRadius="25">ABORT</touch:TouchButton>
- </Grid>
-
- <StackPanel Margin="40">
- <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Status.Status}"></TextBlock>
- <touch:TouchProgressBar Margin="0 20 0 0" VerticalAlignment="Bottom" Width="500" Height="10" Minimum="0" Maximum="{Binding Status.Total}" Value="{Binding Status.Progress}">
- <touch:TouchProgressBar.Style>
- <Style TargetType="touch:TouchProgressBar" BasedOn="{StaticResource {x:Type touch:TouchProgressBar}}">
- <Setter Property="IsIndeterminate" Value="False"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Status.Progress}" Value="0">
- <Setter Property="IsIndeterminate" Value="True"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchProgressBar.Style>
- </touch:TouchProgressBar>
- </StackPanel>
- </StackPanel>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml.cs
deleted file mode 100644
index c715bf5cf..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Maintenance.Dialogs
-{
- /// <summary>
- /// Interaction logic for PowerUpView.xaml
- /// </summary>
- public partial class HeadCleaningView : UserControl
- {
- public HeadCleaningView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningViewVM.cs
deleted file mode 100644
index 59d119f21..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Dialogs/HeadCleaningViewVM.cs
+++ /dev/null
@@ -1,150 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Timers;
-using Tango.BL.Entities;
-using Tango.Core.Commands;
-using Tango.Core.DI;
-using Tango.Integration.Operation;
-using Tango.PMR.Printing;
-using Tango.PPC.Common;
-using Tango.PPC.Common.Connection;
-using Tango.PPC.Common.Notifications;
-using Tango.Settings;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Maintenance.Dialogs
-{
- public class HeadCleaningViewVM : DialogViewVM
- {
- private HeadCleaningHandler _handler;
-
- [TangoInject]
- private IMachineProvider MachineProvider { get; set; }
-
- [TangoInject]
- private INotificationProvider NotificationProvider { get; set; }
-
- private bool _isStarted;
- public bool IsStarted
- {
- get { return _isStarted; }
- set { _isStarted = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isCompleted;
- public bool IsCompleted
- {
- get { return _isCompleted; }
- set { _isCompleted = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isAborting;
- public bool IsAborting
- {
- get { return _isAborting; }
- set { _isAborting = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isFailed;
- public bool IsFailed
- {
- get { return _isFailed; }
- set { _isFailed = value; RaisePropertyChangedAuto(); }
- }
-
- private StartHeadCleaningResponse _status;
- public StartHeadCleaningResponse Status
- {
- get { return _status; }
- set { _status = value; RaisePropertyChangedAuto(); }
- }
-
- public RelayCommand StartCommand { get; set; }
- public RelayCommand AbortCommand { get; set; }
-
- public HeadCleaningViewVM()
- {
- CanClose = true;
- TangoIOC.Default.Inject(this);
- StartCommand = new RelayCommand(Start);
- AbortCommand = new RelayCommand(Abort);
- }
-
- private async void Start()
- {
- try
- {
- CanClose = false;
- IsStarted = true;
- _handler = await MachineProvider.MachineOperator.PerformHeadCleaning();
- _handler.Completed += _handler_Completed;
- _handler.Failed += _handler_Failed;
- _handler.StatusChanged += _handler_StatusChanged;
- }
- catch (Exception ex)
- {
- _handler_Failed(this, ex);
- }
- }
-
- private void _handler_StatusChanged(object sender, HeadCleaningStatusChangedEventArgs e)
- {
- Status = e.Status;
- }
-
- private void _handler_Failed(object sender, Exception e)
- {
- IsStarted = false;
- IsFailed = true;
- InvokeUI(() =>
- {
- CanClose = true;
- Cancel();
- NotificationProvider.ShowError($"Error occurred while trying to perform the head cleaning.\n{e.FlattenMessage()}");
- });
- }
-
- private void _handler_Completed(object sender, EventArgs e)
- {
- IsStarted = false;
- IsCompleted = true;
- InvokeUI(() =>
- {
- Accept();
- NotificationProvider.ShowSuccess("Head cleaning completed successfully.");
- });
- }
-
- protected override void Cancel()
- {
- if (CanClose)
- {
- base.Cancel();
- }
- }
-
- private async void Abort()
- {
- IsAborting = true;
- try
- {
- await _handler.Abort();
- CanClose = true;
- Cancel();
- await NotificationProvider.ShowInfo("Head cleaning aborted.");
- }
- catch (Exception ex)
- {
- if (!IsCompleted)
- {
- CanClose = true;
- IsAborting = false;
- await NotificationProvider.ShowError($"Error occurred while trying to abort the head cleaning.\n{ex.FlattenMessage()}");
- }
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideBase.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideBase.cs
deleted file mode 100644
index 438375c72..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideBase.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-
-namespace Tango.PPC.Maintenance
-{
- public abstract class GuideBase
- {
- public abstract String Name { get; }
- public abstract BitmapSource Icon { get; }
- public abstract String Image { get; }
- public abstract List<GuideStep> Steps { get; }
-
- protected virtual List<GuideStep> GetStepsFromResource(String key)
- {
- List<GuideStep> list = new List<GuideStep>();
-
- var arr = (Application.Current.Resources[key] as Array);
-
- foreach (var item in arr)
- {
- list.Add(new GuideStep()
- {
- Text = item
- });
- }
-
- return list;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideStep.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideStep.cs
deleted file mode 100644
index 71a70d9db..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/GuideStep.cs
+++ /dev/null
@@ -1,21 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core;
-
-namespace Tango.PPC.Maintenance
-{
- public class GuideStep : ExtendedObject
- {
- public Object Text { get; set; }
-
- private bool _isChecked;
- public bool IsChecked
- {
- get { return _isChecked; }
- set { _isChecked = value; RaisePropertyChangedAuto(); }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/HandleWasteCartridgeGuide.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/HandleWasteCartridgeGuide.cs
deleted file mode 100644
index a4820e349..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/HandleWasteCartridgeGuide.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Guides
-{
- public class HandleWasteCartridgeGuide : GuideBase
- {
- public override string Name => "Handling the Waste Cartridges";
- public override String Image => "../Images/Guides/Residue-Cartridges-A.gif";
-
- private BitmapSource _icon;
- public override BitmapSource Icon
- {
- get
- {
- if (_icon == null)
- {
- _icon = ResourceHelper.GetImageFromResources("Images/Guides/handling-the-waste-cartridges.png");
- }
- return _icon;
- }
- }
-
- private List<GuideStep> _steps;
- public override List<GuideStep> Steps
- {
- get
- {
- if (_steps == null)
- {
- _steps = GetStepsFromResource("HandleWasteCartridge");
- }
- return _steps;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadInkCartridgeGuide.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadInkCartridgeGuide.cs
deleted file mode 100644
index 1a6ed8321..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadInkCartridgeGuide.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Guides
-{
- public class LoadInkCartridgeGuide : GuideBase
- {
- public override string Name => "Loading an Ink Cartridge";
- public override String Image => "../Images/Guides/Loading-an-Ink-Cartridge.gif";
-
- private BitmapSource _icon;
- public override BitmapSource Icon
- {
- get
- {
- if (_icon == null)
- {
- _icon = ResourceHelper.GetImageFromResources("Images/Guides/loading-an-ink-cartridge.png");
- }
- return _icon;
- }
- }
-
- private List<GuideStep> _steps;
- public override List<GuideStep> Steps
- {
- get
- {
- if (_steps == null)
- {
- _steps = GetStepsFromResource("LoadInkCartridge");
- }
- return _steps;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadNewThreadGuide.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadNewThreadGuide.cs
deleted file mode 100644
index d5115a748..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/LoadNewThreadGuide.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Guides
-{
- public class LoadNewThreadGuide : GuideBase
- {
- public override string Name => "Loading New Thread";
- public override String Image => "../Images/Guides/Loading-New-Thread.gif";
-
- private BitmapSource _icon;
- public override BitmapSource Icon
- {
- get
- {
- if (_icon == null)
- {
- _icon = ResourceHelper.GetImageFromResources("Images/Guides/loading-new-thread.png");
- }
- return _icon;
- }
- }
-
- private List<GuideStep> _steps;
- public override List<GuideStep> Steps
- {
- get
- {
- if (_steps == null)
- {
- _steps = GetStepsFromResource("LoadNewThread");
- }
- return _steps;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceAirFilterGuide.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceAirFilterGuide.cs
deleted file mode 100644
index d335867ca..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceAirFilterGuide.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Guides
-{
- public class ReplaceAirFilterGuide : GuideBase
- {
- public override string Name => "Replacing the Air Filter";
- public override String Image => "../Images/Guides/Replacing-the-Air-Filter.gif";
-
- private BitmapSource _icon;
- public override BitmapSource Icon
- {
- get
- {
- if (_icon == null)
- {
- _icon = ResourceHelper.GetImageFromResources("Images/Guides/replacing-the-air-filter.png");
- }
- return _icon;
- }
- }
-
- private List<GuideStep> _steps;
- public override List<GuideStep> Steps
- {
- get
- {
- if (_steps == null)
- {
- _steps = GetStepsFromResource("ReplaceAirFilter");
- }
- return _steps;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceThreadGuide.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceThreadGuide.cs
deleted file mode 100644
index ecc3f6026..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Guides/ReplaceThreadGuide.cs
+++ /dev/null
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Media.Imaging;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance.Guides
-{
- public class ReplaceThreadGuide : GuideBase
- {
- public override string Name => "Replacing the Thread";
- public override String Image => "../Images/Guides/Replacing-the-Thread.gif";
-
- private BitmapSource _icon;
- public override BitmapSource Icon
- {
- get
- {
- if (_icon == null)
- {
- _icon = ResourceHelper.GetImageFromResources("Images/Guides/replacing-the-thread.png");
- }
- return _icon;
- }
- }
-
- private List<GuideStep> _steps;
- public override List<GuideStep> Steps
- {
- get
- {
- if (_steps == null)
- {
- _steps = GetStepsFromResource("ReplaceThread");
- }
- return _steps;
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Helpers/GuideHelper.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Helpers/GuideHelper.cs
deleted file mode 100644
index 32518974d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Helpers/GuideHelper.cs
+++ /dev/null
@@ -1,33 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-
-namespace Tango.PPC.Maintenance.Helpers
-{
- public static class GuideHelper
- {
- public static List<GuideBase> CreateAllGuides()
- {
- var resource = new ResourceDictionary
- {
- Source = new Uri("/Tango.PPC.Maintenance;component/Resources/Guides.xaml", UriKind.RelativeOrAbsolute)
- };
-
- Application.Current.Resources.MergedDictionaries.Add(resource);
-
- List<GuideBase> guides = new List<GuideBase>();
-
- var callingAssembly = typeof(GuideHelper).Assembly;
-
- foreach (var guideType in callingAssembly.DefinedTypes.Where(x => x.Namespace == "Tango.PPC.Maintenance.Guides"))
- {
- guides.Add(Activator.CreateInstance(guideType) as GuideBase);
- }
-
- return guides;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-New-Thread.gif b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-New-Thread.gif
deleted file mode 100644
index b6a974084..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-New-Thread.gif
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-an-Ink-Cartridge.gif b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-an-Ink-Cartridge.gif
deleted file mode 100644
index 7087ebc64..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Loading-an-Ink-Cartridge.gif
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Air-Filter.gif b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Air-Filter.gif
deleted file mode 100644
index 023adb4a9..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Air-Filter.gif
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Thread.gif b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Thread.gif
deleted file mode 100644
index 8ab544d8b..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Replacing-the-Thread.gif
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Residue-Cartridges-A.gif b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Residue-Cartridges-A.gif
deleted file mode 100644
index c310820b4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/Residue-Cartridges-A.gif
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/handling-the-waste-cartridges.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/handling-the-waste-cartridges.png
deleted file mode 100644
index 188e881bb..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/handling-the-waste-cartridges.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-an-ink-cartridge.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-an-ink-cartridge.png
deleted file mode 100644
index 4f4dfc375..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-an-ink-cartridge.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-new-thread.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-new-thread.png
deleted file mode 100644
index 1f508261b..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/loading-new-thread.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image.png
deleted file mode 100644
index 277599070..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-air-filter.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-air-filter.png
deleted file mode 100644
index eb8f518a3..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-air-filter.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-thread.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-thread.png
deleted file mode 100644
index e858c3075..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/replacing-the-thread.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/absent.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/absent.png
deleted file mode 100644
index 8fc4e1b33..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/absent.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_error.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_error.png
deleted file mode 100644
index ff2411eb5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_error.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_right.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_right.png
deleted file mode 100644
index 08b9a7076..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_empty_right.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_full_right.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_full_right.png
deleted file mode 100644
index a39b6f073..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Waste/present_full_right.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/action.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/action.png
deleted file mode 100644
index 6d14ec5dc..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/action.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cl-full.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cl-full.png
deleted file mode 100644
index 5aaea8e6c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cl-full.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-empty.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-empty.png
deleted file mode 100644
index 17c3225ed..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-empty.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-full.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-full.png
deleted file mode 100644
index b4ed45d1e..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/cone-full.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/guides.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/guides.png
deleted file mode 100644
index 13b9013d7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/guides.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/head_cleaning.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/head_cleaning.png
deleted file mode 100644
index 373cb78c1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/head_cleaning.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/inks.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/inks.png
deleted file mode 100644
index 3872a77e4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/inks.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/l-full.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/l-full.png
deleted file mode 100644
index 2607f4a26..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/l-full.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/lubricant2.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/lubricant2.png
deleted file mode 100644
index 554c16305..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/lubricant2.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/maintenance.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/maintenance.png
deleted file mode 100644
index 526284750..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/maintenance.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/status.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/status.png
deleted file mode 100644
index 0cc205a6c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/status.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-green.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-green.png
deleted file mode 100644
index f67323dde..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-green.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-red.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-red.png
deleted file mode 100644
index 5e6b505a3..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-red.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-yellow.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-yellow.png
deleted file mode 100644
index 359e93d6d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/temperature-yellow.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/thread_loading.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/thread_loading.png
deleted file mode 100644
index 5d536e7ae..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/thread_loading.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceCommand.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceCommand.cs
deleted file mode 100644
index 5c74d92cd..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceCommand.cs
+++ /dev/null
@@ -1,81 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core;
-using Tango.Core.Commands;
-using Tango.Core.DI;
-using Tango.Integration.Operation;
-using Tango.PPC.Common.Connection;
-using Tango.PPC.Common.Notifications;
-
-namespace Tango.PPC.Maintenance
-{
- public abstract class MaintenanceCommand<T> : ExtendedObject
- {
- private IMachineProvider _machineProvider;
- [TangoInject(Mode = TangoInjectMode.WhenAvailable)]
- protected IMachineProvider MachineProvider
- {
- get { return _machineProvider; }
- set
- {
- _machineProvider = value; RaisePropertyChangedAuto();
- _machineProvider.MachineOperator.StatusChanged += MachineOperator_StatusChanged;
- }
- }
-
- [TangoInject(Mode = TangoInjectMode.WhenAvailable)]
- protected INotificationProvider NotificationProvider { get; set; }
-
- private RelayCommand _command;
- public RelayCommand Command
- {
- get { return _command; }
- set { _command = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _isEnabled;
- public bool IsEnabled
- {
- get { return _isEnabled; }
- set { _isEnabled = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private T _state;
- public T State
- {
- get { return _state; }
- set { _state = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private void MachineOperator_StatusChanged(object sender, MachineStatuses e)
- {
- InvalidateRelayCommands();
- }
-
- public MaintenanceCommand()
- {
- TangoIOC.Default.Inject(this);
- IsEnabled = true;
- Command = new RelayCommand(Execute, CanExecute);
- }
-
- protected virtual bool CanExecute()
- {
- if (!IsEnabled) return false;
- if (MachineProvider == null) return false;
- if (!MachineProvider.MachineOperator.CanPrint) return false;
-
- return true;
- }
-
- private void Execute()
- {
- OnExecute();
- }
-
- protected abstract void OnExecute();
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceModule.cs
deleted file mode 100644
index 18871ac78..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/MaintenanceModule.cs
+++ /dev/null
@@ -1,84 +0,0 @@
-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.Maintenance.Views;
-using Tango.SharedUI.Helpers;
-
-namespace Tango.PPC.Maintenance
-{
- /// <summary>
- /// Represents a PPC <see cref="MaintenanceModule"/>.
- /// </summary>
- /// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(3)]
- public class MaintenanceModule : PPCModuleBase
- {
- /// <summary>
- /// Gets the module name.
- /// </summary>
- public override string Name
- {
- get
- {
- return "Maintenance";
- }
- }
-
- /// <summary>
- /// Gets the module description.
- /// </summary>
- public override string Description
- {
- get
- {
- return "PPC maintenance module.";
- }
- }
-
- /// <summary>
- /// Gets the module cover image.
- /// </summary>
- public override BitmapSource Image
- {
- get
- {
- return ResourceHelper.GetImageFromResources("Images/maintenance.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.Maintenance/Models/MidTankLevelModel.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/MidTankLevelModel.cs
deleted file mode 100644
index 93af310ba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/MidTankLevelModel.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.BL.Entities;
-using Tango.Core;
-using Tango.Integration.Operation;
-
-namespace Tango.PPC.Maintenance.Models
-{
- public class MidTankLevelModel : ExtendedObject
- {
- public double Max { get; set; }
-
- private double _level;
- public double Level
- {
- get { return _level; }
- set { _level = value; RaisePropertyChangedAuto(); RaisePropertyChanged(nameof(IsLow)); RaisePropertyChanged(nameof(IsEmpty)); }
- }
-
- public bool IsLow
- {
- get { return Level <= MachineOperator.LOW_MIDTANK_LITERS; }
- }
-
- public bool IsEmpty
- {
- get { return Level <= MachineOperator.EMPTY_MIDTANK_LITERS; }
- }
-
- public IdsPack IDSPack { get; set; }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/OverallTemperatureModel.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/OverallTemperatureModel.cs
deleted file mode 100644
index 694071d0d..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Models/OverallTemperatureModel.cs
+++ /dev/null
@@ -1,30 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core;
-using Tango.Integration.Operation;
-
-namespace Tango.PPC.Maintenance.Models
-{
- public class OverallTemperatureModel : ExtendedObject
- {
- private double _temperature;
- public double Temperature
- {
- get { return _temperature; }
- set { _temperature = value; RaisePropertyChangedAuto(); RaisePropertyChanged(nameof(IsWarning)); RaisePropertyChanged(nameof(IsError)); }
- }
-
- public bool IsWarning
- {
- get { return Temperature > MachineOperator.OVERALL_TEMPERATURE_WARNING; }
- }
-
- public bool IsError
- {
- get { return Temperature >= MachineOperator.OVERALL_TEMPERATURE_ERROR; }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/AssemblyInfo.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/AssemblyInfo.cs
deleted file mode 100644
index 52774bee8..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/AssemblyInfo.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-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 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.Maintenance/Properties/Resources.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.Designer.cs
deleted file mode 100644
index 003dc17e5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.Designer.cs
+++ /dev/null
@@ -1,63 +0,0 @@
-//------------------------------------------------------------------------------
-// <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.Maintenance.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.Maintenance.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.Maintenance/Properties/Resources.resx b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.resx
deleted file mode 100644
index af7dbebba..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-<?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.Maintenance/Properties/Settings.Designer.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.Designer.cs
deleted file mode 100644
index 7b549e7b7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.Designer.cs
+++ /dev/null
@@ -1,26 +0,0 @@
-//------------------------------------------------------------------------------
-// <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.Maintenance.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.Maintenance/Properties/Settings.settings b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.settings
deleted file mode 100644
index 033d7a5e9..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Properties/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-<?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.Maintenance/Resources/Guides.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Resources/Guides.xaml
deleted file mode 100644
index 24e1e0d71..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Resources/Guides.xaml
+++ /dev/null
@@ -1,60 +0,0 @@
-<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:sys="clr-namespace:System;assembly=mscorlib"
- xmlns:local="clr-namespace:Tango.PPC.Maintenance.Resources">
-
- <x:Array x:Key="LoadNewThread" Type="sys:String">
- <sys:String>1. Loading New Thread</sys:String>
- <sys:String>2. Wait for a message indicating the system is ready to load the thread</sys:String>
- <sys:String>3. Place a cone with un-dyed thread into the thread feeding unit</sys:String>
- <sys:String>4. Feed the thread along the thread groove to the winder</sys:String>
- <sys:String>5. Place an empty collecting cone into the thread winder</sys:String>
- <sys:String>6. Insert the end of the thread into the empty collecting cone</sys:String>
- <sys:String>7. On the TS-1800 panel, press LOAD again</sys:String>
- </x:Array>
-
- <x:Array x:Key="HandleWasteCartridge" Type="sys:String">
- <sys:String>1. On the TS-1800 panel, press LOAD</sys:String>
- <sys:String>2. Wait for a message indicating the system is ready to load the thread</sys:String>
- <sys:String>3. Place a cone with un-dyed thread into the thread feeding unit</sys:String>
- <sys:String>4. Feed the tread along the feeding path up to the top cover</sys:String>
- <sys:String>5. Feed the thread along the thread groove to the winder</sys:String>
- <sys:String>6. Place an empty collecting cone into the thread winder</sys:String>
- <sys:String>7. Insert the end of the thread into the empty collecting cone</sys:String>
- <sys:String>8. On the TS-1800 panel, press LOAD again</sys:String>
- </x:Array>
-
- <x:Array x:Key="ReplaceThread" Type="sys:String">
- <sys:String>1. Cut the current thread just after the feeding cone</sys:String>
- <sys:String>2. Remove the current feeding cone</sys:String>
- <sys:String>3. Place the new feeding cone into the thread feeding unit</sys:String>
- <sys:String>4. Tie the new thread to the current thread</sys:String>
- <sys:String>5. Cut off the ends of the thread leaving a small knot</sys:String>
- <sys:String>6. On the TS-1800 panel, press and hold the JOG button</sys:String>
- <sys:String>7. Hold the JOG button until the knot appears at the collecting cone</sys:String>
- <sys:String>8. Cut the thread at the collecting cone after the knot</sys:String>
- <sys:String>9. Remove the collecting cone</sys:String>
- <sys:String>10. Place an empty collecting cone into the winder</sys:String>
- <sys:String>11. Insert the end of the new thread into the empty collecting cone</sys:String>
- </x:Array>
-
- <x:Array x:Key="ReplaceAirFilter" Type="sys:String">
- <sys:String>1. Open the air filter cover</sys:String>
- <sys:String>2. Remove the old air filter</sys:String>
- <sys:String>3. Insert a new air filter</sys:String>
- <sys:String>4. Close the air filter cover</sys:String>
- </x:Array>
-
- <x:Array x:Key="LoadInkCartridge" Type="sys:String">
- <sys:String>1. Open the cartridge cover</sys:String>
- <sys:String>2. Insert a full ink cartridge into the ink-loading slot</sys:String>
- <sys:String>3. Close the cartridge cover</sys:String>
- <sys:String>4. When ink loading is complete, open the cartridge cover</sys:String>
- <sys:String>5. Remove the empty ink cartridge</sys:String>
- <sys:String>6. Remove the stopper from the residue-filling opening</sys:String>
- <sys:String>7. Place the stopper into its allocated position on the top side of the empty ink cartridge</sys:String>
- <sys:String>8. Put the empty ink cartridge into storage. Optional: if an empty recycling slot is available</sys:String>
- <sys:String>9. Insert the empty ink cartridge into the slot for ink recycling</sys:String>
- </x:Array>
-
-</ResourceDictionary> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj
deleted file mode 100644
index 9dd45add4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj
+++ /dev/null
@@ -1,320 +0,0 @@
-<?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>{011470AC-6BD6-4366-B5F2-C82C065D4A84}</ProjectGuid>
- <OutputType>library</OutputType>
- <RootNamespace>Tango.PPC.Maintenance</RootNamespace>
- <AssemblyName>Tango.PPC.Maintenance</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.2.0\lib\net45\EntityFramework.dll</HintPath>
- </Reference>
- <Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
- <HintPath>..\..\..\packages\EntityFramework.6.2.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="Ionic.Zip, Version=1.9.1.8, Culture=neutral, PublicKeyToken=edbe51ad942a3f5c, processorArchitecture=MSIL">
- <HintPath>..\..\..\packages\Ionic.Zip.1.9.1.8\lib\Ionic.Zip.dll</HintPath>
- </Reference>
- <Reference Include="System" />
- <Reference Include="System.ComponentModel.DataAnnotations" />
- <Reference Include="System.Data" />
- <Reference Include="System.Reactive.Core, Version=3.0.3000.0, Culture=neutral, PublicKeyToken=94bc3704cddfc263, processorArchitecture=MSIL">
- <HintPath>..\..\..\packages\System.Reactive.Core.3.1.1\lib\net46\System.Reactive.Core.dll</HintPath>
- </Reference>
- <Reference Include="System.Reactive.Interfaces, Version=3.0.1000.0, Culture=neutral, PublicKeyToken=94bc3704cddfc263, processorArchitecture=MSIL">
- <HintPath>..\..\..\packages\System.Reactive.Interfaces.3.1.1\lib\net45\System.Reactive.Interfaces.dll</HintPath>
- </Reference>
- <Reference Include="System.Reactive.Linq, Version=3.0.3000.0, Culture=neutral, PublicKeyToken=94bc3704cddfc263, processorArchitecture=MSIL">
- <HintPath>..\..\..\packages\System.Reactive.Linq.3.1.1\lib\net46\System.Reactive.Linq.dll</HintPath>
- </Reference>
- <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="Dialogs\CleanerDispensingView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Dialogs\HeadCleaningView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Resources\Guides.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- <Page Include="Themes\Generic.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- <Page Include="Views\GeneralGuideView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- <Page Include="Views\MaintenanceView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\MainView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- </ItemGroup>
- <ItemGroup>
- <Compile Include="..\..\..\Versioning\GlobalVersionInfo.cs">
- <Link>GlobalVersionInfo.cs</Link>
- </Compile>
- <Compile Include="Commands\HomingMotorCommand.cs" />
- <Compile Include="Commands\OpenCloseDyeingHeadCommand.cs" />
- <Compile Include="Commands\OpenCloseRightLeadingWheelsCommand.cs" />
- <Compile Include="Commands\OpenCloseLeftLeadingWheelsCommand.cs" />
- <Compile Include="Commands\OpenCloseMotorCommand.cs" />
- <Compile Include="Commands\ResetThreadLoadingCommand.cs" />
- <Compile Include="Controls\StateTouchButton.cs" />
- <Compile Include="Converters\LiquidTypeToBrushConverter.cs" />
- <Compile Include="Converters\LiquidTypeToShortNameConverter.cs" />
- <Compile Include="Converters\MidTankLevelToElementHeightConverter.cs" />
- <Compile Include="Converters\StringToFirstLetterConverter.cs" />
- <Compile Include="Dialogs\CleanerDispensingView.xaml.cs">
- <DependentUpon>CleanerDispensingView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Dialogs\HeadCleaningView.xaml.cs">
- <DependentUpon>HeadCleaningView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Dialogs\CleanerDispensingViewVM.cs" />
- <Compile Include="Dialogs\HeadCleaningViewVM.cs" />
- <Compile Include="GuideBase.cs" />
- <Compile Include="GuideStep.cs" />
- <Compile Include="Guides\LoadInkCartridgeGuide.cs" />
- <Compile Include="Guides\ReplaceAirFilterGuide.cs" />
- <Compile Include="Guides\ReplaceThreadGuide.cs" />
- <Compile Include="Guides\HandleWasteCartridgeGuide.cs" />
- <Compile Include="Guides\LoadNewThreadGuide.cs" />
- <Compile Include="Helpers\GuideHelper.cs" />
- <Compile Include="MaintenanceCommand.cs" />
- <Compile Include="MaintenanceModule.cs" />
- <Compile Include="Models\MidTankLevelModel.cs" />
- <Compile Include="Models\OverallTemperatureModel.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\GeneralGuideViewVM.cs" />
- <Compile Include="ViewModels\MaintenanceViewVM.cs" />
- <Compile Include="ViewModels\MainViewVM.cs" />
- <Compile Include="Views\GeneralGuideView.xaml.cs">
- <DependentUpon>GeneralGuideView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\MaintenanceView.xaml.cs">
- <DependentUpon>MaintenanceView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\MainView.xaml.cs">
- <DependentUpon>MainView.xaml</DependentUpon>
- </Compile>
- <EmbeddedResource Include="Properties\Resources.resx">
- <Generator>ResXFileCodeGenerator</Generator>
- <LastGenOutput>Resources.Designer.cs</LastGenOutput>
- </EmbeddedResource>
- <None Include="app.config">
- <SubType>Designer</SubType>
- </None>
- <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.Integration\Tango.Integration.csproj">
- <Project>{4206ac58-3b57-4699-8835-90bf6db01a61}</Project>
- <Name>Tango.Integration</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\maintenance.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\action.png" />
- <Resource Include="Images\guides.png" />
- <Resource Include="Images\status.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\temperature-green.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\inks.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\loading-new-thread.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\machine-image.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\handling-the-waste-cartridges.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\loading-an-ink-cartridge.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\replacing-the-air-filter.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\replacing-the-thread.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\Loading-an-Ink-Cartridge.gif" />
- <Resource Include="Images\Guides\Residue-Cartridges-A.gif" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\Replacing-the-Air-Filter.gif" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Guides\Loading-New-Thread.gif" />
- <Resource Include="Images\Guides\Replacing-the-Thread.gif" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\temperature-red.png" />
- <Resource Include="Images\temperature-yellow.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\lubricant2.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\cl-full.png" />
- <Resource Include="Images\l-full.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\head_cleaning.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\cone-empty.png" />
- <Resource Include="Images\cone-full.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Waste\present_empty_error.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Waste\absent.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\Waste\present_empty_right.png" />
- <Resource Include="Images\Waste\present_full_right.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\thread_loading.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.Maintenance/Themes/Generic.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Themes/Generic.xaml
deleted file mode 100644
index a77cc2281..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Themes/Generic.xaml
+++ /dev/null
@@ -1,9 +0,0 @@
-<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:local="clr-namespace:Tango.PPC.Maintenance.Controls">
-
- <Style TargetType="{x:Type local:StateTouchButton}" BasedOn="{StaticResource {x:Type touch:TouchButton}}">
-
- </Style>
-</ResourceDictionary> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModelLocator.cs
deleted file mode 100644
index 1db63a9e4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModelLocator.cs
+++ /dev/null
@@ -1,56 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core.DI;
-using Tango.PPC.Maintenance.ViewModels;
-
-namespace Tango.PPC.Maintenance
-{
- public static class ViewModelLocator
- {
- /// <summary>
- /// Initializes a new instance of the ViewModelLocator class.
- /// </summary>
- static ViewModelLocator()
- {
- TangoIOC.Default.Register<MainViewVM>();
- TangoIOC.Default.Register<MaintenanceViewVM>();
- TangoIOC.Default.Register<GeneralGuideViewVM>();
- }
-
- /// <summary>
- /// Gets the main view VM.
- /// </summary>
- public static MainViewVM MainViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<MainViewVM>();
- }
- }
-
- /// <summary>
- /// Gets the maintenance view VM.
- /// </summary>
- public static MaintenanceViewVM MaintenanceViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<MaintenanceViewVM>();
- }
- }
-
- /// <summary>
- /// Gets the general guide view VM.
- /// </summary>
- public static GeneralGuideViewVM GeneralGuideViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<GeneralGuideViewVM>();
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/GeneralGuideViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/GeneralGuideViewVM.cs
deleted file mode 100644
index fd0475817..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/GeneralGuideViewVM.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common;
-using Tango.PPC.Common.Navigation;
-
-namespace Tango.PPC.Maintenance.ViewModels
-{
- public class GeneralGuideViewVM : PPCViewModel, INavigationObjectReceiver<GuideBase>
- {
- private DateTime _lastTime;
-
- private GuideBase _guide;
- public GuideBase Guide
- {
- get { return _guide; }
- set { _guide = value; RaisePropertyChangedAuto(); }
- }
-
-
- public override void OnApplicationStarted()
- {
- _lastTime = DateTime.Now;
- }
-
- public void OnNavigatedToWithObject(GuideBase guide)
- {
- if (Guide != guide || (DateTime.Now - _lastTime) > TimeSpan.FromHours(1))
- {
- guide.Steps.ForEach(x => x.IsChecked = false);
- }
-
- Guide = guide;
-
- _lastTime = DateTime.Now;
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MainViewVM.cs
deleted file mode 100644
index a614f7be2..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MainViewVM.cs
+++ /dev/null
@@ -1,31 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.PPC.Common;
-using Tango.PPC.Maintenance.Views;
-
-namespace Tango.PPC.Maintenance.ViewModels
-{
- /// <summary>
- /// Represents the main view VM and entry point for <see cref="Synchronization.MyModule"/>.
- /// </summary>
- /// <seealso cref="Tango.PPC.Common.PPCViewModel" />
- public class MainViewVM : PPCViewModel
- {
- /// <summary>
- /// Called when the application has been started
- /// </summary>
- public override void OnApplicationStarted()
- {
- //Start initializing here rather then in the constructor.
- }
-
- public override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
- NavigationManager.NavigateTo<MaintenanceModule>(nameof(MaintenanceView), false);
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs
deleted file mode 100644
index c0dc61150..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs
+++ /dev/null
@@ -1,324 +0,0 @@
-using Ionic.Zip;
-using System;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Data.Entity;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.BL;
-using Tango.Core;
-using Tango.Core.Commands;
-using Tango.Explorer;
-using Tango.Integration.Operation;
-using Tango.Logging;
-using Tango.PMR.Diagnostics;
-using Tango.PMR.IFS;
-using Tango.PMR.MachineStatus;
-using Tango.PPC.Common;
-using Tango.PPC.Maintenance.Commands;
-using Tango.PPC.Maintenance.Dialogs;
-using Tango.PPC.Maintenance.Helpers;
-using Tango.PPC.Maintenance.Models;
-using Tango.PPC.Maintenance.Views;
-using Tango.PPC.Storage;
-
-namespace Tango.PPC.Maintenance.ViewModels
-{
- public class MaintenanceViewVM : PPCViewModel
- {
- public class WasteStateModel : ExtendedObject
- {
- private CartridgeState _state;
- public CartridgeState State
- {
- get { return _state; }
- set { _state = value; RaisePropertyChangedAuto(); }
- }
-
- public CartridgeSlot Slot { get; set; }
- }
-
- public ObservableCollection<GuideBase> Guides { get; set; }
-
- public RelayCommand<GuideBase> OpenGuideCommand { get; set; }
-
- private List<MidTankLevelModel> _midTankLevels;
- public List<MidTankLevelModel> MidTankLevels
- {
- get { return _midTankLevels; }
- set { _midTankLevels = value; RaisePropertyChangedAuto(); }
- }
-
- private OverallTemperatureModel _overallTemperature;
- public OverallTemperatureModel OverallTemperature
- {
- get { return _overallTemperature; }
- set { _overallTemperature = value; RaisePropertyChangedAuto(); }
- }
-
- private String _totalDyeTime;
- public String TotalDyeTime
- {
- get { return _totalDyeTime; }
- set { _totalDyeTime = value; RaisePropertyChangedAuto(); }
- }
-
- private String _totalDyeMeters;
- public String TotalDyeMeters
- {
- get { return _totalDyeMeters; }
- set { _totalDyeMeters = value; RaisePropertyChangedAuto(); }
- }
-
- private SpoolState _spoolState;
- public SpoolState SpoolState
- {
- get { return _spoolState; }
- set
- {
- if (_spoolState != value)
- {
- _spoolState = value;
- RaisePropertyChangedAuto();
- }
- }
- }
-
- private List<WasteStateModel> _wasteStates;
- public List<WasteStateModel> WasteStates
- {
- get { return _wasteStates; }
- set { _wasteStates = value; RaisePropertyChangedAuto(); }
- }
-
- public RelayCommand ExportLogsCommand { get; set; }
-
- public OpenCloseDyeingHeadCommand OpenCloseDyeingHeadCommand { get; set; }
-
- public OpenCloseLeftLeadingWheelsCommand OpenCloseLeftLeadingWheelsCommand { get; set; }
-
- public OpenCloseRightLeadingWheelsCommand OpenCloseRightLeadingWheelsCommand { get; set; }
-
- public ResetThreadLoadingCommand ResetThreadLoadingCommand { get; set; }
-
- public RelayCommand HeadCleaningCommand { get; set; }
-
- public RelayCommand StartThreadLoadingCommand { get; set; }
-
- public RelayCommand StartThreadBreakCommand { get; set; }
-
- public RelayCommand DispenseCleanerLiquidCommand { get; set; }
-
- public MaintenanceViewVM()
- {
- Guides = new ObservableCollection<GuideBase>(GuideHelper.CreateAllGuides());
- OverallTemperature = new OverallTemperatureModel();
-
- OpenGuideCommand = new RelayCommand<GuideBase>(OpenGuide);
- ExportLogsCommand = new RelayCommand(ExportLogsToStorage);
-
- OpenCloseDyeingHeadCommand = new OpenCloseDyeingHeadCommand();
- OpenCloseLeftLeadingWheelsCommand = new OpenCloseLeftLeadingWheelsCommand();
- OpenCloseRightLeadingWheelsCommand = new OpenCloseRightLeadingWheelsCommand();
- ResetThreadLoadingCommand = new ResetThreadLoadingCommand();
- HeadCleaningCommand = new RelayCommand(PerformHeadCleaning, () => MachineProvider.MachineOperator.CanPrint);
- StartThreadLoadingCommand = new RelayCommand(StartThreadLoadingWizard, () => MachineProvider.MachineOperator.CanPrint);
- StartThreadBreakCommand = new RelayCommand(StartThreadBreakWizard, () => MachineProvider.MachineOperator.CanPrint);
-
- WasteStates = new List<WasteStateModel>()
- {
- new WasteStateModel() { Slot = CartridgeSlot.WasteMiddle, State = CartridgeState.Absent },
- new WasteStateModel() { Slot = CartridgeSlot.WasteLower, State = CartridgeState.Absent }
- };
- }
-
- public override void OnApplicationStarted()
- {
- MachineProvider.MachineOperator.InkFillingStatusChanged += MachineOperator_InkFillingStatusChanged;
- MachineProvider.MachineOperator.MachineStatusChanged += MachineOperator_MachineStatusChanged;
- MachineProvider.MachineOperator.MachineEventsStateProvider.EventsChanged += MachineEventsStateProvider_EventsChanged;
-
- DispenseCleanerLiquidCommand = new RelayCommand(DispenseCleanerLiquid, () =>
- {
- if (MachineProvider.Machine.MachineHeadType == BL.Enumerations.HeadTypes.Arc)
- {
- return MachineProvider.MachineOperator.MachineEventsStateProvider.Events.Any(x => x.Type == BL.Enumerations.EventTypes.DYEING_HEAD_ARC_LID_IS_OPEN);
- }
- else
- {
- return MachineProvider.MachineOperator.MachineEventsStateProvider.Events.Any(x => x.Type == BL.Enumerations.EventTypes.DYEING_HEAD_COVER_IS_OPEN);
- }
- });
-
- RaisePropertyChanged(nameof(DispenseCleanerLiquidCommand));
- }
-
- public override void OnApplicationReady()
- {
- base.OnApplicationReady();
-
- MidTankLevels = MachineProvider.Machine.Configuration.NoneEmptyIdsPacks.OrderBy(x => x.PackIndex).Select(x => new MidTankLevelModel()
- {
- Max = MachineOperator.MAX_MIDTANK_LITERS,
- IDSPack = x,
- }).OrderBy(y => y.IDSPack.LiquidType.Code).ToList();
- }
-
- private void MachineEventsStateProvider_EventsChanged(object sender, IEnumerable<BL.Entities.MachinesEvent> e)
- {
- OpenCloseDyeingHeadCommand.IsEnabled = !e.Any(x => x.Type == BL.Enumerations.EventTypes.DRYER_DOOR_OPEN);
-
- InvokeUI(() =>
- {
- DispenseCleanerLiquidCommand.RaiseCanExecuteChanged();
- });
- }
-
- private void MachineOperator_MachineStatusChanged(object sender, MachineStatus status)
- {
- UpdateMidTankLevels(status);
- OverallTemperature.Temperature = status.OverallTemperature;
- SpoolState = status.SpoolState;
- InvalidateRelayCommands();
- }
-
- private void MachineOperator_InkFillingStatusChanged(object sender, InkFillingStatusChangedEventArgs e)
- {
- foreach (var cartridge in e.Status.CartridgesStatuses.Where(x => x.Cartridge.Slot != CartridgeSlot.Ink))
- {
- var wasteState = WasteStates.SingleOrDefault(x => x.Slot == cartridge.Cartridge.Slot);
-
- if (wasteState != null)
- {
- wasteState.State = cartridge.State;
- }
- }
- }
-
- public async void OpenGuide(GuideBase guide)
- {
- await NavigationManager.NavigateWithObject<MaintenanceModule, GeneralGuideView, GuideBase>(guide);
- }
-
- private void UpdateMidTankLevels(MachineStatus status)
- {
- if (IsVisible)
- {
- foreach (var item in status.IDSPacksLevels)
- {
- var model = MidTankLevels.SingleOrDefault(x => x.IDSPack.PackIndex == item.Index);
-
- if (model != null)
- {
- model.Level = item.MidTankLevel;
- }
- }
- }
- }
-
- private async void ExportLogsToStorage()
- {
- var result = await NavigationManager.
- NavigateForResult<StorageModule,
- Storage.Views.MainView, ExplorerFileItem,
- Storage.Models.StorageNavigationRequest>(
- new Storage.Models.StorageNavigationRequest()
- {
- Intent = Storage.Models.StorageNavigationIntent.SaveFile,
- DefaultFileName = $"Tango-Logs-{DateTime.Now.ToFileName()}",
- Filter = "do not display anything",
- Title = "Export System Logs",
- });
-
- if (result != null)
- {
- String file = result.Path + ".zip";
-
- IsFree = false;
-
- try
- {
- NotificationProvider.SetGlobalBusyMessage("Exporting system logs...");
-
- var appFileLogger = LogManager.RegisteredLoggers.FirstOrDefault(x => x is FileLogger) as FileLogger;
-
- await Task.Factory.StartNew(() =>
- {
- using (ZipFile zip = new ZipFile(file))
- {
- zip.Password = "1Creativity";
-
- if (appFileLogger != null)
- {
- zip.AddDirectory(appFileLogger.Folder);
- }
-
- zip.ParallelDeflateThreshold = -1;
- zip.Save();
- }
- });
-
- NotificationProvider.ReleaseGlobalBusyMessage();
-
- await NotificationProvider.ShowSuccess("System logs exported successfully.");
- }
- catch (Exception ex)
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, "Error exporting system logs.");
- await NotificationProvider.ShowError($"An error occurred while trying to export the system logs.\n{ex.FlattenMessage()}");
- }
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- IsFree = true;
- }
- }
- }
-
- public async override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
-
- try
- {
- using (ObservablesContext db = ObservablesContext.CreateDefault())
- {
- var jobRuns = await db.JobRuns.Select(x => new { x.StartDate, x.EndDate, x.EndPosition }).ToListAsync();
-
- TotalDyeTime = TimeSpan.FromHours(jobRuns.Select(x => x.EndDate - x.StartDate).Sum(x => x.TotalHours)).ToStringUnlimitedHours();
-
- int meters = (int)jobRuns.Select(x => x.EndPosition).Sum();
- TotalDyeMeters = $"{meters.ToString("N0")} meters";
- }
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error loading machine counters.");
- TotalDyeTime = "error!";
- TotalDyeMeters = "error!";
- }
- }
-
- private async void PerformHeadCleaning()
- {
- await NotificationProvider.ShowDialog<HeadCleaningViewVM>();
- }
-
- private void StartThreadLoadingWizard()
- {
- ThreadLoadingService.StartThreadLoadingWizard();
- }
-
- private void StartThreadBreakWizard()
- {
- ThreadLoadingService.StartThreadBreakWizard();
- }
-
- private async void DispenseCleanerLiquid()
- {
- await NotificationProvider.ShowDialog<CleanerDispensingViewVM>();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml
deleted file mode 100644
index ecff03b58..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml
+++ /dev/null
@@ -1,55 +0,0 @@
-<UserControl x:Class="Tango.PPC.Maintenance.Views.GeneralGuideView"
- 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:local="clr-namespace:Tango.PPC.Maintenance.Views"
- xmlns:vm="clr-namespace:Tango.PPC.Maintenance.ViewModels"
- xmlns:global="clr-namespace:Tango.PPC.Maintenance"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:GeneralGuideViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.GeneralGuideViewVM}">
- <Grid>
- <Grid Background="{StaticResource TangoMidBackgroundBrush}">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
-
- <StackPanel Orientation="Horizontal" Margin="20">
- <Image Source="{Binding Guide.Icon}" Stretch="None" VerticalAlignment="Center" />
- <TextBlock Margin="20 0 0 0" VerticalAlignment="Center" FontSize="23" Text="{Binding Guide.Name}"></TextBlock>
- </StackPanel>
-
- <Grid Grid.Row="1" Margin="10">
- <touch:TouchDropShadowBorder Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}">
- <DockPanel>
- <ItemsControl DockPanel.Dock="Top" ItemsSource="{Binding Guide.Steps}" AlternationCount="2">
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <Border x:Name="FooBar" Padding="20 5">
- <DockPanel>
- <touch:TouchCheckBox Width="50" Padding="5 0 0 0" Height="50" DockPanel.Dock="Right" IsChecked="{Binding IsChecked,Mode=TwoWay}" />
- <TextBlock VerticalAlignment="Center" FontSize="16" HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding Text}"></TextBlock>
- </DockPanel>
- </Border>
- <DataTemplate.Triggers>
- <Trigger Property="ItemsControl.AlternationIndex" Value="0">
- <Setter Property="Background" Value="#f9f8f8" TargetName="FooBar"/>
- </Trigger>
- <Trigger Property="ItemsControl.AlternationIndex" Value="1">
- <Setter Property="Background" Value="{StaticResource TangoPrimaryBackgroundBrush}" TargetName="FooBar"/>
- </Trigger>
- </DataTemplate.Triggers>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
-
- </ItemsControl>
-
- <touch:TouchGifAnimation Margin="0 20 0 0" HorizontalAlignment="Left" VerticalAlignment="Bottom" EnableAnimation="{Binding IsVisible}" Source="{Binding Guide.Image}" Stretch="Uniform"></touch:TouchGifAnimation>
- </DockPanel>
- </touch:TouchDropShadowBorder>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml.cs
deleted file mode 100644
index 10b5337ce..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/GeneralGuideView.xaml.cs
+++ /dev/null
@@ -1,33 +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;
-
-namespace Tango.PPC.Maintenance.Views
-{
- /// <summary>
- /// Interaction logic for GeneralGuideView.xaml
- /// </summary>
- public partial class GeneralGuideView : UserControl
- {
- public GeneralGuideView()
- {
- InitializeComponent();
- }
-
- private void TouchCheckBox_Loaded(object sender, RoutedEventArgs e)
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml
deleted file mode 100644
index be6161952..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml
+++ /dev/null
@@ -1,22 +0,0 @@
-<UserControl x:Class="Tango.PPC.Maintenance.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:vm="clr-namespace:Tango.PPC.Maintenance.ViewModels"
- xmlns:global="clr-namespace:Tango.PPC.Maintenance"
- xmlns:views="clr-namespace:Tango.PPC.Maintenance.Views"
- xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:local="clr-namespace:Tango.PPC.Maintenance.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>
- <controls:NavigationControl TransitionType="Slide" TransitionDuration="00:00:0.2" KeepElementsAttached="True">
- <views:MaintenanceView/>
- <views:GeneralGuideView/>
- </controls:NavigationControl>
- </Grid>
-
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml.cs
deleted file mode 100644
index f859c9524..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MainView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Maintenance.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.Maintenance/Views/MaintenanceView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml
deleted file mode 100644
index d00b4abb2..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml
+++ /dev/null
@@ -1,341 +0,0 @@
-<UserControl x:Class="Tango.PPC.Maintenance.Views.MaintenanceView"
- 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:vm="clr-namespace:Tango.PPC.Maintenance.ViewModels"
- xmlns:global="clr-namespace:Tango.PPC.Maintenance"
- xmlns:ifs="clr-namespace:Tango.PMR.IFS;assembly=Tango.PMR"
- xmlns:arr="clr-namespace:System.Collections;assembly=mscorlib"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:localConverters="clr-namespace:Tango.PPC.Maintenance.Converters"
- xmlns:localControls="clr-namespace:Tango.PPC.Maintenance.Controls"
- xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL"
- xmlns:local="clr-namespace:Tango.PPC.Maintenance.Views"
- mc:Ignorable="d"
- d:DesignHeight="1800" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MaintenanceViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MaintenanceViewVM}">
-
- <UserControl.Resources>
-
- <localConverters:StringToFirstLetterConverter x:Key="StringToFirstLetterConverter" />
- <localConverters:MidTankLevelToElementHeightConverter x:Key="MidTankLevelToElementHeightConverter" />
- <localConverters:LiquidTypeToBrushConverter x:Key="LiquidTypeToBrushConverter" />
- <localConverters:LiquidTypeToShortNameConverter x:Key="LiquidTypeToShortNameConverter"/>
-
- <Style TargetType="FrameworkElement" x:Key="Level1Container">
- <Setter Property="Margin" Value="20 15 60 15"></Setter>
- </Style>
- <Style TargetType="FrameworkElement" x:Key="Level2Container">
- <Setter Property="Margin" Value="80 30 60 0"></Setter>
- </Style>
- <Style TargetType="FrameworkElement" x:Key="Level2ContainerExtraMargin">
- <Setter Property="Margin" Value="80 40 60 0"></Setter>
- </Style>
-
- <DataTemplate x:Key="LiquidBox">
- <DockPanel>
- <TextBlock DockPanel.Dock="Top" Text="{Binding IDSPack.LiquidType,Converter={StaticResource LiquidTypeToShortNameConverter}}" HorizontalAlignment="Center"></TextBlock>
- <Grid MaxWidth="20" Margin="1 0">
- <touch:TouchIcon Icon="MapMarkerSolid" Width="20" Height="20" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0 0 0 10" Foreground ="{Binding Path=IDSPack.LiquidType, Converter={StaticResource LiquidTypeToBrushConverter}}">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Visibility" Value="Hidden"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsLow}" Value="True">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsEmpty}" Value="True">
- <DataTrigger.EnterActions>
- <BeginStoryboard Name="blinkDrop">
- <Storyboard>
- <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Duration="00:00:01" RepeatBehavior="Forever">
- <DiscreteDoubleKeyFrame KeyTime="00:00:00" Value="1" />
- <DiscreteDoubleKeyFrame KeyTime="00:00:0.5" Value="0" />
- </DoubleAnimationUsingKeyFrames>
- </Storyboard>
- </BeginStoryboard>
- </DataTrigger.EnterActions>
- <DataTrigger.ExitActions>
- <RemoveStoryboard BeginStoryboardName="blinkDrop" />
- </DataTrigger.ExitActions>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- <Border BorderThickness="1" BorderBrush="{StaticResource TangoLightBorderBrush}" CornerRadius="3" ClipToBounds="True" x:Name="pathBorder">
- <Canvas Width="30" >
- <Path Panel.ZIndex="1" VerticalAlignment="Bottom" ClipToBounds="True" MinHeight="2" Data="M0,0 C2,0 8.9,-1.1705073 11.3,-4.6 14.5,-7.7 15.5,-8 18.7,-10.8 21.7,-13.16 23.3,-14.5 28,-15.6 28,-13.7 28,80 28,100 L0,100 z" Height="90" Width="29" Stretch="Fill"
- Canvas.Left="0" Fill="{Binding Path=IDSPack.LiquidType, Converter={StaticResource LiquidTypeToBrushConverter}}" Margin="0 -14 0 0" >
-
- <Path.Style>
- <Style>
- <Setter Property="Canvas.Top" >
- <Setter.Value>
- <MultiBinding Converter="{StaticResource MidTankLevelToElementHeightConverter}">
- <Binding ElementName="pathBorder" Path="ActualHeight" />
- <Binding Path="Level" />
- </MultiBinding>
- </Setter.Value>
- </Setter>
- </Style>
- </Path.Style>
- </Path>
- </Canvas>
- </Border>
- </Grid>
- </DockPanel>
- </DataTemplate>
- </UserControl.Resources>
-
- <Grid Background="{StaticResource TangoMidBackgroundBrush}" IsEnabled="{Binding IsFree}">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
-
- <Border Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
- <Border.Effect>
- <DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
- </Border.Effect>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Maintenance</TextBlock>
- </Border>
-
- <Grid Grid.Row="1">
- <touch:LightTouchScrollViewer>
- <StackPanel Margin="10 60 10 0">
-
- <!--STATUS-->
- <touch:TouchDropShadowBorder Padding="0 0 0 50">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
- <Image Source="../Images/status.png" />
- <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Current Status</TextBlock>
- </StackPanel>
-
- <StackPanel Margin="20 40 40 0">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="180" />
- <ColumnDefinition Width="1*" />
- <ColumnDefinition Width="180" />
- <ColumnDefinition Width="100" />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="100" />
- <RowDefinition Height="28" />
- </Grid.RowDefinitions>
-
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
- <Image Stretch="None">
- <Image.Style>
- <Style TargetType="Image">
- <Setter Property="Source" Value="../Images/temperature-green.png"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding OverallTemperature.IsWarning}" Value="True">
- <Setter Property="Source" Value="../Images/temperature-yellow.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding OverallTemperature.IsError}" Value="True">
- <Setter Property="Source" Value="../Images/temperature-red.png"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Image.Style>
- </Image>
- <TextBlock Margin="5 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">
- <Run Text="{Binding OverallTemperature.Temperature,StringFormat='0',Mode=OneWay}"></Run>
- <Run>º</Run>
- </TextBlock>
- </StackPanel>
-
- <Grid Grid.Column="1" Margin="0 0 0 10">
- <ItemsControl ItemsSource="{Binding MidTankLevels}" ItemTemplate="{StaticResource LiquidBox}">
- <ItemsControl.ItemsPanel>
- <ItemsPanelTemplate>
- <UniformGrid Rows="1" IsItemsHost="True"></UniformGrid>
- </ItemsPanelTemplate>
- </ItemsControl.ItemsPanel>
- </ItemsControl>
- </Grid>
-
- <Image Grid.Column="2" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="15" RenderOptions.BitmapScalingMode="Fant">
- <Image.Style>
- <Style TargetType="Image">
- <Setter Property="Source" Value="../Images/cone-empty.png"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding SpoolState}" Value="Present">
- <Setter Property="Source" Value="../Images/cone-full.png"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Image.Style>
- </Image>
-
- <Grid Grid.Column="3">
- <ItemsControl ItemsSource="{Binding WasteStates}">
- <ItemsControl.ItemsPanel>
- <ItemsPanelTemplate>
- <UniformGrid Columns="2" />
- </ItemsPanelTemplate>
- </ItemsControl.ItemsPanel>
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <Image Stretch="None" HorizontalAlignment="Right">
- <Image.Style>
- <Style TargetType="Image">
- <Setter Property="Source" Value="../Images/Waste/absent.png"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Absent}">
- <Setter Property="Source" Value="../Images/Waste/absent.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Present}">
- <Setter Property="Source" Value="../Images/Waste/present_empty_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Empty}">
- <Setter Property="Source" Value="../Images/Waste/present_empty_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Full}">
- <Setter Property="Source" Value="../Images/Waste/present_full_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Emptying}">
- <Setter Property="Source" Value="../Images/Waste/present_full_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Inserted}">
- <Setter Property="Source" Value="../Images/Waste/present_empty_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.EmptyingCompleted}">
- <Setter Property="Source" Value="../Images/Waste/present_empty_right.png"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="{x:Static ifs:CartridgeState.Error}">
- <Setter Property="Source" Value="../Images/Waste/present_empty_error.png"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Image.Style>
- </Image>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
- </Grid>
-
- <TextBlock Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Temperature</TextBlock>
- <TextBlock Grid.Column="1" Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Inks</TextBlock>
- <TextBlock Grid.Column="2" Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Collecting Cone</TextBlock>
- <TextBlock Margin="20 0 0 0" Grid.Column="3" Grid.Row="1" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Waste</TextBlock>
- </Grid>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <!--ACTIONS-->
- <touch:TouchDropShadowBorder Margin="0 20 0 0" Padding="0 0 0 50" MinHeight="330">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
- <Image Source="../Images/action.png" />
- <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Actions</TextBlock>
- </StackPanel>
-
- <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
- <UniformGrid Columns="2" Margin="0 0">
-
- <localControls:StateTouchButton Command="{Binding OpenCloseLeftLeadingWheelsCommand.Command}" SelectedState="{Binding OpenCloseLeftLeadingWheelsCommand.State}" Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}">
- <localControls:ButtonState Value="Closed" Content="OPEN LEFT LEADING WHEELS" />
- <localControls:ButtonState Value="Opened" Content="CLOSE LEFT LEADING WHEELS" />
- </localControls:StateTouchButton>
-
- <localControls:StateTouchButton Command="{Binding OpenCloseRightLeadingWheelsCommand.Command}" SelectedState="{Binding OpenCloseRightLeadingWheelsCommand.State}" Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}">
- <localControls:ButtonState Value="Closed" Content="OPEN RIGHT LEADING WHEELS" />
- <localControls:ButtonState Value="Opened" Content="CLOSE RIGHT LEADING WHEELS" />
- </localControls:StateTouchButton>
-
- <localControls:StateTouchButton Command="{Binding OpenCloseDyeingHeadCommand.Command}" SelectedState="{Binding OpenCloseDyeingHeadCommand.State}" Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Visibility="{Binding MachineProvider.Machine.MachineHeadType,Converter={StaticResource IsToStringEqualToVisibilityConverter},ConverterParameter='Flat'}">
- <localControls:ButtonState Value="Closed" Content="OPEN DYEING HEAD LID" />
- <localControls:ButtonState Value="Opened" Content="CLOSE DYEING HEAD LID" />
- </localControls:StateTouchButton>
-
- <touch:TouchButton Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding HeadCleaningCommand}">RUN HEAD CLEANING</touch:TouchButton>
-
- <touch:TouchButton Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding DispenseCleanerLiquidCommand}">DISPENSE CLEANING LIQUID</touch:TouchButton>
-
- <touch:TouchButton Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding ExportLogsCommand}" Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}">EXPORT SYSTEM LOGS</touch:TouchButton>
- </UniformGrid>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <!--THREAD LOADING-->
- <touch:TouchDropShadowBorder Margin="0 20 0 0" Padding="0 0 0 50" MinHeight="330">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
- <Image Source="../Images/thread_loading.png" Width="48" RenderOptions.BitmapScalingMode="Fant" />
- <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Thread Loading</TextBlock>
- </StackPanel>
-
- <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
- <UniformGrid Columns="1" Margin="0 0" HorizontalAlignment="Left">
- <StackPanel Margin="20">
- <touch:TouchButton Width="280" HorizontalAlignment="Left" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding StartThreadBreakCommand}">THREAD BREAK WIZARD</touch:TouchButton>
- <DockPanel Margin="15 10 0 0" TextElement.Foreground="{StaticResource TangoGrayTextBrush}" HorizontalAlignment="Left">
- <touch:TouchIcon Icon="InformationOutline" Width="14" Height="18" VerticalAlignment="Center" />
- <TextBlock Margin="5 0 0 0" FontSize="{StaticResource TangoSmallFontSize}">This wizard will help you resolve thread breaking issues</TextBlock>
- </DockPanel>
- </StackPanel>
-
- <StackPanel Margin="20">
- <touch:TouchButton Width="280" HorizontalAlignment="Left" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding StartThreadLoadingCommand}">THREAD LOADING WIZARD</touch:TouchButton>
- <DockPanel Margin="15 10 0 0" TextElement.Foreground="{StaticResource TangoGrayTextBrush}" HorizontalAlignment="Left">
- <touch:TouchIcon Icon="InformationOutline" Width="14" Height="18" VerticalAlignment="Center" />
- <TextBlock Margin="5 0 0 0" FontSize="{StaticResource TangoSmallFontSize}">This wizard will help you load a new thread in to the system</TextBlock>
- </DockPanel>
- </StackPanel>
-
- <touch:TouchButton Width="280" HorizontalAlignment="Left" Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding ResetThreadLoadingCommand.Command}">RESET THREAD LOADING</touch:TouchButton>
- </UniformGrid>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <!--GUIDES-->
- <touch:TouchDropShadowBorder Margin="0 20 0 0" Padding="0 0 0 50">
- <StackPanel>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
- <Image Source="../Images/guides.png" />
- <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Guides</TextBlock>
- </StackPanel>
-
- <StackPanel Margin="65 10 0 0">
- <ItemsControl ItemsSource="{Binding Guides}">
- <ItemsControl.ItemsPanel>
- <ItemsPanelTemplate>
- <UniformGrid Columns="2" IsItemsHost="True" />
- </ItemsPanelTemplate>
- </ItemsControl.ItemsPanel>
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <touch:TouchButton Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.OpenGuideCommand}" CommandParameter="{Binding}" Padding="20" FontSize="{StaticResource TangoTitleFontSize}" Style="{StaticResource TangoLinkButton}" HorizontalAlignment="Left">
- <TextBlock Text="{Binding Name}"></TextBlock>
- </touch:TouchButton>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
- </StackPanel>
- </StackPanel>
- </touch:TouchDropShadowBorder>
-
- <!--JOB RUNS-->
- <StackPanel Margin="0 20 0 20" TextElement.FontSize="{StaticResource TangoTitleFontSize}" TextElement.Foreground="{StaticResource TangoGrayTextBrush}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
- <TextBlock FontWeight="SemiBold">Total Dyeing Time:</TextBlock>
- <TextBlock Margin="10 0 0 0" Text="{Binding TotalDyeTime,Mode=OneWay,FallbackValue=0}"></TextBlock>
- </StackPanel>
-
- <StackPanel Orientation="Horizontal" Margin="0 10 0 0" HorizontalAlignment="Center">
- <TextBlock FontWeight="SemiBold">Total Dyed Length:</TextBlock>
- <TextBlock Margin="10 0 0 0" Text="{Binding TotalDyeMeters,Mode=OneWay,FallbackValue=0}"></TextBlock>
- </StackPanel>
- </StackPanel>
- </StackPanel>
- </touch:LightTouchScrollViewer>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml.cs
deleted file mode 100644
index 8fb9bd7ca..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml.cs
+++ /dev/null
@@ -1,30 +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.Integration.Operation;
-using Tango.PPC.Maintenance.Models;
-
-namespace Tango.PPC.Maintenance.Views
-{
- /// <summary>
- /// Interaction logic for MainView.xaml
- /// </summary>
- public partial class MaintenanceView : UserControl
- {
- public MaintenanceView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/app.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/app.config
deleted file mode 100644
index 1e22e6a88..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/app.config
+++ /dev/null
@@ -1,61 +0,0 @@
-<?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.Maintenance/packages.config b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/packages.config
deleted file mode 100644
index 468d4f366..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/packages.config
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<packages>
- <package id="EntityFramework" version="6.2.0" targetFramework="net461" />
- <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" />
- <package id="Ionic.Zip" version="1.9.1.8" targetFramework="net461" />
- <package id="System.Reactive.Core" version="3.1.1" targetFramework="net461" />
- <package id="System.Reactive.Interfaces" version="3.1.1" targetFramework="net461" />
- <package id="System.Reactive.Linq" version="3.1.1" targetFramework="net461" />
-</packages> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Models/StorageNavigationIntent.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Models/StorageNavigationIntent.cs
index 3ec14cc6f..2c2a7f10d 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Models/StorageNavigationIntent.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Models/StorageNavigationIntent.cs
@@ -9,8 +9,6 @@ namespace Tango.PPC.Storage.Models
public enum StorageNavigationIntent
{
LoadFile,
- LoadFiles,
- SaveFile,
- SaveFiles
+ SaveFile
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/StorageModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/StorageModule.cs
index 8bbeb4fe2..b3553e666 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/StorageModule.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/StorageModule.cs
@@ -15,7 +15,7 @@ namespace Tango.PPC.Storage
/// Represents a PPC <see cref="StorageModule"/>.
/// </summary>
/// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(5)]
+ [PPCModule(3)]
public class StorageModule : PPCModuleBase
{
/// <summary>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs
index 9b22fcdb5..4a756e7ea 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/ViewModels/MainViewVM.cs
@@ -1,6 +1,5 @@
using System;
using System.Collections.Generic;
-using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@@ -22,6 +21,7 @@ namespace Tango.PPC.Storage.ViewModels
{
private bool _allow_exit;
private ExplorerFileItem _selectedItem;
+ private static char[] _invalidChars = System.IO.Path.GetInvalidFileNameChars();
private String _currentPath;
public String CurrentPath
@@ -63,28 +63,15 @@ namespace Tango.PPC.Storage.ViewModels
}
}
- private bool _displayItems;
- public bool DisplayItems
- {
- get { return _displayItems; }
- set { _displayItems = value; RaisePropertyChangedAuto(); }
- }
-
public RelayCommand<ExplorerFileItem> FileSelectedCommand { get; set; }
- public ObservableCollection<ExplorerFileItem> SelectedItems { get; set; }
-
public RelayCommand SaveCommand { get; set; }
- public RelayCommand OpenCommand { get; set; }
-
public MainViewVM()
{
- SelectedItems = new ObservableCollection<ExplorerFileItem>();
FileSelectedCommand = new RelayCommand<ExplorerFileItem>(OnFileSelected);
- SaveCommand = new RelayCommand(OnSaveCommand, (x) => !String.IsNullOrWhiteSpace(FileName) || Request.Intent == StorageNavigationIntent.SaveFiles);
- Request = new StorageNavigationRequest() { Intent = StorageNavigationIntent.LoadFiles };
- OpenCommand = new RelayCommand(OnOpenCommand, () => Request.Intent == StorageNavigationIntent.LoadFiles);
+ SaveCommand = new RelayCommand(OnSaveCommand, (x) => !String.IsNullOrWhiteSpace(FileName));
+ Request = new StorageNavigationRequest();
}
public override void OnApplicationStarted()
@@ -117,8 +104,6 @@ namespace Tango.PPC.Storage.ViewModels
{
View.EditFileName();
}
-
- DisplayItems = true;
}
else
{
@@ -131,9 +116,7 @@ namespace Tango.PPC.Storage.ViewModels
public override void OnNavigatedFrom()
{
base.OnNavigatedFrom();
- DisplayItems = false;
- Request = null;
- Request = new StorageNavigationRequest() { Intent = StorageNavigationIntent.LoadFiles };
+ Request = new StorageNavigationRequest();
}
/// <summary>
@@ -175,6 +158,7 @@ namespace Tango.PPC.Storage.ViewModels
{
if (_allow_exit || CurrentPath == StorageProvider.Drive.RootDirectory.FullName)
{
+ Request = null;
return Task.FromResult(true);
}
else
@@ -186,17 +170,9 @@ namespace Tango.PPC.Storage.ViewModels
private async void OnFileSelected(ExplorerFileItem fileItem)
{
- _selectedItem = fileItem;
- _allow_exit = true;
- await NavigationManager.NavigateBack();
- StorageProvider.SubmitFileSelection(new List<ExplorerFileItem>() { fileItem });
- }
-
- private async void OnOpenCommand()
- {
_allow_exit = true;
await NavigationManager.NavigateBack();
- StorageProvider.SubmitFileSelection(SelectedItems.ToList());
+ StorageProvider.SubmitFileSelection(fileItem);
}
public ExplorerFileItem GetNavigationResult()
@@ -211,23 +187,10 @@ namespace Tango.PPC.Storage.ViewModels
private void OnSaveCommand()
{
- _allow_exit = true;
-
- if (Request.Intent == StorageNavigationIntent.SaveFile)
- {
- _selectedItem = new ExplorerFileItem()
- {
- Path = CurrentPath + "\\" + FileName,
- };
- }
- else if (Request.Intent == StorageNavigationIntent.SaveFiles)
+ _selectedItem = new ExplorerFileItem()
{
- _selectedItem = new ExplorerFileItem()
- {
- Path = CurrentPath,
- };
- }
-
+ Path = CurrentPath + "\\" + FileName,
+ };
NavigationManager.NavigateBack();
}
@@ -237,7 +200,10 @@ namespace Tango.PPC.Storage.ViewModels
if (text != null)
{
- text = text.ToValidFileName();
+ foreach (var c in _invalidChars)
+ {
+ text = text.Replace(c.ToString(), "");
+ }
_fileName = text;
RaisePropertyChanged(nameof(FileName));
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Views/MainView.xaml
index c57735a7b..74307c9ce 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Views/MainView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Storage/Views/MainView.xaml
@@ -16,7 +16,7 @@
<UserControl.InputBindings>
<KeyBinding Key="Return" Command="{Binding SaveCommand}"></KeyBinding>
</UserControl.InputBindings>
-
+
<Grid>
<Grid Background="{StaticResource TangoMidBackgroundBrush}">
<Grid.RowDefinitions>
@@ -32,89 +32,31 @@
</Border>
<Grid Margin="10" Grid.Row="1">
<DockPanel>
- <Grid DockPanel.Dock="Top">
- <Grid.Style>
- <Style TargetType="Grid">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <MultiDataTrigger>
- <MultiDataTrigger.Conditions>
- <Condition Binding="{Binding Request.Intent}" Value="LoadFiles" />
- <Condition Binding="{Binding ElementName=explorer,Path=IsMultiSelecting}" Value="True" />
- </MultiDataTrigger.Conditions>
- <Setter Property="Visibility" Value="Visible"></Setter>
- </MultiDataTrigger>
- </Style.Triggers>
- </Style>
- </Grid.Style>
- <Border BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}" Padding="20">
- <StackPanel>
- <DockPanel Margin="0 0 0 0">
- <touch:TouchButton Command="{Binding OpenCommand}" Margin="20 0 0 0" Height="55" Width="200" Style="{StaticResource TangoHollowButton}" CornerRadius="25" DockPanel.Dock="Right">
- <touch:TouchButton.Content>
- OPEN
- </touch:TouchButton.Content>
- </touch:TouchButton>
- <Grid>
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}">
- <Run Text="{Binding SelectedItems.Count,Mode=OneWay}"></Run>
- <Run>files selected</Run>
- </TextBlock>
- </Grid>
- </DockPanel>
- </StackPanel>
- </Border>
- </Grid>
-
- <Grid DockPanel.Dock="Top">
- <Grid.Style>
- <Style TargetType="Grid">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Request.Intent}" Value="SaveFile">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Request.Intent}" Value="SaveFiles">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Grid.Style>
+
+ <Grid DockPanel.Dock="Top" Visibility="{Binding Request.Intent,Converter={StaticResource EnumToVisibilityConverter},ConverterParameter=SaveFile}">
<Border BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}" Padding="20">
<StackPanel>
<TextBlock Text="{Binding Request.Title}" FontSize="{StaticResource TangoHeaderFontSize}"></TextBlock>
<DockPanel Margin="0 10 0 0">
- <touch:TouchButton Command="{Binding SaveCommand}" Margin="20 0 0 0" Height="55" Width="200" Style="{StaticResource TangoHollowButton}" CornerRadius="25" DockPanel.Dock="Right">
+ <touch:TouchButton Command="{Binding SaveCommand}" Margin="20 0 0 0" Height="50" Width="200" Style="{StaticResource TangoHollowButton}" CornerRadius="0" DockPanel.Dock="Right">
<touch:TouchButton.Content>
SAVE
</touch:TouchButton.Content>
</touch:TouchButton>
- <Grid>
- <touch:TouchTextBox x:Name="txtFileName" Visibility="{Binding Request.Intent,Converter={StaticResource EnumToVisibilityConverter},ConverterParameter=SaveFile}" KeyboardAction="Go" FocusSelectionMode="SelectAll" VerticalAlignment="Bottom" Text="{Binding FileName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
- <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Visibility="{Binding Request.Intent,Converter={StaticResource EnumToVisibilityConverter},ConverterParameter=SaveFiles}">Select destination folder</TextBlock>
- </Grid>
+ <touch:TouchTextBox x:Name="txtFileName" KeyboardAction="Go" FocusSelectionMode="SelectAll" VerticalAlignment="Bottom" Text="{Binding FileName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
</DockPanel>
</StackPanel>
</Border>
</Grid>
- <explorer:ExplorerControl x:Name="explorer" CurrentPath="{Binding CurrentPath,Mode=TwoWay}" SelectedItems="{Binding SelectedItems}" FileSelectedCommand="{Binding FileSelectedCommand}" Filter="{Binding Request.Filter}" Visibility="{Binding DisplayItems,Converter={StaticResource BooleanToVisibilityConverter}}">
+ <explorer:ExplorerControl x:Name="explorer" CurrentPath="{Binding CurrentPath,Mode=TwoWay}" FileSelectedCommand="{Binding FileSelectedCommand}" Filter="{Binding Request.Filter}">
<explorer:ExplorerControl.Style>
<Style TargetType="explorer:ExplorerControl" BasedOn="{StaticResource {x:Type explorer:ExplorerControl}}">
<Setter Property="EnableFileSelection" Value="True"></Setter>
- <Setter Property="EnableMultiSelect" Value="False"></Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding Request.Intent}" Value="SaveFile">
<Setter Property="EnableFileSelection" Value="False"></Setter>
</DataTrigger>
- <DataTrigger Binding="{Binding Request.Intent}" Value="LoadFiles">
- <Setter Property="EnableFileSelection" Value="True"></Setter>
- <Setter Property="EnableMultiSelect" Value="True"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Request.Intent}" Value="LoadFile">
- <Setter Property="EnableFileSelection" Value="True"></Setter>
- <Setter Property="EnableMultiSelect" Value="False"></Setter>
- </DataTrigger>
</Style.Triggers>
</Style>
</explorer:ExplorerControl.Style>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml
deleted file mode 100644
index 25227fc60..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml
+++ /dev/null
@@ -1,80 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Dialogs.EmbeddedLogItemDetailsView"
- 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:local="clr-namespace:Tango.PPC.Technician.Dialogs"
- xmlns:converters="clr-namespace:Tango.PPC.Technician.Converters"
- xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
- mc:Ignorable="d"
- Background="{StaticResource TangoPrimaryBackgroundBrush}" Width="560" Height="700" d:DataContext="{d:DesignInstance Type=local:EmbeddedLogItemDetailsViewVM, IsDesignTimeCreatable=False}">
-
- <UserControl.Resources>
- <converters:LogItemToStringConverter x:Key="LogItemToStringConverter" />
- </UserControl.Resources>
-
- <Grid Margin="5">
- <Grid Grid.RowSpan="2">
- <Grid.RowDefinitions>
- <RowDefinition Height="60"/>
- <RowDefinition Height="31*"/>
- <RowDefinition Height="60"/>
- </Grid.RowDefinitions>
-
- <StackPanel Orientation="Horizontal">
- <touch:TouchIcon Width="42" Height="42" VerticalAlignment="Center">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="InformationOutline"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Log.Category}" Value="Warning">
- <Setter Property="Icon" Value="ExclamationTriangleSolid"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Log.Category}" Value="Error">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Log.Category}" Value="Critical">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- <TextBlock VerticalAlignment="Center" Text="{Binding Log.Message}" TextWrapping="NoWrap" Height="22" TextTrimming="CharacterEllipsis" Width="500" Margin="10 0 0 0" FontSize="16"></TextBlock>
- </StackPanel>
-
- <Grid Grid.Row="1">
- <DockPanel>
- <Grid DockPanel.Dock="Top">
- <controls:TableGrid RowHeight="30">
- <TextBlock Text="Time Stamp:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.TimeStamp,Converter={StaticResource DateTimeUTCToStringConverter},ConverterParameter='MM/dd/yyyy HH:mm:ss.fff'}"></TextBlock>
- <TextBlock Text="Category:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.Category}"></TextBlock>
- <TextBlock Text="File:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.DebugLogResponse.FileName}"></TextBlock>
- <TextBlock Text="Line:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.DebugLogResponse.LineNumber}"></TextBlock>
- <TextBlock Text="Module:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.DebugLogResponse.ModuleId}"></TextBlock>
- <TextBlock Text="Filter:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Log.DebugLogResponse.Filter}"></TextBlock>
- </controls:TableGrid>
- </Grid>
-
- <Border Padding="5" BorderThickness="1" BorderBrush="{StaticResource TangoLightBorderBrush}">
- <TextBox BorderThickness="0" Text="{Binding Log,Converter={StaticResource LogItemToStringConverter}}" Style="{x:Null}" TextWrapping="Wrap" IsReadOnly="True" HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Hidden" Background="Transparent" />
- </Border>
- </DockPanel>
- </Grid>
-
- <Grid Grid.Row="2">
- <touch:TouchButton Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Right" Width="170" VerticalAlignment="Bottom" CornerRadius="25" Height="50" Command="{Binding CloseCommand}">CLOSE</touch:TouchButton>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml.cs
deleted file mode 100644
index 83ec6d362..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- /// <summary>
- /// Interaction logic for LogItemDetailsView.xaml
- /// </summary>
- public partial class EmbeddedLogItemDetailsView : UserControl
- {
- public EmbeddedLogItemDetailsView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsViewVM.cs
deleted file mode 100644
index 8dc745263..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/EmbeddedLogItemDetailsViewVM.cs
+++ /dev/null
@@ -1,21 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Integration.Logging;
-using Tango.Logging;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- public class EmbeddedLogItemDetailsViewVM : DialogViewVM
- {
- private EmbeddedLogItem _log;
- public EmbeddedLogItem Log
- {
- get { return _log; }
- set { _log = value; RaisePropertyChangedAuto(); }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml
deleted file mode 100644
index 37fa8b05c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml
+++ /dev/null
@@ -1,74 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Dialogs.SynchronizationDetailsView"
- 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:local="clr-namespace:Tango.PPC.Technician.Dialogs"
- xmlns:converters="clr-namespace:Tango.PPC.Technician.Converters"
- xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
- mc:Ignorable="d"
- Background="{StaticResource TangoPrimaryBackgroundBrush}" Width="560" Height="700" d:DataContext="{d:DesignInstance Type=local:SynchronizationDetailsViewVM, IsDesignTimeCreatable=False}">
-
- <Grid Margin="5">
- <Grid Grid.RowSpan="2">
- <Grid.RowDefinitions>
- <RowDefinition Height="60"/>
- <RowDefinition Height="31*"/>
- <RowDefinition Height="60"/>
- </Grid.RowDefinitions>
-
- <StackPanel Orientation="Horizontal" DataContext="{Binding Status}">
- <touch:TouchIcon Width="42" Height="42" VerticalAlignment="Center">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Information"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding State}" Value="Pending">
- <Setter Property="Icon" Value="Pause"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoGrayBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Synchronizing">
- <Setter Property="Icon" Value="CloudSync"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Failed">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Completed">
- <Setter Property="Icon" Value="Check"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoGreenBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- <TextBlock VerticalAlignment="Center" Text="{Binding Message}" TextWrapping="NoWrap" Height="22" TextTrimming="CharacterEllipsis" Width="500" Margin="10 0 0 0" FontSize="16"></TextBlock>
- </StackPanel>
-
- <Grid Grid.Row="1">
- <DockPanel>
- <Grid DockPanel.Dock="Top">
- <controls:TableGrid RowHeight="30">
- <TextBlock Text="Status:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Status.State,Converter={StaticResource EnumToDescriptionConverter}}"></TextBlock>
- <TextBlock Text="Start Time:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Status.StartDateTime,Converter={StaticResource DateTimeUTCToStringConverter},ConverterParameter='MM/dd/yyyy HH:mm:ss'}"></TextBlock>
- <TextBlock Text="Duration:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Status.Duration,StringFormat='hh\\:mm\\:ss\\.fff'}"></TextBlock>
- </controls:TableGrid>
- </Grid>
-
- <Border Padding="5" BorderThickness="1" BorderBrush="{StaticResource TangoLightBorderBrush}">
- <TextBox BorderThickness="0" Text="{Binding Status.ErrorReason,TargetNullValue='No further Information available.'}" Style="{x:Null}" TextWrapping="Wrap" IsReadOnly="True" HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Hidden" Background="Transparent" />
- </Border>
- </DockPanel>
- </Grid>
-
- <Grid Grid.Row="2">
- <touch:TouchButton Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Right" Width="170" VerticalAlignment="Bottom" CornerRadius="25" Height="50" Command="{Binding CloseCommand}">CLOSE</touch:TouchButton>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml.cs
deleted file mode 100644
index 40f7a536c..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- /// <summary>
- /// Interaction logic for LogItemDetailsView.xaml
- /// </summary>
- public partial class SynchronizationDetailsView : UserControl
- {
- public SynchronizationDetailsView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsViewVM.cs
deleted file mode 100644
index 392c8dd3a..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/SynchronizationDetailsViewVM.cs
+++ /dev/null
@@ -1,22 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.BL.Entities;
-using Tango.Logging;
-using Tango.PPC.Common.Synchronization;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- public class SynchronizationDetailsViewVM : DialogViewVM
- {
- private SynchronizationStatus _status;
- public SynchronizationStatus Status
- {
- get { return _status; }
- set { _status = value; RaisePropertyChangedAuto(); }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml
deleted file mode 100644
index ccf2062c1..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml
+++ /dev/null
@@ -1,87 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Dialogs.UpdateDetailsView"
- 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:local="clr-namespace:Tango.PPC.Technician.Dialogs"
- xmlns:converters="clr-namespace:Tango.PPC.Technician.Converters"
- xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
- mc:Ignorable="d"
- Background="{StaticResource TangoPrimaryBackgroundBrush}" Width="560" Height="700" d:DataContext="{d:DesignInstance Type=local:UpdateDetailsViewVM, IsDesignTimeCreatable=False}">
-
- <Grid Margin="5">
- <Grid Grid.RowSpan="2">
- <Grid.RowDefinitions>
- <RowDefinition Height="60"/>
- <RowDefinition Height="31*"/>
- <RowDefinition Height="60"/>
- </Grid.RowDefinitions>
-
- <StackPanel Orientation="Horizontal" DataContext="{Binding Update}">
- <touch:TouchIcon Width="42" Height="42" VerticalAlignment="Center">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Information"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsSetup}" Value="True">
- <Setter Property="Icon" Value="Settings"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsUpdate}" Value="True">
- <Setter Property="Icon" Value="CloudDownload"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsDataBase}" Value="True">
- <Setter Property="Icon" Value="Database"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsSynchronization}" Value="True">
- <Setter Property="Icon" Value="Sync"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsOfflineUpdate}" Value="True">
- <Setter Property="Icon" Value="Sd"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsOfflineFirmwareUpgrade}" Value="True">
- <Setter Property="Icon" Value="Chip"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsStarted}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsCompleted}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsFailed}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- <TextBlock VerticalAlignment="Center" Text="{Binding UpdateStatus,Converter={StaticResource EnumToDescriptionConverter}}" TextWrapping="NoWrap" Height="22" TextTrimming="CharacterEllipsis" Width="500" Margin="10 0 0 0" FontSize="16"></TextBlock>
- </StackPanel>
-
- <Grid Grid.Row="1">
- <DockPanel>
- <Grid DockPanel.Dock="Top">
- <controls:TableGrid RowHeight="30">
- <TextBlock Text="Started On:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Update.StartDate,Converter={StaticResource DateTimeUTCToStringConverter},ConverterParameter='MM/dd/yyyy HH:mm:ss'}"></TextBlock>
- <TextBlock Text="Application:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Update.ApplicationVersion}"></TextBlock>
- <TextBlock Text="Firmware:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Update.FirmwareVersion}"></TextBlock>
- <TextBlock Text="Ended:" FontWeight="SemiBold" />
- <TextBlock Text="{Binding Update.EndDate,TargetNullValue='Never',FallbackValue='Never',Converter={StaticResource DateTimeUTCToStringConverter},ConverterParameter='MM/dd/yyyy HH:mm:ss'}"></TextBlock>
- </controls:TableGrid>
- </Grid>
-
- <Border Padding="5" BorderThickness="1" BorderBrush="{StaticResource TangoLightBorderBrush}">
- <TextBox BorderThickness="0" Text="{Binding Update.FailedLog,TargetNullValue='No further Information available.'}" Style="{x:Null}" TextWrapping="Wrap" IsReadOnly="True" HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Hidden" Background="Transparent" />
- </Border>
- </DockPanel>
- </Grid>
-
- <Grid Grid.Row="2">
- <touch:TouchButton Style="{StaticResource TangoHollowButton}" HorizontalAlignment="Right" Width="170" VerticalAlignment="Bottom" CornerRadius="25" Height="50" Command="{Binding CloseCommand}">CLOSE</touch:TouchButton>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml.cs
deleted file mode 100644
index f2a06aedf..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- /// <summary>
- /// Interaction logic for LogItemDetailsView.xaml
- /// </summary>
- public partial class UpdateDetailsView : UserControl
- {
- public UpdateDetailsView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsViewVM.cs
deleted file mode 100644
index 36c0fc6d7..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Dialogs/UpdateDetailsViewVM.cs
+++ /dev/null
@@ -1,21 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.BL.Entities;
-using Tango.Logging;
-using Tango.SharedUI;
-
-namespace Tango.PPC.Technician.Dialogs
-{
- public class UpdateDetailsViewVM : DialogViewVM
- {
- private TangoUpdate _update;
- public TangoUpdate Update
- {
- get { return _update; }
- set { _update = value; RaisePropertyChangedAuto(); }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/browser.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/browser.png
deleted file mode 100644
index ebb975b6f..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/browser.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/circuit-board.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/circuit-board.png
deleted file mode 100644
index 28b535f54..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/circuit-board.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/conveyor.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/conveyor.png
deleted file mode 100644
index 1cd649a88..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/conveyor.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/exit.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/exit.png
deleted file mode 100644
index e05db36d4..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/exit.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/mobile-phone.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/mobile-phone.png
deleted file mode 100644
index ea4e685dc..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/mobile-phone.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/packages.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/packages.png
deleted file mode 100644
index cf0e936d8..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/packages.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/remote_connections.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/remote_connections.png
deleted file mode 100644
index d9d4a1d45..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/remote_connections.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/shutdown.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/shutdown.png
deleted file mode 100644
index abc4d1a1a..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/shutdown.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/sync.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/sync.png
deleted file mode 100644
index 46059c5c0..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Images/sync.png
+++ /dev/null
Binary files differ
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Tango.PPC.Technician.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Tango.PPC.Technician.csproj
index fc00f83d4..d135142c4 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Tango.PPC.Technician.csproj
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Tango.PPC.Technician.csproj
@@ -69,21 +69,9 @@
</Compile>
<Compile Include="Converters\LogItemMessageToOneLineConverter.cs" />
<Compile Include="Converters\LogItemToStringConverter.cs" />
- <Compile Include="Dialogs\EmbeddedLogItemDetailsView.xaml.cs">
- <DependentUpon>EmbeddedLogItemDetailsView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Dialogs\SynchronizationDetailsView.xaml.cs">
- <DependentUpon>SynchronizationDetailsView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Dialogs\UpdateDetailsView.xaml.cs">
- <DependentUpon>UpdateDetailsView.xaml</DependentUpon>
- </Compile>
<Compile Include="Dialogs\LogItemDetailsView.xaml.cs">
<DependentUpon>LogItemDetailsView.xaml</DependentUpon>
</Compile>
- <Compile Include="Dialogs\EmbeddedLogItemDetailsViewVM.cs" />
- <Compile Include="Dialogs\SynchronizationDetailsViewVM.cs" />
- <Compile Include="Dialogs\UpdateDetailsViewVM.cs" />
<Compile Include="Dialogs\LogItemDetailsViewVM.cs" />
<Compile Include="Models\DispenserController.cs" />
<Compile Include="TechnicianModule.cs" />
@@ -105,22 +93,10 @@
<Compile Include="ViewModels\DispensersViewVM.cs" />
<Compile Include="ViewModels\LoggingViewVM.cs" />
<Compile Include="ViewModels\MainViewVM.cs" />
- <Compile Include="ViewModels\PackagesViewVM.cs" />
- <Compile Include="ViewModels\RemoteConnectionsViewVM.cs" />
- <Compile Include="ViewModels\UpdatesViewVM.cs" />
<Compile Include="ViewModels\SystemViewVM.cs" />
<Compile Include="Views\CatalogView.xaml.cs">
<DependentUpon>CatalogView.xaml</DependentUpon>
</Compile>
- <Compile Include="Views\RemoteConnectionsView.xaml.cs">
- <DependentUpon>RemoteConnectionsView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\UpdatesView.xaml.cs">
- <DependentUpon>UpdatesView.xaml</DependentUpon>
- </Compile>
- <Compile Include="Views\PackagesView.xaml.cs">
- <DependentUpon>PackagesView.xaml</DependentUpon>
- </Compile>
<Compile Include="Views\DispensersView.xaml.cs">
<DependentUpon>DispensersView.xaml</DependentUpon>
</Compile>
@@ -185,10 +161,6 @@
<Project>{0BE74EEE-22CB-4DBA-B896-793B9E1A3AC0}</Project>
<Name>Tango.PPC.Common</Name>
</ProjectReference>
- <ProjectReference Include="..\..\Tango.PPC.Shared\Tango.PPC.Shared.csproj">
- <Project>{208C8BD8-72C6-4E3C-ACAA-351091A2ACC7}</Project>
- <Name>Tango.PPC.Shared</Name>
- </ProjectReference>
</ItemGroup>
<ItemGroup>
<Page Include="App.xaml">
@@ -199,18 +171,6 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
- <Page Include="Dialogs\EmbeddedLogItemDetailsView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Dialogs\SynchronizationDetailsView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Dialogs\UpdateDetailsView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
<Page Include="Dialogs\LogItemDetailsView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -219,18 +179,6 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
- <Page Include="Views\RemoteConnectionsView.xaml">
- <SubType>Designer</SubType>
- <Generator>MSBuild:Compile</Generator>
- </Page>
- <Page Include="Views\UpdatesView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
- <Page Include="Views\PackagesView.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
<Page Include="Views\DispensersView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -260,24 +208,5 @@
<ItemGroup>
<Resource Include="Images\dispensers.png" />
</ItemGroup>
- <ItemGroup>
- <Resource Include="Images\circuit-board.png" />
- <Resource Include="Images\conveyor.png" />
- <Resource Include="Images\exit.png" />
- <Resource Include="Images\mobile-phone.png" />
- <Resource Include="Images\shutdown.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\packages.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\sync.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\browser.png" />
- </ItemGroup>
- <ItemGroup>
- <Resource Include="Images\remote_connections.png" />
- </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModelLocator.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModelLocator.cs
index 9a8b63c91..ae4678e60 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModelLocator.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModelLocator.cs
@@ -20,9 +20,6 @@ namespace Tango.PPC.Technician
TangoIOC.Default.Register<CatalogViewVM>();
TangoIOC.Default.Register<DispensersViewVM>();
TangoIOC.Default.Register<SystemViewVM>();
- TangoIOC.Default.Register<PackagesViewVM>();
- TangoIOC.Default.Register<UpdatesViewVM>();
- TangoIOC.Default.Register<RemoteConnectionsViewVM>();
}
/// <summary>
@@ -79,38 +76,5 @@ namespace Tango.PPC.Technician
return TangoIOC.Default.GetInstance<SystemViewVM>();
}
}
-
- /// <summary>
- /// Gets the system view VM.
- /// </summary>
- public static PackagesViewVM PackagesViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<PackagesViewVM>();
- }
- }
-
- /// <summary>
- /// Gets the synchronization view vm.
- /// </summary>
- public static UpdatesViewVM UpdatesViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<UpdatesViewVM>();
- }
- }
-
- /// <summary>
- /// Gets the remote connections view vm.
- /// </summary>
- public static RemoteConnectionsViewVM RemoteConnectionsViewVM
- {
- get
- {
- return TangoIOC.Default.GetInstance<RemoteConnectionsViewVM>();
- }
- }
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/CatalogViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/CatalogViewVM.cs
index dbc99fa87..97bae6f5b 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/CatalogViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/CatalogViewVM.cs
@@ -4,9 +4,6 @@ using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Tango.Core.Commands;
-//using Tango.PPC.Browser;
-//using Tango.PPC.Browser.Navigation;
-//using Tango.PPC.Browser.Views;
using Tango.PPC.Common;
namespace Tango.PPC.Technician.ViewModels
@@ -19,22 +16,16 @@ namespace Tango.PPC.Technician.ViewModels
public RelayCommand<String> NavigationCommand { get; set; }
/// <summary>
- /// Gets or sets the browser command.
- /// </summary>
- public RelayCommand BrowserCommand { get; set; }
-
- /// <summary>
/// Initializes a new instance of the <see cref="CatalogViewVM"/> class.
/// </summary>
public CatalogViewVM()
{
NavigationCommand = new RelayCommand<string>(NavigateToView);
- BrowserCommand = new RelayCommand(OpenBrowserModule);
}
public override void OnApplicationStarted()
{
-
+
}
/// <summary>
@@ -45,17 +36,5 @@ namespace Tango.PPC.Technician.ViewModels
{
NavigationManager.NavigateTo<TechnicianModule>(view);
}
-
- /// <summary>
- /// Opens the browser module.
- /// </summary>
- private void OpenBrowserModule()
- {
- //NavigationManager.NavigateWithObject<BrowserModule, BrowserView, BrowserNavigationRequest>(new BrowserNavigationRequest()
- //{
- // Address = "https://twine-s.com/",
- // DisplayAddressBar = true,
- //}, true);
- }
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/LoggingViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/LoggingViewVM.cs
index 2aee7f561..6ca693af6 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/LoggingViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/LoggingViewVM.cs
@@ -8,11 +8,8 @@ using System.Threading.Tasks;
using System.Windows.Data;
using Tango.Core;
using Tango.Core.Commands;
-using Tango.Integration.Logging;
-using Tango.Integration.Operation;
using Tango.Logging;
using Tango.PPC.Common;
-using Tango.PPC.Common.Helpers;
using Tango.PPC.Technician.Dialogs;
namespace Tango.PPC.Technician.ViewModels
@@ -20,28 +17,12 @@ namespace Tango.PPC.Technician.ViewModels
public class LoggingViewVM : PPCViewModel
{
private const int MAX_LOGS = 1000;
-
private List<LogItemBase> paused_logs;
- private List<LogItemBase> paused_embedded_logs;
public SynchronizedObservableCollection<LogItemBase> ApplicationLogs { get; set; }
public SynchronizedObservableCollection<LogItemBase> EmbeddedLogs { get; set; }
- private ICollectionView _applicationLogsViewSource;
- public ICollectionView ApplicationLogsViewSource
- {
- get { return _applicationLogsViewSource; }
- set { _applicationLogsViewSource = value; RaisePropertyChangedAuto(); }
- }
-
- private ICollectionView _embeddedLogsViewSource;
- public ICollectionView EmbeddedLogsViewSource
- {
- get { return _embeddedLogsViewSource; }
- set { _embeddedLogsViewSource = value; RaisePropertyChangedAuto(); }
- }
-
private LogItemBase _selectedLog;
public LogItemBase SelectedLog
{
@@ -49,6 +30,13 @@ namespace Tango.PPC.Technician.ViewModels
set { _selectedLog = value; RaisePropertyChangedAuto(); OnSelectedLogChanged(); }
}
+ private ICollectionView _applicationLogsViewSource;
+ public ICollectionView ApplicationLogsViewSource
+ {
+ get { return _applicationLogsViewSource; }
+ set { _applicationLogsViewSource = value; RaisePropertyChangedAuto(); }
+ }
+
private String _filter;
public String Filter
{
@@ -58,7 +46,6 @@ namespace Tango.PPC.Technician.ViewModels
_filter = value;
RaisePropertyChangedAuto();
ApplicationLogsViewSource.Refresh();
- EmbeddedLogsViewSource.Refresh();
}
}
@@ -69,13 +56,6 @@ namespace Tango.PPC.Technician.ViewModels
set { _isPaused = value; RaisePropertyChangedAuto(); OnIsPausedChanged(); }
}
- private bool _processDebugLogs;
- public bool ProcessDebugLogs
- {
- get { return _processDebugLogs; }
- set { _processDebugLogs = value; RaisePropertyChangedAuto(); OnProcessDebugLogsChanged(); }
- }
-
public RelayCommand ClearCommand { get; set; }
public LoggingViewVM()
@@ -83,19 +63,8 @@ namespace Tango.PPC.Technician.ViewModels
ApplicationLogs = new SynchronizedObservableCollection<LogItemBase>();
EmbeddedLogs = new SynchronizedObservableCollection<LogItemBase>();
ApplicationLogsViewSource = CollectionViewSource.GetDefaultView(ApplicationLogs);
- EmbeddedLogsViewSource = CollectionViewSource.GetDefaultView(EmbeddedLogs);
paused_logs = new List<LogItemBase>();
- paused_embedded_logs = new List<LogItemBase>();
-
- var appStartLogs = LogsHelper.GetLogSafe().EmptyAndDispose();
-
- foreach (var log in appStartLogs)
- {
- ApplicationLogs.Insert(0, log);
- }
-
LogManager.NewLog += LogManager_NewLog;
- MachineOperator.EmbeddedLogManager.NewLog += EmbeddedLogManager_NewLog;
ClearCommand = new RelayCommand(ClearLogs);
Filter = "error";
@@ -112,31 +81,6 @@ namespace Tango.PPC.Technician.ViewModels
return false;
}
};
-
- EmbeddedLogsViewSource.Filter = (x) =>
- {
- try
- {
- LogItemBase log = x as LogItemBase;
- return String.IsNullOrWhiteSpace(Filter) || log.Category.ToString().ToLower().Contains(Filter.ToLower()) || log.Message.ToLower().Contains(Filter.ToLower());
- }
- catch
- {
- return false;
- }
- };
- }
-
- private void OnProcessDebugLogsChanged()
- {
- if (ProcessDebugLogs)
- {
- LogManager.Categories.Add(LogCategory.Debug);
- }
- else
- {
- LogManager.Categories.RemoveAll(x => x == LogCategory.Debug);
- }
}
private void OnIsPausedChanged()
@@ -147,14 +91,6 @@ namespace Tango.PPC.Technician.ViewModels
}
paused_logs.Clear();
-
-
- foreach (var log in paused_embedded_logs)
- {
- EmbeddedLogManager_NewLog(this, log);
- }
-
- paused_embedded_logs.Clear();
}
private void LogManager_NewLog(object sender, LogItemBase log)
@@ -184,59 +120,22 @@ namespace Tango.PPC.Technician.ViewModels
}
}
- private void EmbeddedLogManager_NewLog(object sender, LogItemBase log)
- {
- if (!IsPaused)
- {
- InvokeUI(() =>
- {
- EmbeddedLogs.Insert(0, log);
-
- try
- {
- if (EmbeddedLogs.Count > MAX_LOGS)
- {
- EmbeddedLogs.Remove(EmbeddedLogs.Last());
- }
- }
- catch
- {
- //I don't know if this will cause an exception but I'm tired.
- }
- });
- }
- else
- {
- paused_embedded_logs.Add(log);
- }
- }
-
private void ClearLogs()
{
ApplicationLogs.Clear();
- EmbeddedLogs.Clear();
paused_logs.Clear();
- paused_embedded_logs.Clear();
}
private async void OnSelectedLogChanged()
{
if (SelectedLog != null)
{
- if (SelectedLog.GetType() == typeof(EmbeddedLogItem))
- {
- await NotificationProvider.ShowDialog<EmbeddedLogItemDetailsViewVM>(new EmbeddedLogItemDetailsViewVM()
- {
- Log = SelectedLog as EmbeddedLogItem,
- });
- }
- else
+ await NotificationProvider.ShowDialog<LogItemDetailsViewVM>(new LogItemDetailsViewVM()
{
- await NotificationProvider.ShowDialog<LogItemDetailsViewVM>(new LogItemDetailsViewVM()
- {
- Log = SelectedLog,
- });
- }
+ Log = SelectedLog,
+ });
+
+ SelectedLog = null;
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/MainViewVM.cs
index 4f8aba952..d63a89f3b 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/MainViewVM.cs
@@ -12,13 +12,13 @@ namespace Tango.PPC.Technician.ViewModels
{
public override void OnApplicationStarted()
{
-
+
}
public override void OnNavigatedTo()
{
base.OnNavigatedTo();
- NavigationManager.NavigateTo<TechnicianModule>(nameof(CatalogView), false);
+ NavigationManager.NavigateTo<TechnicianModule>(nameof(CatalogView));
}
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/PackagesViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/PackagesViewVM.cs
deleted file mode 100644
index 1d7e1780a..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/PackagesViewVM.cs
+++ /dev/null
@@ -1,44 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.Core.DI;
-using Tango.PPC.Common;
-using Tango.PPC.Common.UpdatePackages;
-using Tango.PPC.Shared.Updates;
-
-namespace Tango.PPC.Technician.ViewModels
-{
- public class PackagesViewVM : PPCViewModel
- {
- [TangoInject(TangoInjectMode.WhenAvailable)]
- public IPackageRunner PackageRunner { get; set; }
-
- private List<PackageInstallation> _packages;
- public List<PackageInstallation> Packages
- {
- get { return _packages; }
- set { _packages = value; RaisePropertyChangedAuto(); }
- }
-
- public override void OnApplicationStarted()
- {
-
- }
-
- public async override void OnApplicationReady()
- {
- base.OnApplicationReady();
-
- try
- {
- Packages = (await PackageRunner.GetPackagesFile()).PackageInstallations;
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "An error occurred while trying to list the installed update packages.");
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/RemoteConnectionsViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/RemoteConnectionsViewVM.cs
deleted file mode 100644
index 2d8857329..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/RemoteConnectionsViewVM.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.Core.Commands;
-using Tango.Integration.ExternalBridge;
-using Tango.PPC.Common;
-
-namespace Tango.PPC.Technician.ViewModels
-{
- public class RemoteConnectionsViewVM : PPCViewModel
- {
- public RelayCommand DisconnectCommand { get; set; }
-
- private ExternalBridgeReceiver _selectedReceiver;
- public ExternalBridgeReceiver SelectedReceiver
- {
- get { return _selectedReceiver; }
- set
- {
- if (value != null)
- {
- _selectedReceiver = value;
- InvalidateRelayCommands();
- }
- }
- }
-
- public RemoteConnectionsViewVM()
- {
- DisconnectCommand = new RelayCommand(DisconnectReceiver, () => SelectedReceiver != null);
- }
-
- private async void DisconnectReceiver()
- {
- if (SelectedReceiver != null)
- {
- try
- {
- await Task.Factory.StartNew(() =>
- {
- SelectedReceiver.Disconnect().Wait();
- });
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error disconnecting the specified receiver.");
- }
- finally
- {
- _selectedReceiver = null;
- RaisePropertyChanged(nameof(SelectedReceiver));
- InvalidateRelayCommands();
- }
- }
- }
-
- public override void OnApplicationStarted()
- {
-
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/SystemViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/SystemViewVM.cs
index 452907366..444c1d09e 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/SystemViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/SystemViewVM.cs
@@ -8,20 +8,16 @@ using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;
using System.Timers;
-using Tango.BL;
using Tango.Core.Commands;
using Tango.PPC.Common;
using Tango.PPC.Common.OS;
using Tango.Settings;
-using System.Data.Entity;
-using Tango.PPC.Common.UWF;
namespace Tango.PPC.Technician.ViewModels
{
public class SystemViewVM : PPCViewModel
{
private IOperationSystemManager _os;
- private IUnifiedWriteFilterManager _uwf;
private Timer _statsTimer;
private bool _resettingDevice;
@@ -60,20 +56,6 @@ namespace Tango.PPC.Technician.ViewModels
set { _ipAddress = value; RaisePropertyChangedAuto(); }
}
- private String _totalDyeTime;
- public String TotalDyeTime
- {
- get { return _totalDyeTime; }
- set { _totalDyeTime = value; RaisePropertyChangedAuto(); }
- }
-
- private String _totalDyeMeters;
- public String TotalDyeMeters
- {
- get { return _totalDyeMeters; }
- set { _totalDyeMeters = value; RaisePropertyChangedAuto(); }
- }
-
public RelayCommand ResetDeviceCommand { get; set; }
public RelayCommand RestartCommand { get; set; }
@@ -84,10 +66,9 @@ namespace Tango.PPC.Technician.ViewModels
public RelayCommand ExitToExplorerCommand { get; set; }
- public SystemViewVM(IOperationSystemManager os, IUnifiedWriteFilterManager uwf)
+ public SystemViewVM(IOperationSystemManager os)
{
_os = os;
- _uwf = uwf;
CPU = 0;
RAM = 0;
@@ -105,7 +86,7 @@ namespace Tango.PPC.Technician.ViewModels
{
_resettingDevice = true;
ResetDeviceCommand.RaiseCanExecuteChanged();
- await MachineProvider.MachineOperator.Reset();
+ await MachineProvider.MachineOperator.ResetDFU();
await NotificationProvider.ShowInfo("Embedded device has been reset successfully.");
}
catch (Exception ex)
@@ -121,30 +102,11 @@ namespace Tango.PPC.Technician.ViewModels
private async void FactoryReset()
{
- if (await NotificationProvider.ShowQuestion("Are you sure you want to reset this device back to factory settings?"))
+ if (await NotificationProvider.ShowQuestion("Are you sure you want to reset this device and back to factory settings?"))
{
Settings.ApplicationState = ApplicationStates.FactoryRestore;
Settings.Save();
- try
- {
- NotificationProvider.SetGlobalBusyMessage("Disabling write filter protection...");
- await _uwf.Disable();
- await Task.Delay(2000);
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NavigationManager.NavigateTo(Common.Navigation.NavigationView.RestartingSystemView);
- await Task.Delay(4000);
- _os.Restart();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error executing factory reset.");
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowError($"Error executing factory reset.\n{ex.FlattenMessage()}");
- }
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- }
+ ApplicationManager.Restart();
}
}
@@ -160,8 +122,6 @@ namespace Tango.PPC.Technician.ViewModels
{
if (await NotificationProvider.ShowQuestion("Are you sure you want to restart the device?"))
{
- await NavigationManager.NavigateTo(Common.Navigation.NavigationView.RestartingSystemView);
- await Task.Delay(4000);
_os.Restart();
}
}
@@ -170,7 +130,12 @@ namespace Tango.PPC.Technician.ViewModels
{
if (await NotificationProvider.ShowQuestion("Close the application and start OS shell?"))
{
- _os.OpenShell();
+ Process.Start(new ProcessStartInfo()
+ {
+ UseShellExecute = true,
+ FileName = "explorer.exe",
+ });
+
ApplicationManager.ShutDown();
}
}
@@ -183,6 +148,12 @@ namespace Tango.PPC.Technician.ViewModels
_statsTimer.Start();
}
+ public override void OnApplicationReady()
+ {
+ base.OnApplicationReady();
+ IPAddress = GetIpv4Address();
+ }
+
private void _statsTimer_Elapsed(object sender, ElapsedEventArgs e)
{
if (IsVisible)
@@ -273,31 +244,5 @@ namespace Tango.PPC.Technician.ViewModels
return "N/A";
}
}
-
- public async override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
-
- IPAddress = GetIpv4Address();
-
- try
- {
- using (ObservablesContext db = ObservablesContext.CreateDefault())
- {
- var jobRuns = await db.JobRuns.Select(x => new { x.StartDate, x.EndDate, x.EndPosition }).ToListAsync();
-
- TotalDyeTime = TimeSpan.FromHours(jobRuns.Select(x => x.EndDate - x.StartDate).Sum(x => x.TotalHours)).ToStringUnlimitedHours();
-
- int meters = (int)jobRuns.Select(x => x.EndPosition).Sum();
- TotalDyeMeters = $"{meters.ToString("N0")} meters";
- }
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error loading machine counters.");
- TotalDyeTime = "error!";
- TotalDyeMeters = "error!";
- }
- }
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/UpdatesViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/UpdatesViewVM.cs
deleted file mode 100644
index 3f4232252..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/ViewModels/UpdatesViewVM.cs
+++ /dev/null
@@ -1,107 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using Tango.BL;
-using Tango.BL.Entities;
-using Tango.BL.Enumerations;
-using Tango.Core.Commands;
-using Tango.PPC.Common;
-using System.Data.Entity;
-using Tango.PPC.Technician.Dialogs;
-using Tango.PPC.Common.Synchronization;
-
-namespace Tango.PPC.Technician.ViewModels
-{
- public class UpdatesViewVM : PPCViewModel
- {
- public RelayCommand SynchronizeCommand { get; set; }
-
- private List<TangoUpdate> _updates;
- public List<TangoUpdate> Updates
- {
- get { return _updates; }
- set { _updates = value; RaisePropertyChangedAuto(); }
- }
-
- private TangoUpdate _selectedUpdate;
- public TangoUpdate SelectedUpdate
- {
- get { return _selectedUpdate; }
- set { _selectedUpdate = value; OnSelectedUpdateChanged(); }
- }
-
- private SynchronizationStatus _selectedSynchronization;
- public SynchronizationStatus SelectedSynchronization
- {
- get { return _selectedSynchronization; }
- set { _selectedSynchronization = value; OnSelectedSynchronizationChanged(); }
- }
-
- public UpdatesViewVM()
- {
- Updates = new List<TangoUpdate>();
- SynchronizeCommand = new RelayCommand(Synchronize, () => !MachineDataSynchronizer.IsSynchronizing);
- }
-
- public override void OnApplicationStarted()
- {
-
- }
-
- public override void OnApplicationReady()
- {
- base.OnApplicationReady();
- MachineDataSynchronizer.SynchronizationStarted += (_, __) => InvalidateRelayCommands();
- MachineDataSynchronizer.SynchronizationEnded += (_, __) => InvalidateRelayCommands();
- }
-
- private async void Synchronize()
- {
- try
- {
- await MachineDataSynchronizer.Synchronize();
- }
- catch { }
- }
-
- public async override void OnNavigatedTo()
- {
- base.OnNavigatedTo();
-
- try
- {
- using (ObservablesContext db = ObservablesContext.CreateDefault())
- {
- Updates = await db.TangoUpdates.Where(x =>
- x.Status != (int)TangoUpdateStatuses.SynchronizationCompleted &&
- x.Status != (int)TangoUpdateStatuses.SynchronizationFailed &&
- x.Status != (int)TangoUpdateStatuses.SynchronizationStarted
- ).OrderByDescending(x => x.StartDate).ToListAsync();
- }
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error loading update history.");
- }
- }
-
- private async void OnSelectedUpdateChanged()
- {
- if (SelectedUpdate != null)
- {
- await NotificationProvider.ShowDialog<UpdateDetailsViewVM>(new UpdateDetailsViewVM() { Update = SelectedUpdate });
- }
- }
-
- private async void OnSelectedSynchronizationChanged()
- {
- if (SelectedSynchronization != null)
- {
- await NotificationProvider.ShowDialog<SynchronizationDetailsViewVM>(new SynchronizationDetailsViewVM() { Status = SelectedSynchronization });
- }
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/CatalogView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/CatalogView.xaml
index 78fa17979..58c88324f 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/CatalogView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/CatalogView.xaml
@@ -20,116 +20,32 @@
<Border.Effect>
<DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
</Border.Effect>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Technician</TextBlock>
+ <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Technician Mode</TextBlock>
</Border>
- <touch:LightTouchScrollViewer Grid.Row="1">
- <Grid Grid.Row="1" VerticalAlignment="Top" Margin="20">
- <StackPanel Margin="30 0 30 0" DockPanel.Dock="Bottom" VerticalAlignment="Center">
+ <Grid Grid.Row="1" VerticalAlignment="Top" Margin="20">
+ <UniformGrid Columns="2">
+ <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="LoggingView" Width="250" Height="250" Style="{StaticResource TangoHollowButton}" Padding="20">
+ <DockPanel>
+ <TextBlock Margin="0 10 0 0" DockPanel.Dock="Bottom" HorizontalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Logging</TextBlock>
+ <Image Width="128" Source="../Images/logging.png" />
+ </DockPanel>
+ </touch:TouchButton>
- <StackPanel.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>
- </StackPanel.Resources>
+ <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="SystemView" Width="250" Height="250" Style="{StaticResource TangoHollowButton}" Padding="20">
+ <DockPanel>
+ <TextBlock Margin="0 10 0 0" DockPanel.Dock="Bottom" HorizontalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">System</TextBlock>
+ <Image Width="128" Source="../Images/system.png" />
+ </DockPanel>
+ </touch:TouchButton>
- <TextBlock Margin="0 20 0 40" Foreground="{StaticResource TangoGrayTextBrush}">The technician module enables additional diagnostic tools.</TextBlock>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="LoggingView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/logging.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Logging</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- Display and investigate issues using application and embedded device logs.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="SystemView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/system.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoTitleFontSize}">System</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- Display system properties, perform system actions, reset, shutdown etc...
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="DispensersView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/dispensers.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Dispensers</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- Perform manual dispensers homing priming.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="PackagesView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/packages.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Installed Packages</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- View the history of update packages installation.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="UpdatesView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/sync.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Updates &amp; Synchronization</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- View the current status and history of update and synchronization operations.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="RemoteConnectionsView" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/remote_connections.png" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Remote Connections</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- View the current status of remote connections to this machine.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <!--<touch:TouchButton Command="{Binding BrowserCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/browser.png" RenderOptions.BitmapScalingMode="Fant" Width="80" Height="80" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Browser</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" TextWrapping="Wrap" Width="580">
- Open the browser module and navigate the web.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>-->
- </StackPanel>
- </Grid>
- </touch:LightTouchScrollViewer>
+ <touch:TouchButton Command="{Binding NavigationCommand}" CommandParameter="DispensersView" Margin="0 60 0 0" Width="250" Height="250" Style="{StaticResource TangoHollowButton}" Padding="20">
+ <DockPanel>
+ <TextBlock Margin="0 10 0 0" DockPanel.Dock="Bottom" HorizontalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Dispensers</TextBlock>
+ <Image Width="128" Source="../Images/dispensers.png" />
+ </DockPanel>
+ </touch:TouchButton>
+ </UniformGrid>
+ </Grid>
</Grid>
</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/LoggingView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/LoggingView.xaml
index 8393349ea..39353c286 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/LoggingView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/LoggingView.xaml
@@ -34,7 +34,7 @@
<DockPanel>
<DockPanel DockPanel.Dock="Top">
<StackPanel Orientation="Horizontal">
- <touch:TouchNavigationLinks x:Name="nav" Margin="20" FontSize="{StaticResource TangoNavigationLinksFontSize}">
+ <touch:TouchNavigationLinks Margin="20" FontSize="{StaticResource TangoNavigationLinksFontSize}">
<sys:String>Application</sys:String>
<sys:String>Embedded</sys:String>
</touch:TouchNavigationLinks>
@@ -47,109 +47,91 @@
<touch:TouchIcon Icon="Magnify" Foreground="{StaticResource TangoGrayBrush}" Width="16" Height="16" />
<touch:TouchTextBox Width="200" VerticalAlignment="Center" Margin="5 -10 0 0" Text="{Binding Filter,Delay=1000}"></touch:TouchTextBox>
</StackPanel>
-
- <touch:TouchCheckBox IsChecked="{Binding ProcessDebugLogs}" Margin="20 0 0 0" Content="Debug Logs">
- <touch:TouchCheckBox.Style>
- <Style TargetType="touch:TouchCheckBox" BasedOn="{StaticResource {x:Type touch:TouchCheckBox}}">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding ElementName=nav,Path=SelectedIndex}" Value="0">
- <Setter Property="Visibility" Value="Visible"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchCheckBox.Style>
- </touch:TouchCheckBox>
</StackPanel>
</StackPanel>
<touch:TouchDatePicker Visibility="Collapsed" SelectedDate="12/15/2018" Height="40" />
</DockPanel>
<Grid Margin="20">
- <TabControl Padding="0" BorderThickness="0" Margin="0 10 0 0" Background="Transparent" SelectedIndex="{Binding ElementName=nav,Path=SelectedIndex,Mode=OneWay}">
- <TabItem Header="Application" Visibility="Collapsed">
- <touch:TouchSimpleDataGrid x:Name="gridApplication" Style="{StaticResource TechGrid}" ItemsSource="{Binding ApplicationLogsViewSource}" SelectedItem="{Binding SelectedLog}">
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="InformationOutline"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Category}" Value="Warning">
- <Setter Property="Icon" Value="ExclamationTriangleSolid"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Error">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Critical">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="Time" Width="120" Binding="{Binding TimeStamp,Converter={StaticResource DateTimeUTCToStringConverter},Mode=OneWay,ConverterParameter='hh\\:mm\\:ss.ff'}" />
- <DataGridTemplateColumn Header="Message" Width="1*">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <TextBlock Text="{Binding Message,Converter={StaticResource LogItemMessageToOneLineConverter},ConverterParameter='70',Mode=OneWay}"/>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </TabItem>
- <TabItem Header="Embedded" Visibility="Collapsed">
- <touch:TouchSimpleDataGrid x:Name="gridEmbedded" Style="{StaticResource TechGrid}" ItemsSource="{Binding EmbeddedLogsViewSource}" SelectedItem="{Binding SelectedLog}">
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="InformationOutline"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Category}" Value="Warning">
- <Setter Property="Icon" Value="ExclamationTriangleSolid"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Error">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding Category}" Value="Critical">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="Time" Width="120" Binding="{Binding TimeStamp,Converter={StaticResource DateTimeUTCToStringConverter},Mode=OneWay,ConverterParameter='hh\\:mm\\:ss.ff'}" />
- <DataGridTemplateColumn Header="Message" Width="1*">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <TextBlock Text="{Binding Message,Converter={StaticResource LogItemMessageToOneLineConverter},ConverterParameter='70',Mode=OneWay}"/>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </TabItem>
- </TabControl>
+ <touch:TouchSimpleDataGrid AutoGenerateColumns="False" SelectionMode="Single" SelectionUnit="FullRow" BorderThickness="1" BorderBrush="{StaticResource TangoDarkForegroundBrush}" HeadersVisibility="Column" CanUserAddRows="False" CanUserDeleteRows="False" CanUserReorderColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False" CanUserSortColumns="False" IsReadOnly="True" ItemsSource="{Binding ApplicationLogsViewSource}" SelectedItem="{Binding SelectedLog}" VerticalGridLinesBrush="{x:Null}" HorizontalGridLinesBrush="{StaticResource TangoGrayBrush}" RowHeight="50" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled">
+ <DataGrid.Resources>
+ <Style BasedOn="{StaticResource {x:Type DataGridColumnHeader}}" TargetType="{x:Type DataGridColumnHeader}">
+ <Setter Property="Background" Value="{StaticResource TangoDarkForegroundBrush}" />
+ <Setter Property="Foreground" Value="{StaticResource TangoLightForegroundBrush}" />
+ <Setter Property="Padding" Value="5"></Setter>
+ </Style>
+ </DataGrid.Resources>
+ <DataGrid.RowStyle>
+ <Style TargetType="DataGridRow" BasedOn="{StaticResource {x:Type DataGridRow}}">
+ <Style.Triggers>
+ <Trigger Property="IsSelected" Value="True">
+ <Setter Property="Background" Value="Transparent"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
+ </Trigger>
+ <Trigger Property="IsFocused" Value="True">
+ <Setter Property="Background" Value="Transparent"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
+ </Trigger>
+ </Style.Triggers>
+ </Style>
+ </DataGrid.RowStyle>
+ <DataGrid.CellStyle>
+ <Style TargetType="{x:Type DataGridCell}">
+ <Setter Property="Template">
+ <Setter.Value>
+ <ControlTemplate TargetType="{x:Type DataGridCell}">
+ <Grid Background="{TemplateBinding Background}">
+ <ContentPresenter VerticalAlignment="Center" />
+ </Grid>
+ </ControlTemplate>
+ </Setter.Value>
+ </Setter>
+ <Style.Triggers>
+ <Trigger Property="IsSelected" Value="True">
+ <Setter Property="Background" Value="Transparent"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
+ </Trigger>
+ </Style.Triggers>
+ </Style>
+ </DataGrid.CellStyle>
+ <DataGrid.Columns>
+ <DataGridTemplateColumn Header="" Width="50">
+ <DataGridTemplateColumn.CellTemplate>
+ <DataTemplate>
+ <touch:TouchIcon Width="16">
+ <touch:TouchIcon.Style>
+ <Style TargetType="touch:TouchIcon">
+ <Setter Property="Icon" Value="InformationOutline"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding Category}" Value="Warning">
+ <Setter Property="Icon" Value="ExclamationTriangleSolid"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding Category}" Value="Error">
+ <Setter Property="Icon" Value="Alert"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
+ </DataTrigger>
+ <DataTrigger Binding="{Binding Category}" Value="Critical">
+ <Setter Property="Icon" Value="Alert"></Setter>
+ <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </touch:TouchIcon.Style>
+ </touch:TouchIcon>
+ </DataTemplate>
+ </DataGridTemplateColumn.CellTemplate>
+ </DataGridTemplateColumn>
+ <DataGridTextColumn Header="Time" Width="120" Binding="{Binding TimeStamp,Converter={StaticResource DateTimeUTCToStringConverter},Mode=OneWay,ConverterParameter='hh\\:mm\\:ss.ff'}" />
+ <DataGridTemplateColumn Header="Message" Width="1*">
+ <DataGridTemplateColumn.CellTemplate>
+ <DataTemplate>
+ <TextBlock Text="{Binding Message,Converter={StaticResource LogItemMessageToOneLineConverter},ConverterParameter='70',Mode=OneWay}"/>
+ </DataTemplate>
+ </DataGridTemplateColumn.CellTemplate>
+ </DataGridTemplateColumn>
+ </DataGrid.Columns>
+ </touch:TouchSimpleDataGrid>
</Grid>
</DockPanel>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/MainView.xaml
index d4235341c..08f9a335a 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/MainView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/MainView.xaml
@@ -17,9 +17,6 @@
<local:LoggingView/>
<local:DispensersView/>
<local:SystemView/>
- <local:PackagesView/>
- <local:UpdatesView/>
- <local:RemoteConnectionsView/>
</controls:NavigationControl>
</Grid>
</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml
deleted file mode 100644
index a7944497b..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml
+++ /dev/null
@@ -1,103 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Views.PackagesView"
- 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:local="clr-namespace:Tango.PPC.Technician.Views"
- xmlns:controls="clr-namespace:Tango.PPC.Technician.Controls"
- xmlns:sys="clr-namespace:System;assembly=mscorlib"
- xmlns:vm="clr-namespace:Tango.PPC.Technician.ViewModels"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:global="clr-namespace:Tango.PPC.Technician"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:PackagesViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.PackagesViewVM}">
- <Grid Background="{StaticResource TangoMidBackgroundBrush}">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
-
- <Border Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
- <Border.Effect>
- <DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
- </Border.Effect>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Installed Packages</TextBlock>
- </Border>
-
- <Grid Grid.Row="1">
- <Grid Margin="20">
- <touch:TouchSimpleDataGrid Background="{StaticResource TangoPrimaryBackgroundBrush}" AutoGenerateColumns="False" SelectionMode="Single" SelectionUnit="FullRow" BorderThickness="1" BorderBrush="{StaticResource TangoDarkForegroundBrush}" HeadersVisibility="Column" CanUserAddRows="False" CanUserDeleteRows="False" CanUserReorderColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False" CanUserSortColumns="False" IsReadOnly="True" ItemsSource="{Binding Packages}" VerticalGridLinesBrush="{x:Null}" HorizontalGridLinesBrush="{StaticResource TangoGrayBrush}" RowHeight="50" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled">
- <DataGrid.Resources>
- <Style BasedOn="{StaticResource {x:Type DataGridColumnHeader}}" TargetType="{x:Type DataGridColumnHeader}">
- <Setter Property="Background" Value="{StaticResource TangoDarkForegroundBrush}" />
- <Setter Property="Foreground" Value="{StaticResource TangoLightForegroundBrush}" />
- <Setter Property="Padding" Value="5"></Setter>
- </Style>
- </DataGrid.Resources>
- <DataGrid.RowStyle>
- <Style TargetType="DataGridRow" BasedOn="{StaticResource {x:Type DataGridRow}}">
- <Style.Triggers>
- <Trigger Property="IsSelected" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- <Trigger Property="IsFocused" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- </Style.Triggers>
- </Style>
- </DataGrid.RowStyle>
- <DataGrid.CellStyle>
- <Style TargetType="{x:Type DataGridCell}">
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="{x:Type DataGridCell}">
- <Grid Background="{TemplateBinding Background}">
- <ContentPresenter VerticalAlignment="Center" />
- </Grid>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- <Style.Triggers>
- <Trigger Property="IsSelected" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- </Style.Triggers>
- </Style>
- </DataGrid.CellStyle>
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Pause"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding State}" Value="Failed">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Installed">
- <Setter Property="Icon" Value="Check"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="Type" Width="60" Binding="{Binding Type}" />
- <DataGridTextColumn Header="Date" Width="180" Binding="{Binding InstallationDate}" />
- <DataGridTextColumn Header="Name" Width="*" Binding="{Binding PackageName}" />
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml.cs
deleted file mode 100644
index 52384fe73..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/PackagesView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Views
-{
- /// <summary>
- /// Interaction logic for DispensersView.xaml
- /// </summary>
- public partial class PackagesView : UserControl
- {
- public PackagesView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml
deleted file mode 100644
index af93a56e5..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml
+++ /dev/null
@@ -1,88 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Views.RemoteConnectionsView"
- 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:vm="clr-namespace:Tango.PPC.Technician.ViewModels"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:global="clr-namespace:Tango.PPC.Technician"
- xmlns:local="clr-namespace:Tango.PPC.Technician.Views"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:RemoteConnectionsViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.RemoteConnectionsViewVM}">
- <Grid Background="{StaticResource TangoMidBackgroundBrush}">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
-
- <Border Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
- <Border.Effect>
- <DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
- </Border.Effect>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Remote Connections</TextBlock>
- </Border>
-
- <Grid Grid.Row="1">
- <Grid Margin="20">
- <DockPanel>
- <touch:TouchButton Command="{Binding DisconnectCommand}" DockPanel.Dock="Bottom" HorizontalAlignment="Right" Style="{StaticResource TangoHollowButton}" Height="60" Width="250" Margin="0 20 0 0">DISCONNECT</touch:TouchButton>
- <touch:TouchSimpleDataGrid IsSynchronizedWithCurrentItem="True" SelectedItem="{Binding SelectedReceiver,Mode=TwoWay}" Background="{StaticResource TangoPrimaryBackgroundBrush}" AutoGenerateColumns="False" SelectionMode="Single" SelectionUnit="FullRow" BorderThickness="1" BorderBrush="{StaticResource TangoDarkForegroundBrush}" HeadersVisibility="Column" CanUserAddRows="False" CanUserDeleteRows="False" CanUserReorderColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False" CanUserSortColumns="False" IsReadOnly="True" ItemsSource="{Binding ExternalBridgeService.ActiveReceivers}" VerticalGridLinesBrush="{x:Null}" HorizontalGridLinesBrush="{StaticResource TangoGrayBrush}" RowHeight="50" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled">
- <DataGrid.Resources>
- <Style BasedOn="{StaticResource {x:Type DataGridColumnHeader}}" TargetType="{x:Type DataGridColumnHeader}">
- <Setter Property="Background" Value="{StaticResource TangoDarkForegroundBrush}" />
- <Setter Property="Foreground" Value="{StaticResource TangoLightForegroundBrush}" />
- <Setter Property="Padding" Value="5"></Setter>
- </Style>
- </DataGrid.Resources>
- <DataGrid.RowStyle>
- <Style TargetType="DataGridRow" BasedOn="{StaticResource {x:Type DataGridRow}}">
- <Style.Triggers>
- <Trigger Property="IsSelected" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- <Trigger Property="IsFocused" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- </Style.Triggers>
- </Style>
- </DataGrid.RowStyle>
- <DataGrid.CellStyle>
- <Style TargetType="{x:Type DataGridCell}">
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="{x:Type DataGridCell}">
- <Grid Background="{TemplateBinding Background}">
- <ContentPresenter VerticalAlignment="Center" />
- </Grid>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- <Style.Triggers>
- <Trigger Property="IsSelected" Value="True">
- <Setter Property="Background" Value="Transparent"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}" />
- </Trigger>
- </Style.Triggers>
- </Style>
- </DataGrid.CellStyle>
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16" Icon="Bridge" />
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="App ID" Width="130" Binding="{Binding LoginInfo.AppID}" />
- <DataGridTextColumn Header="User" Width="180" Binding="{Binding LoginInfo.UserName}" />
- <DataGridTextColumn Header="Host Name" Width="180" Binding="{Binding LoginInfo.HostName}" />
- <DataGridTextColumn Header="Safety Level Permissions" Width="1*" Binding="{Binding LoginInfo.RequireSafetyLevelOperations,Converter={StaticResource BooleanToYesNoConverter}}" />
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </DockPanel>
- </Grid>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml.cs
deleted file mode 100644
index 5d8e32444..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/RemoteConnectionsView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Views
-{
- /// <summary>
- /// Interaction logic for RemoteConnectionsView.xaml
- /// </summary>
- public partial class RemoteConnectionsView : UserControl
- {
- public RemoteConnectionsView()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/SystemView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/SystemView.xaml
index 52abfc239..f2bfcdf7d 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/SystemView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/SystemView.xaml
@@ -8,10 +8,9 @@
xmlns:vm="clr-namespace:Tango.PPC.Technician.ViewModels"
xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
xmlns:global="clr-namespace:Tango.PPC.Technician"
mc:Ignorable="d"
- d:DesignHeight="1260" d:DesignWidth="600" d:DataContext="{d:DesignInstance Type=vm:SystemViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.SystemViewVM}" x:Name="view">
+ d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:SystemViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.SystemViewVM}" x:Name="view">
<UserControl.Resources>
<converters:ByteArrayToFileSizeConverter x:Key="ByteArrayToFileSizeConverter" />
@@ -30,283 +29,55 @@
<TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">System</TextBlock>
</Border>
- <Grid Grid.Row="1">
+ <Grid Grid.Row="1" Margin="20">
- <touch:LightTouchScrollViewer>
- <DockPanel Margin="20">
- <StackPanel Margin="30 40 30 0" DockPanel.Dock="Bottom" VerticalAlignment="Center">
+ <DockPanel>
+ <UniformGrid DockPanel.Dock="Top" Columns="3" Margin="50" TextElement.FontSize="{StaticResource TangoHeaderFontSize}">
+ <TextBlock HorizontalAlignment="Center" FontWeight="SemiBold">
+ <Run>CPU:</Run>
+ <Run Text="{Binding CPU,Mode=OneWay,StringFormat='0'}"></Run><Run>%</Run>
+ </TextBlock>
- <StackPanel.Resources>
- <Style TargetType="touch:TouchButton" x:Key="ButtonMenu">
- <Setter Property="Padding" Value="10"></Setter>
- <Setter Property="HorizontalContentAlignment" Value="Left"></Setter>
- <Setter Property="Height" Value="100"></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>
- </StackPanel.Resources>
+ <TextBlock HorizontalAlignment="Center" FontWeight="SemiBold">
+ <Run>RAM:</Run>
+ <Run Text="{Binding RAM,Mode=OneWay,Converter={StaticResource ByteArrayToFileSizeConverter},StringFormat='0'}"></Run>
+ </TextBlock>
- <touch:TouchButton Command="{Binding ResetDeviceCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/circuit-board.png" Width="60" Height="60" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Reset Embedded Device</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- Resets the embedded device using the DFU channel.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
-
- <touch:TouchButton Command="{Binding RestartCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/mobile-phone.png" Width="60" Height="60" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Restart Panel PC</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- Restarts the panel PC operation system.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
- <touch:TouchButton Command="{Binding ShutdownCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/shutdown.png" Width="60" Height="60" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Shutdown Panel PC</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- Turns off the panel PC (requires turning on from reset button).
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
- <touch:TouchButton Command="{Binding FactoryResetCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/conveyor.png" Width="60" Height="60" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Factory Reset</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- Removes all data associated with this machine and installs the latest version.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
- <touch:TouchButton Command="{Binding ExitToExplorerCommand}" Style="{StaticResource ButtonMenu}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
- <Image Source="../Images/exit.png" Width="60" Height="60" />
- <StackPanel Margin="10 0 0 0">
- <TextBlock FontSize="{StaticResource TangoButtonFontSize}">Exit To Shell</TextBlock>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
- Closes the PPC application and opens the windows shell.
- </TextBlock>
- </StackPanel>
- </StackPanel>
- </touch:TouchButton>
- </StackPanel>
-
- <FlowDocumentScrollViewer VerticalScrollBarVisibility="Disabled">
- <FlowDocument>
- <Table CellSpacing="0" FontFamily="{StaticResource TangoFlexoFontFamily}">
- <Table.Resources>
- <Style TargetType="{x:Type TableRowGroup}">
- <Setter Property="FontSize" Value="{StaticResource TangoDefaultFontSize}"/>
- </Style>
-
- <Style TargetType="TableCell">
- <Setter Property="BorderThickness" Value="0 0 0 1"></Setter>
- <Setter Property="BorderBrush" Value="{StaticResource TangoGrayBrush}"></Setter>
- <Setter Property="Padding" Value="5"></Setter>
- </Style>
- </Table.Resources>
- <Table.Columns>
- <TableColumn Width="160" />
- <TableColumn />
- <TableColumn />
- </Table.Columns>
-
- <TableRowGroup>
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Application Version:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding ApplicationManager.Version,Mode=OneWay,TargetNullValue='N/A',FallbackValue='N/A'}"/>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Firmware Version:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding MachineProvider.MachineOperator.DeviceInformation.Version,Mode=OneWay,TargetNullValue='N/A',FallbackValue='N/A'}"/>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>FPGA 1:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding MachineProvider.MachineOperator.DeviceInformation.FPGA1Version,Mode=OneWay,TargetNullValue='N/A',FallbackValue='N/A'}"/>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>FPGA 2:</TextBlock>
- </Paragraph>
- </TableCell>
+ <TextBlock HorizontalAlignment="Center" FontWeight="SemiBold">
+ <Run>TEMP:</Run>
+ <Run Text="{Binding Temperature,Mode=OneWay,StringFormat='0 °C'}"></Run>
+ </TextBlock>
+ </UniformGrid>
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding MachineProvider.MachineOperator.DeviceInformation.FPGA2Version,Mode=OneWay,TargetNullValue='N/A',FallbackValue='N/A'}"/>
- </Paragraph>
- </TableCell>
- </TableRow>
+ <DockPanel>
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>FPGA 3:</TextBlock>
- </Paragraph>
- </TableCell>
+ <StackPanel DockPanel.Dock="Top" HorizontalAlignment="Center">
+ <TextBlock HorizontalAlignment="Center" FontWeight="SemiBold" FontSize="{StaticResource TangoHeaderFontSize}">
+ <Run>UP TIME:</Run>
+ <Run Text="{Binding UpTime,StringFormat=hh\\:mm\\:ss,FallbackValue='00:00:00'}"></Run>
+ </TextBlock>
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding MachineProvider.MachineOperator.DeviceInformation.FPGA3Version,Mode=OneWay,TargetNullValue='N/A',FallbackValue='N/A'}"/>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>CPU:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock>
- <Run Text="{Binding CPU,Mode=OneWay,StringFormat='0',FallbackValue=0}"></Run>
- <Run>%</Run>
- </TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>RAM:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding RAM,Mode=OneWay,FallbackValue=0,Converter={StaticResource ByteArrayToFileSizeConverter},StringFormat='0'}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Temperature:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding Temperature,Mode=OneWay,FallbackValue=0,StringFormat='0 °C'}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Up Time:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding UpTime,Mode=OneWay,StringFormat=hh\\:mm\\:ss,FallbackValue='00:00:00'}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>IP Address:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding IPAddress,Mode=OneWay,FallbackValue=0}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Total Dye Time:</TextBlock>
- </Paragraph>
- </TableCell>
-
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding TotalDyeTime,Mode=OneWay,FallbackValue=0}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
-
- <TableRow>
- <TableCell>
- <Paragraph>
- <TextBlock>Total Dye Meters:</TextBlock>
- </Paragraph>
- </TableCell>
+ <TextBlock HorizontalAlignment="Center" Margin="0 20 0 0" FontWeight="SemiBold" FontSize="{StaticResource TangoHeaderFontSize}">
+ <Run>IP ADDRESS:</Run>
+ <Run Text="{Binding IPAddress}"></Run>
+ </TextBlock>
+ </StackPanel>
- <TableCell>
- <Paragraph>
- <TextBlock Text="{Binding TotalDyeMeters,Mode=OneWay,FallbackValue=0}"></TextBlock>
- </Paragraph>
- </TableCell>
- </TableRow>
- </TableRowGroup>
- </Table>
- </FlowDocument>
- </FlowDocumentScrollViewer>
+ <StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" Width="300" TextElement.FontSize="{StaticResource TangoTitleFontSize}">
+ <touch:TouchButton Command="{Binding ResetDeviceCommand}" Height="60" Content="Reset Machine">
+ <touch:TouchButton.Style>
+ <Style TargetType="touch:TouchButton" BasedOn="{StaticResource {x:Type touch:TouchButton}}">
+ <Setter Property="Background" Value="{StaticResource TangoErrorBrush}"></Setter>
+ </Style>
+ </touch:TouchButton.Style>
+ </touch:TouchButton>
+ <touch:TouchButton Command="{Binding RestartCommand}" Height="60" Background="{StaticResource TangoErrorBrush}" Margin="0 20 0 0">Restart Device</touch:TouchButton>
+ <touch:TouchButton Command="{Binding ShutdownCommand}" Height="60" Background="{StaticResource TangoErrorBrush}" Margin="0 20 0 0">Shutdown Device</touch:TouchButton>
+ <touch:TouchButton Command="{Binding FactoryResetCommand}" Height="60" Background="{StaticResource TangoErrorBrush}" Margin="0 20 0 0">Factory Reset</touch:TouchButton>
+ <touch:TouchButton Command="{Binding ExitToExplorerCommand}" Height="60" Background="{StaticResource TangoErrorBrush}" Margin="0 20 0 0">Exit To Shell</touch:TouchButton>
+ </StackPanel>
</DockPanel>
- </touch:LightTouchScrollViewer>
+ </DockPanel>
</Grid>
</Grid>
</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml
deleted file mode 100644
index 501632bfa..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml
+++ /dev/null
@@ -1,160 +0,0 @@
-<UserControl x:Class="Tango.PPC.Technician.Views.UpdatesView"
- 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:local="clr-namespace:Tango.PPC.Technician.Views"
- xmlns:sys="clr-namespace:System;assembly=mscorlib"
- xmlns:vm="clr-namespace:Tango.PPC.Technician.ViewModels"
- xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:converters="clr-namespace:Tango.PPC.Technician.Converters"
- xmlns:global="clr-namespace:Tango.PPC.Technician"
- mc:Ignorable="d"
- d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:UpdatesViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.UpdatesViewVM}">
-
- <UserControl.Resources>
- <converters:LogItemMessageToOneLineConverter x:Key="LogItemMessageToOneLineConverter" />
- </UserControl.Resources>
-
- <Grid Background="{StaticResource TangoMidBackgroundBrush}">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="1*"/>
- </Grid.RowDefinitions>
-
- <Border Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
- <Border.Effect>
- <DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
- </Border.Effect>
- <TextBlock VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold">Updates &amp; Synchronization</TextBlock>
- </Border>
-
- <Grid Grid.Row="1" Margin="15">
-
- <DockPanel>
- <touch:TouchNavigationLinks x:Name="nav" DockPanel.Dock="Top" FontSize="{StaticResource TangoTitleFontSize}">
- <sys:String>Updates</sys:String>
- <sys:String>Synchronization</sys:String>
- </touch:TouchNavigationLinks>
- <TabControl Padding="0" BorderThickness="0" Margin="0 10 0 0" Background="Transparent" SelectedIndex="{Binding ElementName=nav,Path=SelectedIndex,Mode=OneWay}">
- <TabItem Visibility="Collapsed" Header="Software Updates">
- <touch:TouchSimpleDataGrid Style="{StaticResource TechGrid}" ItemsSource="{Binding Updates}" SelectedItem="{Binding SelectedUpdate}">
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Pause"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsSetup}" Value="True">
- <Setter Property="Icon" Value="Settings"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsUpdate}" Value="True">
- <Setter Property="Icon" Value="CloudDownload"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsDataBase}" Value="True">
- <Setter Property="Icon" Value="Database"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsSynchronization}" Value="True">
- <Setter Property="Icon" Value="Sync"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsOfflineUpdate}" Value="True">
- <Setter Property="Icon" Value="Sd"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsOfflineFirmwareUpgrade}" Value="True">
- <Setter Property="Icon" Value="Chip"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsStarted}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsCompleted}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoSuccessBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding IsFailed}" Value="True">
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="Date" Width="120" Binding="{Binding StartDate,Converter={StaticResource DateTimeUTCToShortDateTimeConverter}}" />
- <DataGridTextColumn Header="Application" Width="120" Binding="{Binding ApplicationVersion}" />
- <DataGridTextColumn Header="Firmware" Width="120" Binding="{Binding FirmwareVersion}" />
- <DataGridTemplateColumn Header="Message" Width="1*">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <TextBlock Text="{Binding UpdateStatus,Converter={StaticResource EnumToDescriptionConverter}}"/>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </TabItem>
- <TabItem Visibility="Collapsed" Header="Synchronization">
- <DockPanel>
- <DockPanel DockPanel.Dock="Bottom">
- <DockPanel Margin="20">
- <touch:TouchButton IsEnabled="{Binding MachineDataSynchronizer.IsEnabled}" DockPanel.Dock="Right" Padding="50 20" CornerRadius="30" Command="{Binding SynchronizeCommand}">Synchronize Now</touch:TouchButton>
- <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Center" TextWrapping="Wrap" Margin="0 0 20 0">Synchronization occurres automatically in the background. You can choose to synchronize now.</TextBlock>
- </DockPanel>
- </DockPanel>
-
- <Grid>
- <touch:TouchSimpleDataGrid Style="{StaticResource TechGrid}" ItemsSource="{Binding MachineDataSynchronizer.StatusHistory}" SelectedItem="{Binding SelectedSynchronization}">
- <DataGrid.Columns>
- <DataGridTemplateColumn Header="" Width="50">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <touch:TouchIcon Width="16">
- <touch:TouchIcon.Style>
- <Style TargetType="touch:TouchIcon">
- <Setter Property="Icon" Value="Pause"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding State}" Value="Pending">
- <Setter Property="Icon" Value="Pause"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoGrayBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Synchronizing">
- <Setter Property="Icon" Value="CloudSync"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoWarningBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Failed">
- <Setter Property="Icon" Value="Alert"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoErrorBrush}"></Setter>
- </DataTrigger>
- <DataTrigger Binding="{Binding State}" Value="Completed">
- <Setter Property="Icon" Value="Check"></Setter>
- <Setter Property="Foreground" Value="{StaticResource TangoGreenBrush}"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </touch:TouchIcon.Style>
- </touch:TouchIcon>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- <DataGridTextColumn Header="Start Time" Width="120" Binding="{Binding StartDateTime,StringFormat=t}" />
- <DataGridTextColumn Header="Status" Width="120" Binding="{Binding State,Converter={StaticResource EnumToDescriptionConverter}}" />
- <DataGridTextColumn Header="Duration" Width="120" Binding="{Binding Duration,StringFormat='hh\\:mm\\:ss'}" />
- <DataGridTemplateColumn Header="Message" Width="1*">
- <DataGridTemplateColumn.CellTemplate>
- <DataTemplate>
- <TextBlock Text="{Binding Message,Converter={StaticResource StringEllipsisConverter},ConverterParameter='70',Mode=OneWay}"/>
- </DataTemplate>
- </DataGridTemplateColumn.CellTemplate>
- </DataGridTemplateColumn>
- </DataGrid.Columns>
- </touch:TouchSimpleDataGrid>
- </Grid>
- </DockPanel>
- </TabItem>
- </TabControl>
- </DockPanel>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml.cs
deleted file mode 100644
index cdac5cbbb..000000000
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Technician/Views/UpdatesView.xaml.cs
+++ /dev/null
@@ -1,28 +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;
-
-namespace Tango.PPC.Technician.Views
-{
- /// <summary>
- /// Interaction logic for UpdatesView.xaml
- /// </summary>
- public partial class UpdatesView : UserControl
- {
- public UpdatesView()
- {
- InitializeComponent();
- }
- }
-}