forked from qt-creator/qt-creator
Wizards: Make it possible to check existing files to overwrite.
Present a checkable list of files to be overwritten, enabling re-generating a part of the project or class. Task-number: QTCREATORBUG-4538
This commit is contained in:
@@ -69,7 +69,9 @@ public:
|
||||
OpenProjectAttribute = 0x02,
|
||||
/* File is generated by external scripts, do not write out,
|
||||
* see BaseFileWizard::writeFiles() */
|
||||
CustomGeneratorAttribute = 0x4
|
||||
CustomGeneratorAttribute = 0x4,
|
||||
/* File exists and the user indicated that he wants to keep it */
|
||||
KeepExistingFileAttribute = 0x8
|
||||
};
|
||||
Q_DECLARE_FLAGS(Attributes, Attribute)
|
||||
|
||||
@@ -188,7 +190,7 @@ protected:
|
||||
static QString preferredSuffix(const QString &mimeType);
|
||||
|
||||
enum OverwriteResult { OverwriteOk, OverwriteError, OverwriteCanceled };
|
||||
OverwriteResult promptOverwrite(const QStringList &files,
|
||||
OverwriteResult promptOverwrite(GeneratedFiles *files,
|
||||
QString *errorMessage) const;
|
||||
static bool postGenerateOpenEditors(const GeneratedFiles &l, QString *errorMessage = 0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user