1818using GitHub . Models . Drafts ;
1919using GitHub . Primitives ;
2020using GitHub . Services ;
21+ using GitHub . UI ;
2122using GitHub . Validation ;
2223using Octokit ;
2324using ReactiveUI ;
@@ -51,8 +52,9 @@ public PullRequestCreationViewModel(
5152 IPullRequestService service ,
5253 INotificationService notifications ,
5354 IMessageDraftStore draftStore ,
54- IGitService gitService )
55- : this ( modelServiceFactory , service , notifications , draftStore , gitService , DefaultScheduler . Instance )
55+ IGitService gitService ,
56+ IAutoCompleteAdvisor autoCompleteAdvisor )
57+ : this ( modelServiceFactory , service , notifications , draftStore , gitService , autoCompleteAdvisor , DefaultScheduler . Instance )
5658 {
5759 }
5860
@@ -62,19 +64,22 @@ public PullRequestCreationViewModel(
6264 INotificationService notifications ,
6365 IMessageDraftStore draftStore ,
6466 IGitService gitService ,
67+ IAutoCompleteAdvisor autoCompleteAdvisor ,
6568 IScheduler timerScheduler )
6669 {
6770 Guard . ArgumentNotNull ( modelServiceFactory , nameof ( modelServiceFactory ) ) ;
6871 Guard . ArgumentNotNull ( service , nameof ( service ) ) ;
6972 Guard . ArgumentNotNull ( notifications , nameof ( notifications ) ) ;
7073 Guard . ArgumentNotNull ( draftStore , nameof ( draftStore ) ) ;
7174 Guard . ArgumentNotNull ( gitService , nameof ( gitService ) ) ;
75+ Guard . ArgumentNotNull ( autoCompleteAdvisor , nameof ( autoCompleteAdvisor ) ) ;
7276 Guard . ArgumentNotNull ( timerScheduler , nameof ( timerScheduler ) ) ;
7377
7478 this . service = service ;
7579 this . modelServiceFactory = modelServiceFactory ;
7680 this . draftStore = draftStore ;
7781 this . gitService = gitService ;
82+ this . AutoCompleteAdvisor = autoCompleteAdvisor ;
7883 this . timerScheduler = timerScheduler ;
7984
8085 this . WhenAnyValue ( x => x . Branches )
@@ -334,8 +339,9 @@ protected string GetDraftKey()
334339 SourceBranch . Name ) ;
335340 }
336341
337- public RemoteRepositoryModel GitHubRepository { get { return githubRepository ? . Value ; } }
338- bool IsExecuting { get { return isExecuting . Value ; } }
342+ public RemoteRepositoryModel GitHubRepository => githubRepository ? . Value ;
343+ bool IsExecuting => isExecuting . Value ;
344+ public IAutoCompleteAdvisor AutoCompleteAdvisor { get ; }
339345
340346 bool initialized ;
341347 bool Initialized
0 commit comments