forked from qt-creator/qt-creator
cmake: Add option to disable subfolders
An option is added to change the default behavior that would create subfolders inside source groups for files based on their location on disk. When disabling the option, files will be added directly under their respective source group. The virtual folders <build-folder> and <other-files> is also omitted when the option is disabled. Fixes: QTCREATORBUG-27432 Change-Id: Id78e178011c5299d4f7257bf855a5d791eebf91c Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
@@ -72,6 +72,11 @@ CMakeSpecificSettings::CMakeSpecificSettings()
|
||||
askBeforeReConfigureInitialParams.setDefaultValue(true);
|
||||
askBeforeReConfigureInitialParams.setLabelText(tr("Ask before re-configuring with "
|
||||
"initial parameters"));
|
||||
|
||||
registerAspect(&showSourceSubFolders);
|
||||
showSourceSubFolders.setSettingsKey("ShowSourceSubFolders");
|
||||
showSourceSubFolders.setDefaultValue(true);
|
||||
showSourceSubFolders.setLabelText(tr("Show subfolders inside source group folders"));
|
||||
}
|
||||
|
||||
// CMakeSpecificSettingsPage
|
||||
@@ -93,6 +98,7 @@ CMakeSpecificSettingsPage::CMakeSpecificSettingsPage(CMakeSpecificSettings *sett
|
||||
},
|
||||
s.packageManagerAutoSetup,
|
||||
s.askBeforeReConfigureInitialParams,
|
||||
s.showSourceSubFolders,
|
||||
Stretch(),
|
||||
}.attachTo(widget);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user