示例#1
0
        public GitHubConnectSection(IGitHubServiceProvider serviceProvider,
                                    ISimpleApiClientFactory apiFactory,
                                    ITeamExplorerServiceHolder holder,
                                    IConnectionManager manager,
                                    IPackageSettings packageSettings,
                                    ITeamExplorerServices teamExplorerServices,
                                    ILocalRepositories localRepositories,
                                    IUsageTracker usageTracker,
                                    int index)
            : base(serviceProvider, apiFactory, holder, manager)
        {
            Guard.ArgumentNotNull(apiFactory, nameof(apiFactory));
            Guard.ArgumentNotNull(holder, nameof(holder));
            Guard.ArgumentNotNull(manager, nameof(manager));
            Guard.ArgumentNotNull(packageSettings, nameof(packageSettings));
            Guard.ArgumentNotNull(teamExplorerServices, nameof(teamExplorerServices));
            Guard.ArgumentNotNull(localRepositories, nameof(localRepositories));
            Guard.ArgumentNotNull(usageTracker, nameof(usageTracker));

            Title        = "GitHub";
            IsEnabled    = true;
            IsVisible    = false;
            sectionIndex = index;

            this.packageSettings      = packageSettings;
            this.teamExplorerServices = teamExplorerServices;
            this.localRepositories    = localRepositories;
            this.usageTracker         = usageTracker;

            Clone = ReactiveCommand.CreateFromTask(DoClone);

            connectionManager.Connections.CollectionChanged += RefreshConnections;
            PropertyChanged += OnPropertyChange;
            UpdateConnection();
        }
示例#2
0
        public PullRequestPageViewModel(
            IViewViewModelFactory factory,
            IPullRequestService service,
            IPullRequestSessionManager sessionManager,
            ITeamExplorerServices teServices,
            IVisualStudioBrowser visualStudioBrowser,
            IUsageTracker usageTracker)
        {
            Guard.ArgumentNotNull(factory, nameof(factory));
            Guard.ArgumentNotNull(service, nameof(service));
            Guard.ArgumentNotNull(sessionManager, nameof(sessionManager));
            Guard.ArgumentNotNull(visualStudioBrowser, nameof(visualStudioBrowser));
            Guard.ArgumentNotNull(teServices, nameof(teServices));

            this.factory             = factory;
            this.service             = service;
            this.sessionManager      = sessionManager;
            this.teServices          = teServices;
            this.visualStudioBrowser = visualStudioBrowser;
            this.usageTracker        = usageTracker;

            timeline.ItemsRemoved.Subscribe(TimelineItemRemoved);

            ShowCommit   = ReactiveCommand.CreateFromTask <string>(DoShowCommit);
            OpenOnGitHub = ReactiveCommand.Create(DoOpenOnGitHub);
        }
        public ReleasesNavigationItem(IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService ws)
            : base(Octicon.book, git, shell, storage, tes, ws)
        {
            _tes = tes;

            Text = Gitea.VisualStudio.Shared.Strings.Releases;
        }
 public PublishSectionViewModel(IMessenger messenger, IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IViewFactory viewFactory, IWebService web)
 {
     messenger.Register("OnLogined", OnLogined);
     messenger.Register("OnSignOuted", OnSignOuted);
     _messenger   = messenger;
     _git         = git;
     _shell       = shell;
     _storage     = storage;
     _tes         = tes;
     _viewFactory = viewFactory;
     _web         = web;
     Name         = Strings.Name;
     if (string.IsNullOrEmpty(storage.Host))
     {
         Provider = Strings.Provider;
     }
     else
     {
         Provider = Strings.Provider + ": " + storage.Host + "";
     }
     Description        = Strings.Description;
     _loginCommand      = new DelegateCommand(OnLogin);
     _signUpCommand     = new DelegateCommand(OnSignUp);
     _getStartedCommand = new DelegateCommand(OnGetStarted);
     _publishCommand    = new DelegateCommand(OnPublish, CanPublish);
     ShowGetStarted     = storage.IsLogined;
     //IsStarted = true;
     LoadResources();
 }
示例#5
0
 public EnsureLoggedInSectionSync(IGitHubServiceProvider serviceProvider,
                                  ISimpleApiClientFactory apiFactory, ITeamExplorerServiceHolder holder,
                                  IConnectionManager cm, ITeamExplorerServices teServices,
                                  IDialogService dialogService)
     : base(serviceProvider, apiFactory, holder, cm, teServices, dialogService)
 {
 }
