forked from qt-creator/qt-creator
Fixes: Make git diff work for staged files, do not launch submit if file list empty, make file model read only, add conveniences
Details: Add a type data field to the git file model
This commit is contained in:
@@ -49,9 +49,16 @@ class VCSBASE_EXPORT SubmitFileModel : public QStandardItemModel
|
||||
public:
|
||||
explicit SubmitFileModel(QObject *parent = 0);
|
||||
|
||||
// Convenience to add a file plus status text.
|
||||
// Convenience to create and add rows containing a file plus status text.
|
||||
static QList<QStandardItem *> createFileRow(const QString &fileName, const QString &status = QString(), bool checked = true);
|
||||
QList<QStandardItem *> addFile(const QString &fileName, const QString &status = QString(), bool checked = true);
|
||||
|
||||
// Find convenience that returns the whole row (as opposed to QStandardItemModel::find).
|
||||
QList<QStandardItem *> findRow(const QString &text, int column = 0) const;
|
||||
|
||||
// Convenience to obtain a row
|
||||
QList<QStandardItem *> rowAt(int row) const;
|
||||
|
||||
// Filter for entries contained in the filter list. Returns the
|
||||
// number of deleted entries.
|
||||
unsigned filter(const QStringList &filter, int column);
|
||||
|
||||
Reference in New Issue
Block a user