15 #ifndef BORNAGAIN_GUI_VIEW_JOB_JOBLISTMODEL_H
16 #define BORNAGAIN_GUI_VIEW_JOB_JOBLISTMODEL_H
18 #include <QAbstractListModel>
30 int rowCount(
const QModelIndex& parent = QModelIndex())
const override;
32 QVariant
data(
const QModelIndex& index,
int role = Qt::DisplayRole)
const override;
37 void runJob(
const QModelIndex& index);
44 void onRowsInserted(
const QModelIndex& parent,
int start,
int end);
void removeJob(const QModelIndex &index)
void disableJobNotification(JobItem *job)
JobListModel(JobModel *jobs, QObject *parent=nullptr)
int rowCount(const QModelIndex &parent=QModelIndex()) const override
void cancelJob(const QModelIndex &index)
QModelIndex indexForJob(JobItem *job)
void onRowsInserted(const QModelIndex &parent, int start, int end)
void emitJobListModelChanged(JobItem *job)
JobItem * jobForIndex(const QModelIndex &index) const
void enableJobNotification(JobItem *job)
void onRowsAboutToBeInserted(const QModelIndex &parent, int start, int end)
void runJob(const QModelIndex &index)
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const override