示例#6
0
        public ConnectSectionViewModel(IMessenger messenger, IShellService shell, IStorage storage, ITeamExplorerServices teamexplorer, IViewFactory viewFactory, IWebService web)
        {
            messenger.Register("OnLoggedIn", OnLoggedIn);
            messenger.Register("OnSignedOut", OnSignedOut);
            messenger.Register <string, Repository>("OnClone", OnRepositoryCloned);

            _messenger    = messenger;
            _shell        = shell;
            _storage      = storage;
            _teamexplorer = teamexplorer;
            _viewFactory  = viewFactory;
            _web          = web;

            Repositories = new ObservableCollection <Repository>();

            Repositories.CollectionChanged += OnRepositoriesChanged;

            SignInCommand          = new DelegateCommand(OnSignIn);
            SignUpCommand          = new DelegateCommand(OnSignUp);
            _signOutCommand        = new DelegateCommand(OnSignOut);
            _cloneCommand          = new DelegateCommand(OnClone);
            _createCommand         = new DelegateCommand(OnCreate);
            _openRepositoryCommand = new DelegateCommand <Repository>(OnOpenRepository);

            LoggedInButtonsVisible    = _storage.IsLogined ? Visibility.Visible : Visibility.Collapsed;
            NotLoggedInButtonsVisible = LoggedInButtonsVisible == Visibility.Visible ? Visibility.Collapsed : Visibility.Visible;
            IsRepositoriesVisible     = LoggedInButtonsVisible == Visibility.Visible;
            LoadRepositoriesAsync();
        }
        public ReleasesNavigationItem(IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService ws)
            : base(Octicon.book, git, shell, storage, tes, ws)
        {
            _tes = tes;

            Text = "Releases";
        }
        public WikiNavigationItem(IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService ws)
            : base(Octicon.book, git, shell, storage, tes, ws)
        {
            _tes = tes;

            Text = Strings.Items_Wiki;
        }
示例#9
0
        public ConnectSectionViewModel(IMessenger messenger, IShellService shell, IStorage storage, ITeamExplorerServices teamexplorer, IViewFactory viewFactory, IWebService web)
        {
            messenger.Register("OnLogined", OnLogined);
            messenger.Register <string, Repository>("OnClone", OnRepositoryCloned);

            _messenger    = messenger;
            _shell        = shell;
            _storage      = storage;
            _teamexplorer = teamexplorer;
            _viewFactory  = viewFactory;
            _web          = web;

            Repositories = new ObservableCollection <Repository>();

            Repositories.CollectionChanged += OnRepositoriesChanged;

            _signOutCommand        = new DelegateCommand(OnSignOut);
            _cloneCommand          = new DelegateCommand(OnClone);
            _createCommand         = new DelegateCommand(OnCreate);
            _openRepositoryCommand = new DelegateCommand <Repository>(OnOpenRepository);
            if (_storage.IsLogined)
            {
                LoadRepositories();
            }
        }
示例#10
0
 public EnsureLoggedInSection(ISimpleApiClientFactory apiFactory, ITeamExplorerServiceHolder holder,
                              IConnectionManager cm, IRepositoryHosts hosts, ITeamExplorerServices teServices)
     : base(apiFactory, holder, cm)
 {
     IsVisible       = false;
     this.hosts      = hosts;
     this.teServices = teServices;
 }
 public EnsureLoggedInSection(IGitHubServiceProvider serviceProvider,
                              ISimpleApiClientFactory apiFactory, ITeamExplorerServiceHolder holder,
                              IConnectionManager cm, ITeamExplorerServices teServices)
     : base(serviceProvider, apiFactory, holder, cm)
 {
     IsVisible       = false;
     this.teServices = teServices;
 }
示例#12
0
 public EnsureLoggedInSection(ISimpleApiClientFactory apiFactory, ITeamExplorerServiceHolder holder,
     IConnectionManager cm, IRepositoryHosts hosts, ITeamExplorerServices teServices)
     : base(apiFactory, holder, cm)
 {
     IsVisible = false;
     this.hosts = hosts;
     this.teServices = teServices;
 }
 public GitLabPublishSection(IMessenger messenger, IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IViewFactory viewFactory, IWebService web)
 {
     _messenger   = messenger;
     _git         = git;
     _shell       = shell;
     _storage     = storage;
     _tes         = tes;
     _viewFactory = viewFactory;
     _web         = web;
 }
