/// <summary> /// Initializes the singleton instance of the command. /// </summary> /// <param name="package">Owner package, not null.</param> public static async Task InitializeAsync(REConverterPackage package) { var codeConversion = await CodeConversion.CreateAsync(package, package.VsWorkspace, package.GetOptionsAsync); var oleMenuCommandService = await package.GetServiceAsync <IMenuCommandService, OleMenuCommandService>(); await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync(); Instance = new ConvertVBToCSCommand(package, codeConversion, oleMenuCommandService); }
/// <summary> /// Initializes the singleton instance of the command. /// </summary> /// <param name="package">Owner package, not null.</param> public static async Task InitializeAsync(REConverterPackage package) { CodeConversion codeConversion = await CodeConversion.CreateAsync(package, package.VsWorkspace, package.GetOptionsAsync); Instance = new ConvertCSToVBCommand(package, codeConversion, await package.GetServiceAsync <IMenuCommandService, OleMenuCommandService>()); }