qmlfrontend/runqueue.h
author unc0rr
Sun, 07 Jan 2018 09:48:26 +0100
branchqmlfrontend
changeset 12884 66171ce586cc
parent 12861 488782d9aba9
permissions -rw-r--r--
Fix referencing missing item
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12861
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     1
#ifndef RUNQUEUE_H
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     2
#define RUNQUEUE_H
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     3
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     4
#include <QObject>
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     5
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     6
#include "gameconfig.h"
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     7
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     8
class RunQueue : public QObject {
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
     9
    Q_OBJECT
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    10
public:
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    11
    explicit RunQueue(QObject* parent = nullptr);
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    12
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    13
    void queue(const GameConfig& config);
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    14
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    15
signals:
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    16
    void previewIsRendering();
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    17
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    18
public slots:
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    19
    void onGameFinished();
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    20
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    21
private:
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    22
    QList<GameConfig> m_runQueue;
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    23
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    24
    void nextRun();
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    25
};
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    26
488782d9aba9 Recreate uFLRunQueue in Qt, render previews
unc0rr
parents:
diff changeset
    27
#endif // RUNQUEUE_H