示例#14
0
 public GitHubConnectSection0(IGitHubServiceProvider serviceProvider,
                              ISimpleApiClientFactory apiFactory,
                              ITeamExplorerServiceHolder holder,
                              IConnectionManager manager,
                              IPackageSettings settings,
                              ITeamExplorerServices teamExplorerServices,
                              ILocalRepositories localRepositories,
                              IUsageTracker usageTracker)
     : base(serviceProvider, apiFactory, holder, manager, settings, teamExplorerServices, localRepositories, usageTracker, 0)
 {
 }
        public RepositoryPublishControl(ITeamExplorerServices teServices, INotificationDispatcher notifications)
        {
            InitializeComponent();

            this.WhenActivated(d =>
            {
                d(this.BindCommand(ViewModel, vm => vm.PublishRepository, v => v.publishRepositoryButton));

                ViewModel.PublishRepository.Subscribe(state =>
                {
                    if (state == ProgressState.Success)
                    {
                        teServices.ShowMessage(UI.Resources.RepositoryPublishedMessage);
                        NotifyDone();
                    }
                });

                d(this.WhenAny(x => x.ViewModel.IsPublishing, x => x.Value)
                  .Subscribe(x => NotifyIsBusy(x)));


                d(notifications.Listen()
                  .Where(n => n.Type == Notification.NotificationType.Error)
                  .Subscribe(n => teServices.ShowError(n.Message)));

                d(this.WhenAny(x => x.ViewModel.SafeRepositoryNameWarningValidator.ValidationResult, x => x.Value)
                  .WhereNotNull()
                  .Select(result => result?.Message)
                  .Subscribe(message =>
                {
                    if (!String.IsNullOrEmpty(message))
                    {
                        teServices.ShowWarning(message);
                    }
                    else
                    {
                        teServices.ClearNotifications();
                    }
                }));

                nameText.Text = ViewModel.DefaultRepositoryName;
            });
            IsVisibleChanged += (s, e) =>
            {
                if (IsVisible)
                {
                    this.TryMoveFocus(FocusNavigationDirection.First).Subscribe();
                }
            };
        }
        public GitLabConnectSection(IMessenger messenger, IShellService shell, IStorage storage, ITeamExplorerServices teamexplorer, IViewFactory viewFactory, IWebService web)
        {
            _messenger    = messenger;
            _shell        = shell;
            _storage      = storage;
            _teamexplorer = teamexplorer;
            _viewFactory  = viewFactory;
            _web          = web;

            messenger.Register("OnLogined", OnLogined);
            messenger.Register("OnSignOuted", OnSignOuted);
            messenger.Register <string, Repository>("OnClone", OnClone);
            messenger.Register <string>("OnOpenSolution", OnOpenSolution);
        }
示例#17
0
        public RepositoryCloneService(
            IOperatingSystem operatingSystem,
            IVSGitServices vsGitServices,
            ITeamExplorerServices teamExplorerServices,
            IGraphQLClientFactory graphqlFactory,
            IUsageTracker usageTracker)
        {
            this.operatingSystem      = operatingSystem;
            this.vsGitServices        = vsGitServices;
            this.teamExplorerServices = teamExplorerServices;
            this.graphqlFactory       = graphqlFactory;
            this.usageTracker         = usageTracker;

            defaultClonePath = GetLocalClonePathFromGitProvider(operatingSystem.Environment.GetUserRepositoriesPath());
        }
        static RepositoryCloneService CreateRepositoryCloneService(IOperatingSystem operatingSystem           = null,
                                                                   IVSGitServices vsGitServices               = null, IUsageTracker usageTracker = null,
                                                                   ITeamExplorerServices teamExplorerServices = null, IGitHubServiceProvider serviceProvider = null)
        {
            operatingSystem      = operatingSystem ?? Substitute.For <IOperatingSystem>();
            vsGitServices        = vsGitServices ?? Substitute.For <IVSGitServices>();
            usageTracker         = usageTracker ?? Substitute.For <IUsageTracker>();
            teamExplorerServices = teamExplorerServices ?? Substitute.For <ITeamExplorerServices>();
            serviceProvider      = serviceProvider ?? Substitute.For <IGitHubServiceProvider>();

            operatingSystem.Environment.ExpandEnvironmentVariables(Args.String).Returns(x => x[0]);

            return(new RepositoryCloneService(operatingSystem, vsGitServices, teamExplorerServices,
                                              Substitute.For <IGraphQLClientFactory>(), Substitute.For <IGitHubContextService>(),
                                              usageTracker, serviceProvider));
        }
