#ifndef TRIVIAAPP_H
#define TRIVIAAPP_H

#include <QApplication>
#include <QVector>
#include <QMainWindow>

#include "MainWindow.h"


class Question; // forward declaration
class QTimer;
class QPushButton;

static const QString triviaFilename = "Trivia.xml";

class TriviaApp : public QApplication{
    Q_OBJECT

    protected:
        QVector<Question*> questions;
        Mainwindow mainwindow;
        QTimer *timer;
        int userScore;
        QPushButton *bottonContinue;

    public:
        TriviaApp(int argc, char* argv[]);
        ~TriviaApp();
        int crear();
        Question* createQuestion(const QString& type, const QString& duration);

    protected:
        bool loadQuestions();
        void printQuestions();

signals:

public slots:
    void loadWidget();

};

#endif // TRIVIAAPP_H
