From 72fc39f873de467c1431d928bce4d39442205691 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Sun, 19 Oct 2025 16:20:01 +0300 Subject: MS LITE --- .../ViewModels/LoadingViewVM.cs | 24 ++++++++++++++-------- 1 file changed, 15 insertions(+), 9 deletions(-) (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoadingViewVM.cs') 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 /// The navigation manager. /// The studio module loader. /// The notification provider. - 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; } /// @@ -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..."; -- cgit v1.3.1