public static async Task InitializeAsync(Shell.AsyncPackage package) { await Shell.ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync(package.DisposalToken); Shell.OleMenuCommandService commandService = await package.GetServiceAsync(typeof(IMenuCommandService)) as Shell.OleMenuCommandService; Instance = new OpenT4EditorSettingsCommand(package, commandService); }
protected override async Task InitializeAsync(CancellationToken cancellationToken, IProgress <ServiceProgressData> progress) { await this.JoinableTaskFactory.SwitchToMainThreadAsync(cancellationToken); await OpenT4EditorSettingsCommand.InitializeAsync(this); }