public void Start() { SetStatus(VsSearchTaskStatus.Started); SetStatus(VsSearchTaskStatus.Completed); if (!String.IsNullOrEmpty(SearchQuery.SearchString)) { var result = new NuGetStaticSearchResult(_dte, SearchQuery.SearchString, _provider); _searchCallback.ReportResult(this, result); _searchCallback.ReportComplete(this, 1); } else { _searchCallback.ReportComplete(this, 0); } }
public void Start() { SetStatus(VsSearchTaskStatus.Started); SetStatus(VsSearchTaskStatus.Completed); OleMenuCommand supportedManagePackageCommand = GetSupportedManagePackageCommand(); if (!String.IsNullOrEmpty(SearchQuery.SearchString) && null != supportedManagePackageCommand) { var result = new NuGetStaticSearchResult(SearchQuery.SearchString, _provider, supportedManagePackageCommand); _searchCallback.ReportResult(this, result); _searchCallback.ReportComplete(this, 1); } else { _searchCallback.ReportComplete(this, 0); } }
public void Start() { NuGetUIThreadHelper.JoinableTaskFactory.Run(async() => { await NuGetUIThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync(); SetStatus(VsSearchTaskStatus.Started); SetStatus(VsSearchTaskStatus.Completed); var supportedManagePackageCommand = GetSupportedManagePackageCommand(); if (!string.IsNullOrEmpty(SearchQuery.SearchString) && null != supportedManagePackageCommand) { var result = new NuGetStaticSearchResult(SearchQuery.SearchString, _provider, supportedManagePackageCommand); _searchCallback.ReportResult(this, result); _searchCallback.ReportComplete(this, 1); } else { _searchCallback.ReportComplete(this, 0); } }); }