public void ExecuteCommand(SortAndRemoveUnnecessaryImportsCommandArgs args, Action nextHandler) { this.WaitIndicator.Wait( title: EditorFeaturesResources.Organize_Document, message: EditorFeaturesResources.Organizing_document, allowCancel: true, action: waitContext => this.SortAndRemoveUnusedImports(args.SubjectBuffer, waitContext.CancellationToken)); }
public bool ExecuteCommand(SortAndRemoveUnnecessaryImportsCommandArgs args, CommandExecutionContext context) { using (context.OperationContext.AddScope(allowCancellation: true, EditorFeaturesResources.Organizing_document)) { this.SortAndRemoveUnusedImports(args.SubjectBuffer, context.OperationContext); } return(true); }
public CommandState GetCommandState(SortAndRemoveUnnecessaryImportsCommandArgs args, Func <CommandState> nextHandler) { return(GetCommandState(args, nextHandler, o => o.SortAndRemoveUnusedImportsDisplayStringWithAccelerator)); }
public CommandState GetCommandState(SortAndRemoveUnnecessaryImportsCommandArgs args) { return(GetCommandState(args, o => o.SortAndRemoveUnusedImportsDisplayStringWithAccelerator, needsSemantics: true)); }
public VSCommanding.CommandState GetCommandState(SortAndRemoveUnnecessaryImportsCommandArgs args) { return(GetCommandState(args, o => o.SortAndRemoveUnusedImportsDisplayStringWithAccelerator)); }