示例#19
0
        public GitLabConnectSection(IMessenger messenger, IShellService shell, IStorage storage, ITeamExplorerServices teamexplorer, IViewFactory viewFactory, IWebService web)
        {
            _messenger    = messenger;
            _shell        = shell;
            _storage      = storage;
            _teamexplorer = teamexplorer;
            _viewFactory  = viewFactory;
            _web          = web;

            messenger.Register("OnLogined", OnLogined);
            messenger.Register("OnSignOuted", OnSignOuted);
            messenger.Register <string, Repository>("OnClone", OnClone);
            messenger.Register <string>("OnOpenSolution", OnOpenSolution);
            var gitExt = Microsoft.VisualStudio.Shell.ServiceProvider.GlobalProvider.GetService <Microsoft.VisualStudio.TeamFoundation.Git.Extensibility.IGitExt>();

            gitExt.PropertyChanged += GitExt_PropertyChanged;
        }
        public GiteeConnectSection(IMessenger messenger, IShellService shell, IStorage storage, ITeamExplorerServices teamexplorer, IViewFactory viewFactory, IWebService web)
        {
            _messenger    = messenger;
            _shell        = shell;
            _storage      = storage;
            _teamexplorer = teamexplorer;
            _viewFactory  = viewFactory;
            _web          = web;

            messenger.Register("OnLogined", OnLogined);
            messenger.Register("OnSignOuted", OnSignOuted);
            messenger.Register <string, Repository>("OnClone", OnClone);
            messenger.Register <string>("OnOpenSolution", OnOpenSolution);
            IGitExt gitExt = GlobalServiceProvider.GlobalProvider.GetService <IGitExt>();

            gitExt.PropertyChanged += GitExt_PropertyChanged;
        }
        public GiteaNavigationItem(Octicon icon, IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService web)
        {
            _git     = git;
            _shell   = shell;
            _storage = storage;
            _tes     = tes;
            _web     = web;
            octicon  = icon;
            var brush = new SolidColorBrush(Color.FromRgb(66, 66, 66));

            brush.Freeze();
            OnThemeChanged();
            VSColorTheme.ThemeChanged += _ =>
            {
                OnThemeChanged();
                Invalidate();
            };
        }
        public RepositoryCloneService(
            IOperatingSystem operatingSystem,
            IVSGitServices vsGitServices,
            ITeamExplorerServices teamExplorerServices,
            IGraphQLClientFactory graphqlFactory,
            IGitHubContextService gitHubContextService,
            IUsageTracker usageTracker,
            IGitHubServiceProvider sp)
        {
            this.operatingSystem      = operatingSystem;
            this.vsGitServices        = vsGitServices;
            this.teamExplorerServices = teamExplorerServices;
            this.graphqlFactory       = graphqlFactory;
            this.gitHubContextService = gitHubContextService;
            this.usageTracker         = usageTracker;
            dte = new Lazy <EnvDTE.DTE>(() => sp.GetService <EnvDTE.DTE>());

            defaultClonePath = GetLocalClonePathFromGitProvider(operatingSystem.Environment.GetUserRepositoriesPath());
        }
