forked from qt-creator/qt-creator
DiffUtils: Get rid of PatchFormattingFlags
Get rid of PatchFormattingFlags argument inside DiffUtils::makePatch(), as there is the only caller of this method. Internally, behave like the GitFormat flag was passed. As all callers to sideFileName() were always passing AddLevel (GitFormat flag contained AddLevel), the flag is not needed anymore. Change-Id: I1993cfd7212f5f60a5bdb2c9e1e4317c3ecd91d7 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -126,11 +126,6 @@ public:
|
||||
|
||||
class DIFFEDITOR_EXPORT DiffUtils {
|
||||
public:
|
||||
enum PatchFormattingFlags {
|
||||
AddLevel = 0x1, // Add 'a/' , '/b' for git am
|
||||
GitFormat = AddLevel | 0x2, // Add line 'diff ..' as git does
|
||||
};
|
||||
|
||||
static ChunkData calculateOriginalData(const QList<Utils::Diff> &leftDiffList,
|
||||
const QList<Utils::Diff> &rightDiffList);
|
||||
static FileData calculateContextData(const ChunkData &originalData,
|
||||
@@ -146,8 +141,7 @@ public:
|
||||
const QString &leftFileName,
|
||||
const QString &rightFileName,
|
||||
bool lastChunk = false);
|
||||
static QString makePatch(const QList<FileData> &fileDataList,
|
||||
unsigned formatFlags = 0);
|
||||
static QString makePatch(const QList<FileData> &fileDataList);
|
||||
static QList<FileData> readPatch(const QString &patch,
|
||||
bool *ok = nullptr,
|
||||
QFutureInterfaceBase *jobController = nullptr);
|
||||
|
||||
Reference in New Issue
Block a user