diff options
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs index e55d0534e..05181fd3f 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs @@ -21,6 +21,7 @@ using Tango.MachineStudio.Common.Web; using Tango.Core.DI; using Tango.Settings; using Tango.Core; +using Tango.MachineStudio.Common.Buid; namespace Tango.MachineStudio.UI.ViewModels { @@ -35,6 +36,7 @@ namespace Tango.MachineStudio.UI.ViewModels private INavigationManager _navigationManager; private IStudioModuleLoader _studioModuleLoader; private IEventLogger _eventLogger; + private IBuildProvider _buildProvider; private LogManager logManager = LogManager.Default; public IStudioApplicationManager ApplicationManager { get; set; } @@ -58,7 +60,7 @@ namespace Tango.MachineStudio.UI.ViewModels /// <param name="navigationManager">The navigation manager.</param> /// <param name="studioModuleLoader">The studio module loader.</param> /// <param name="notificationProvider">The notification provider.</param> - public LoadingViewVM(IStudioApplicationManager applicationManager, INavigationManager navigationManager, IStudioModuleLoader studioModuleLoader, INotificationProvider notificationProvider, IEventLogger eventLogger, TeamFoundationServiceExtendedClient teamFoundationClient) + public LoadingViewVM(IBuildProvider buildProvider, IStudioApplicationManager applicationManager, INavigationManager navigationManager, IStudioModuleLoader studioModuleLoader, INotificationProvider notificationProvider, IEventLogger eventLogger, TeamFoundationServiceExtendedClient teamFoundationClient) { Status = "Loading, please wait..."; _tfs = teamFoundationClient; @@ -67,6 +69,7 @@ namespace Tango.MachineStudio.UI.ViewModels _navigationManager = navigationManager; _studioModuleLoader = studioModuleLoader; _notificationProvider = notificationProvider; + _buildProvider = buildProvider; } /// <summary> @@ -89,15 +92,18 @@ namespace Tango.MachineStudio.UI.ViewModels { try { - try + if (_buildProvider.BuildType == MSBuildType.Default) { - Status = "Connecting to Team Foundation Services..."; - _tfs.Initialize(); - Thread.Sleep(500); - } - catch (Exception ex) - { - LogManager.Log(ex, "Could not initialize Team Foundation Service client."); + try + { + Status = "Connecting to Team Foundation Services..."; + _tfs.Initialize(); + Thread.Sleep(500); + } + catch (Exception ex) + { + LogManager.Log(ex, "Could not initialize Team Foundation Service client."); + } } Status = "Loading, please wait..."; |