示例#23
0
        public GitHubHomeSection(IGitHubServiceProvider serviceProvider,
                                 ISimpleApiClientFactory apiFactory,
                                 ITeamExplorerServiceHolder holder,
                                 IVisualStudioBrowser visualStudioBrowser,
                                 ITeamExplorerServices teamExplorerServices,
                                 IPackageSettings settings,
                                 IUsageTracker usageTracker)
            : base(serviceProvider, apiFactory, holder)
        {
            Title                     = "GitHub";
            View                      = new GitHubHomeContent();
            View.DataContext          = this;
            this.visualStudioBrowser  = visualStudioBrowser;
            this.teamExplorerServices = teamExplorerServices;
            this.settings             = settings;
            this.usageTracker         = usageTracker;

            var openOnGitHub = ReactiveCommand.Create();

            openOnGitHub.Subscribe(_ => DoOpenOnGitHub());
            OpenOnGitHub = openOnGitHub;

            // We want to display a welcome message but only if Team Explorer isn't
            // already displaying the "Install 3rd Party Tools" message. To do this
            // we need to set a timer and check in the tick as at this point the message
            // won't be initialized.
            if (!settings.HideTeamExplorerWelcomeMessage)
            {
                var timer = new DispatcherTimer();
                timer.Interval = new TimeSpan(10);
                timer.Tick    += (s, e) =>
                {
                    timer.Stop();
                    if (!IsGitToolsMessageVisible())
                    {
                        ShowWelcomeMessage();
                    }
                };
                timer.Start();
            }
        }
        public GistCreationControl(
            ITeamExplorerServices teServices,
            INotificationDispatcher notifications,
            [Import(typeof(SVsServiceProvider))] IServiceProvider serviceProvider)
        {
            InitializeComponent();

            this.WhenActivated(d =>
            {
                errorMessage.Visibility = Visibility.Collapsed;

                d(this.Bind(ViewModel, vm => vm.Description, v => v.descriptionTextBox.Text));
                d(this.Bind(ViewModel, vm => vm.FileName, v => v.fileNameTextBox.Text));
                d(this.Bind(ViewModel, vm => vm.IsPrivate, v => v.makePrivate.IsChecked));
                d(this.BindCommand(ViewModel, vm => vm.CreateGist, v => v.createGistButton));

                d(this.Bind(ViewModel, vm => vm.Account, v => v.accountStackPanel.DataContext));

                ViewModel.CreateGist
                .Where(x => x != null)
                .Subscribe(gist =>
                {
                    var browser = serviceProvider.GetExportedValue <IVisualStudioBrowser>();
                    browser?.OpenUrl(new Uri(gist.HtmlUrl));

                    var ns = serviceProvider.GetExportedValue <IStatusBarNotificationService>();
                    ns?.ShowMessage(UI.Resources.gistCreatedMessage);

                    NotifyDone();
                });

                d(notifications.Listen()
                  .Where(n => n.Type == Notification.NotificationType.Error)
                  .ObserveOnDispatcher(DispatcherPriority.Normal)
                  .Subscribe(n =>
                {
                    errorMessage.Visibility = Visibility.Visible;
                    errorMessageText.Text   = n.Message;
                }));
            });
        }
