Use more FilePathAspect

Change-Id: Ib348df1460f8610607251498b07010df58d51ddf
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
hjk
2023-05-17 17:18:11 +02:00
parent 2274847bfe
commit 6f31d87444
26 changed files with 53 additions and 66 deletions

View File

@@ -52,7 +52,6 @@ public:
registerAspect(&command);
command.setSettingsKey("autoFormatCommand");
command.setDisplayStyle(StringAspect::PathChooserDisplay);
command.setDefaultValue("cmake-format");
command.setExpectedKind(PathChooser::ExistingCommand);
@@ -121,14 +120,14 @@ public:
TextEditor::Command formatCommand() const
{
TextEditor::Command cmd;
cmd.setExecutable(command.filePath());
cmd.setExecutable(command());
cmd.setProcessing(TextEditor::Command::FileProcessing);
cmd.addOption("--in-place");
cmd.addOption("%file");
return cmd;
}
StringAspect command;
FilePathAspect command;
BoolAspect autoFormatOnSave;
BoolAspect autoFormatOnlyCurrentProject;
StringAspect autoFormatMime;