#include "widget.h"
#include <QDir>
#include <QGridLayout>
#include <QApplication>
#include "graphicsbutton.h"

Widget::Widget(QWidget *parent)
    : QWidget(parent)
{
    setMinimumSize(800, 600);

    // Create push buttons for starting the executables
    QGridLayout* demosLayout = new QGridLayout;

    GraphicsButton *button = new GraphicsButton("notepad", m_appFolder, "notepad", this);
    demosLayout->addWidget(button, 0, 0);

    button = new GraphicsButton("calc", m_appFolder, "calc", this);
    demosLayout->addWidget(button, 0, 1);

    button = new GraphicsButton("explorer", m_appFolder, "explorer", this);
    demosLayout->addWidget(button, 0, 2);

    button = new GraphicsButton("notepad", m_appFolder, "notepad", this);
    demosLayout->addWidget(button, 1, 0);

    button = new GraphicsButton("calc", m_appFolder, "calc", this);
    demosLayout->addWidget(button, 1, 1);

    button = new GraphicsButton("explorer", m_appFolder, "explorer", this);
    demosLayout->addWidget(button, 1, 2);

    button = new GraphicsButton("notepad", m_appFolder, "notepad", this);
    demosLayout->addWidget(button, 2, 0);

    button = new GraphicsButton("calc", m_appFolder, "calc", this);
    demosLayout->addWidget(button, 2, 1);

    button = new GraphicsButton("explorer", m_appFolder, "explorer", this);
    demosLayout->addWidget(button, 2, 2);

    setLayout(demosLayout);
}

Widget::~Widget()
{
}