示例#25
0
        public GitHubHomeSection(IGitHubServiceProvider serviceProvider,
                                 ISimpleApiClientFactory apiFactory,
                                 ITeamExplorerServiceHolder holder,
                                 IVisualStudioBrowser visualStudioBrowser,
                                 ITeamExplorerServices teamExplorerServices,
                                 IPackageSettings settings,
                                 IUsageTracker usageTracker)
            : base(serviceProvider, apiFactory, holder)
        {
            Title                     = "GitHub";
            View                      = new GitHubHomeContent();
            View.DataContext          = this;
            this.visualStudioBrowser  = visualStudioBrowser;
            this.teamExplorerServices = teamExplorerServices;
            this.settings             = settings;
            this.usageTracker         = usageTracker;

            var openOnGitHub = new RelayCommand(_ => DoOpenOnGitHub());

            OpenOnGitHub = openOnGitHub;
        }
        public GitLabNavigationItem(Octicon icon, IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService web)
        {
            _git     = git;
            _shell   = shell;
            _storage = storage;
            _tes     = tes;
            _web     = web;
            octicon  = icon;
            var brush = new SolidColorBrush(Color.FromRgb(66, 66, 66));

            brush.Freeze();
            OnThemeChanged();
            VSColorTheme.ThemeChanged += _ =>
            {
                OnThemeChanged();
                Invalidate();
            };
            var gitExt = ServiceProvider.GlobalProvider.GetService <Microsoft.VisualStudio.TeamFoundation.Git.Extensibility.IGitExt>();

            gitExt.PropertyChanged += GitExt_PropertyChanged;
        }
        public PublishSectionViewModel(IMessenger messenger, IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IViewFactory viewFactory, IWebService web)
        {
            messenger.Register("OnLogined", OnLogined);
            messenger.Register("OnSignOuted", OnSignOuted);

            _messenger   = messenger;
            _git         = git;
            _shell       = shell;
            _storage     = storage;
            _tes         = tes;
            _viewFactory = viewFactory;
            _web         = web;

            Name        = Strings.Name;
            Provider    = Strings.Provider;
            Description = Strings.Description;

            _loginCommand      = new DelegateCommand(OnLogin);
            _signUpCommand     = new DelegateCommand(OnSignUp);
            _getStartedCommand = new DelegateCommand(OnGetStarted);
            _publishCommand    = new DelegateCommand(OnPublish, CanPublish);

            LoadResources();
        }
        public RepositoryPublishControl(ITeamExplorerServices teServices, INotificationDispatcher notifications)
        {
            InitializeComponent();

            this.WhenActivated(d =>
            {
                d(this.OneWayBind(ViewModel, vm => vm.Connections, v => v.hostsComboBox.ItemsSource));
                d(this.OneWayBind(ViewModel, vm => vm.IsHostComboBoxVisible, v => v.hostsComboBox.Visibility));
                d(this.Bind(ViewModel, vm => vm.SelectedConnection, v => v.hostsComboBox.SelectedItem));

                d(this.Bind(ViewModel, vm => vm.RepositoryName, v => v.nameText.Text));

                d(this.Bind(ViewModel, vm => vm.Description, v => v.description.Text));
                d(this.Bind(ViewModel, vm => vm.KeepPrivate, v => v.makePrivate.IsChecked));
                d(this.OneWayBind(ViewModel, vm => vm.CanKeepPrivate, v => v.makePrivate.IsEnabled));

                d(this.OneWayBind(ViewModel, vm => vm.Accounts, v => v.accountsComboBox.ItemsSource));
                d(this.Bind(ViewModel, vm => vm.SelectedAccount, v => v.accountsComboBox.SelectedItem));

                d(this.BindCommand(ViewModel, vm => vm.PublishRepository, v => v.publishRepositoryButton));

                d(this.OneWayBind(ViewModel, vm => vm.IsPublishing, v => v.nameText.IsEnabled, x => x == false));
                d(this.OneWayBind(ViewModel, vm => vm.IsPublishing, v => v.description.IsEnabled, x => x == false));
                d(this.OneWayBind(ViewModel, vm => vm.IsPublishing, v => v.accountsComboBox.IsEnabled, x => x == false));

                ViewModel.PublishRepository.Subscribe(state =>
                {
                    if (state == ProgressState.Success)
                    {
                        teServices.ShowMessage(UI.Resources.RepositoryPublishedMessage);
                        NotifyDone();
                    }
                });

                d(this.WhenAny(x => x.ViewModel.IsPublishing, x => x.Value)
                  .Subscribe(x => NotifyIsBusy(x)));


                d(notifications.Listen()
                  .Where(n => n.Type == Notification.NotificationType.Error)
                  .Subscribe(n => teServices.ShowError(n.Message)));

                d(this.WhenAny(x => x.ViewModel.SafeRepositoryNameWarningValidator.ValidationResult, x => x.Value)
                  .WhereNotNull()
                  .Select(result => result?.Message)
                  .Subscribe(message =>
                {
                    if (!String.IsNullOrEmpty(message))
                    {
                        teServices.ShowWarning(message);
                    }
                    else
                    {
                        teServices.ClearNotifications();
                    }
                }));

                nameText.Text = ViewModel.DefaultRepositoryName;
            });
            IsVisibleChanged += (s, e) =>
            {
                if (IsVisible)
                {
                    this.TryMoveFocus(FocusNavigationDirection.First).Subscribe();
                }
            };
        }
 public NotAGitHubRepositoryViewModel(ITeamExplorerServices teamExplorerServices)
 {
     this.teamExplorerServices = teamExplorerServices;
     Publish = ReactiveCommand.Create();
     Publish.Subscribe(_ => OnPublish());
 }
示例#30
0
 public IssuesNavigationItem(IGitService git, IShellService shell, IStorage storage, ITeamExplorerServices tes, IWebService ws)
     : base(Octicon.issue_opened, git, shell, storage, tes, ws)
 {
     _tes = tes;
     Text = Strings.Items_Issues;
 }
示例#31
0
 public NotAGitHubRepositoryViewModel(ITeamExplorerServices teamExplorerServices)
 {
     this.teamExplorerServices = teamExplorerServices;
     Publish = ReactiveCommand.Create();
     Publish.Subscribe(_ => OnPublish());
 }
 public LoginFailedViewModel(ITeamExplorerServices teServices)
 {
     this.teServices  = teServices;
     OpenTeamExplorer = ReactiveCommand.Create().OnExecuteCompleted(_ => DoOpenTeamExplorer());
 }
 public EnsureLoggedInSectionSync(ISimpleApiClientFactory apiFactory, ITeamExplorerServiceHolder holder,
     IConnectionManager cm, IRepositoryHosts hosts, ITeamExplorerServices teServices)
     : base(apiFactory, holder, cm, hosts, teServices)
 {}