+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include <QtSql>
-#include "emufrontfileobjectmodel.h"
-
-EmuFrontFileObjectModel::EmuFrontFileObjectModel(QObject *parent) :
- EmuFrontQueryModel(parent)
-{ }
-
-Qt::ItemFlags EmuFrontFileObjectModel::flags(const QModelIndex &index) const
-{
- Qt::ItemFlags flags = QSqlQueryModel::flags(index);
- if (index.column() == EmuFrontFileObject_Name) {
- flags |= Qt::ItemIsEditable;
- }
- return flags;
-}
-
-bool EmuFrontFileObjectModel::setData(const QModelIndex &index, const QVariant &value, int /*role*/)
-{
- if(index.column() != EmuFrontFileObject_Name)
- return false;
-
- QModelIndex primaryKeyIndex
- = QSqlQueryModel::index(index.row(), EmuFrontFileObject_Id);
-
- int id = data(primaryKeyIndex).toInt();
- clear();
-
- bool ok;
- if (index.column() == EmuFrontFileObject_Name) {
- ok = setName(id, value.toString());
- }
-
- refresh();
- return ok;
-}
-
-void EmuFrontFileObjectModel::refresh()
- {
- setQuery(constructSelect());
- setHeaderData(EmuFrontFileObject_Id, Qt::Horizontal, tr("ID"));
- setHeaderData(EmuFrontFileObject_Name, Qt::Horizontal, tr("Name"));
- setHeaderData(EmuFrontFileObject_FileId, Qt::Horizontal, tr("FileID"));
- setHeaderData(EmuFrontFileObject_FileName, Qt::Horizontal, tr("File Name"));
- setHeaderData(EmuFrontFileObject_FileCheckSum, Qt::Horizontal, tr("File Checksum"));
- setHeaderData(EmuFrontFileObject_FileSize, Qt::Horizontal, tr("File Size"));
- setHeaderData(EmuFrontFileObject_FileType, Qt::Horizontal, tr("File Type"));
- setHeaderData(EmuFrontFileObject_FileUpdateTime, Qt::Horizontal, tr("File Updated"));
- }
-
-QString EmuFrontFileObjectModel::constructSelect(QString where) const
-{
- return QString("SELECT maintbl.id AS FileObjectId, "
- "maintbl.name AS Name, "
- "file.id AS FileId, "
- "file.name AS FileName, "
- "file.type AS FileType, "
- "file.checksum AS FileChecksum, "
- "file.size AS FileSize, "
- "file.updatetime AS FileUpdateTime "
- "FROM %1 AS maintbl "
- "LEFT OUTER JOIN file ON maintbl.fileid=file.id "
- "%2 "
- "ORDER BY Name").arg(tableName).arg(where);
-}
-
-bool EmuFrontFileObjectModel::setName(int id, const QString &name)
-{
- QSqlQuery query;
- query.prepare(QString("update %1 set name = :name where id = :id").arg(tableName));
- query.bindValue(":name", name);
- query.bindValue(":id", id);
- return query.exec();
-}
-
-bool EmuFrontFileObjectModel::insertRows(int row, int count, const QModelIndex &parent)
-{
- if (parent.isValid())
- return false; // This is a flat model
- if (rowCount() < row)
- row = rowCount() + 1;
- QSqlQuery q;
- q.prepare(QString("INSERT INTO %1 (id, name, fileid) "
- " VALUES (NULL, '', NULL) ").arg(tableName));
- beginInsertRows(QModelIndex(), row, row + count - 1);
- for (int i = 0; i < count; ++i) {
- q.exec();
- }
- endInsertRows();
- refresh();
- return true;
-}
-
-bool EmuFrontFileObjectModel::removeRows(int row, int count, const QModelIndex &parent)
-{
- if (parent.isValid()) {
- return false; // This is a flat model
- }
- if (rowCount() < row + count - 1)
- return false;
-
- QSqlQuery q;
- q.prepare(QString("DELETE FROM %1 WHERE id=:id").arg(tableName));
- QModelIndex primaryIndex;
- int id = -1;
- beginRemoveRows(QModelIndex(), row, row + count - 1);
- for(int i = 0; i < count; ++i) {
- primaryIndex = QSqlQueryModel::index(row + i, EmuFrontFileObject_Id);
- id = data(primaryIndex).toInt();
- qDebug() << "Removing data item with id " << id;
- q.bindValue(":id", id);
- q.exec();
- }
- endRemoveRows();
- refresh();
- return true;
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef EMUFRONTFILEOBJECTMODEL_H
-#define EMUFRONTFILEOBJECTMODEL_H
-
-#include "emufrontquerymodel.h"
-
-class EmuFrontFileObjectModel : public EmuFrontQueryModel
-{
- Q_OBJECT
-public:
- EmuFrontFileObjectModel(QObject *parent = 0);
- virtual Qt::ItemFlags flags(const QModelIndex &index) const;
- virtual bool setData(const QModelIndex &index, const QVariant &value, int role);
- virtual bool insertRows(int row, int count, const QModelIndex &parent);
- virtual bool removeRows(int row, int count, const QModelIndex &parent);
- enum {
- EmuFrontFileObject_Id,
- EmuFrontFileObject_Name,
- EmuFrontFileObject_FileId,
- EmuFrontFileObject_FileName,
- EmuFrontFileObject_FileType,
- EmuFrontFileObject_FileCheckSum,
- EmuFrontFileObject_FileSize,
- EmuFrontFileObject_FileUpdateTime
- };
-
-protected:
- virtual void refresh();
- virtual QString constructSelect(QString where = "") const;
- virtual bool setName(int id, const QString &name);
-};
-
-#endif // EMUFRONTFILEOBJECTMODEL_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include "emufrontquerymodel.h"
-
-EmuFrontQueryModel::EmuFrontQueryModel(QObject *parent) :
- QSqlQueryModel(parent)
-{
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef EMUFRONTQUERYMODEL_H
-#define EMUFRONTQUERYMODEL_H
-
-#include <QSqlQueryModel>
-
-class EmuFrontQueryModel : public QSqlQueryModel
-{
- Q_OBJECT
-public:
- EmuFrontQueryModel(QObject *parent = 0);
-
-signals:
-
-public slots:
-
-protected:
- QString tableName;
-};
-
-#endif // EMUFRONTQUERYMODEL_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include "mediatypemodel.h"
-
-MediaTypeModel::MediaTypeModel(QObject *parent) :
- EmuFrontFileObjectModel(parent)
-{
- tableName = "mediatype";
- refresh();
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef MEDIATYPEMODEL_H
-#define MEDIATYPEMODEL_H
-
-#include "emufrontfileobjectmodel.h"
-
-class MediaTypeModel : public EmuFrontFileObjectModel
-{
- Q_OBJECT
-public:
- MediaTypeModel(QObject *parent = 0);
-};
-
-#endif // MEDIATYPEMODEL_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include "platformmodel.h"
-
-PlatformModel::PlatformModel(QObject *parent) :
- EmuFrontFileObjectModel(parent)
-{
- tableName = "platform";
- refresh();
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef PLATFORMMODEL_H
-#define PLATFORMMODEL_H
-
-#include "emufrontfileobjectmodel.h"
-
-class PlatformModel : public EmuFrontFileObjectModel
-{
- Q_OBJECT
-public:
- PlatformModel(QObject *parent = 0);
-};
-
-#endif // PLATFORMMODEL_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include "setupmodel.h"
-
-SetupModel::SetupModel(QObject *parent) :
- EmuFrontQueryModel(parent)
-{
- refresh();
-}
-
-void SetupModel::refresh()
-{
- setQuery(constructSelect());
- setHeaderData(Setup_Id, Qt::Horizontal, tr("Id"));
- setHeaderData(Setup_PlatformId, Qt::Horizontal, tr("Platform id"));
- setHeaderData(Setup_MediaTypeId, Qt::Horizontal, tr("Media type id"));
- setHeaderData(Setup_FileTypeExtensions, Qt::Horizontal, tr("File types"));
- setHeaderData(Setup_Name, Qt::Horizontal, tr("Name"));
-}
-
-QString SetupModel::constructSelect(QString where) const
-{
- return QString(
- "SELECT setup.id AS SetupId, "
- "setup.platformid AS PlatformId, "
- "setup.mediatypeid AS MediaTypeId, "
- "setup.filetypeextensions AS SupportedFileTypeExtensions, "
- "platform.name || ' ' || mediatype.name AS SetupName "
- "FROM setup "
- "INNER JOIN platform ON setup.platformid=platform.id "
- "INNER JOIN mediatype ON setup.mediatypeid=mediatype.id %1 "
- "ORDER BY SetupName"
- ).arg(where);
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef SETUPMODEL_H
-#define SETUPMODEL_H
-
-#include "emufrontquerymodel.h"
-
-class SetupModel : public EmuFrontQueryModel
-{
- Q_OBJECT
-public:
- SetupModel(QObject *parent = 0);
- enum { Setup_Id = 0,
- Setup_PlatformId,
- Setup_MediaTypeId,
- Setup_FileTypeExtensions,
- Setup_Name };
- static const QString FILE_TYPE_EXTENSION_SEPARATOR;
-
-protected:
- virtual void refresh();
- virtual QString constructSelect(QString where = "") const;
-};
-
-#endif // SETUPMODEL_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include <QtGui>
-#include "emufrontdatadialog.h"
-
-EmuFrontDataDialog::EmuFrontDataDialog(QWidget *parent) :
- EmuFrontDialog(parent)
-{
- editButton = new QPushButton(tr("&Edit"));
- editButton->setEnabled(false);
- addButton = new QPushButton(tr("&Add"));
- deleteButton = new QPushButton(tr("&Delete"));
- deleteButton->setEnabled(false);
- objectList = new QTableView(this);
- buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok, Qt::Vertical);
- buttonBox->addButton(editButton, QDialogButtonBox::ActionRole);
- buttonBox->addButton(addButton, QDialogButtonBox::ActionRole);
- buttonBox->addButton(deleteButton, QDialogButtonBox::ActionRole);
- // this be called from the implementing classes:
- //connectSignals();
- layout();
-}
-
-void EmuFrontDataDialog::postInit()
-{
- connectSignals();
- setHiddenColumns();
- hideColumns();
-}
-
-void EmuFrontDataDialog::layout()
-{
- QHBoxLayout *mainLayout = new QHBoxLayout;
- mainLayout->addWidget(objectList);
- mainLayout->addWidget(buttonBox);
- setLayout(mainLayout);
-}
-
-void EmuFrontDataDialog::hideColumns()
-{
- foreach(int c, hiddenColumns)
- objectList->hideColumn(c);
-}
-
-void EmuFrontDataDialog::connectSignals()
-{
- connect(buttonBox, SIGNAL(accepted()), this, SLOT(accept()));
- connect(objectList, SIGNAL(clicked(const QModelIndex &)),
- this, SLOT(listObjectClicked(const QModelIndex &)));
- connect(editButton, SIGNAL(clicked()), this, SLOT(editButtonClicked()));
- connect(addButton, SIGNAL(clicked()), this, SLOT(addButtonClicked()));
- connect(deleteButton, SIGNAL(clicked()), this, SLOT(deleteButtonClicked()));
-}
-
-void EmuFrontDataDialog::editButtonClicked()
-{
- setButtonsEnabled(false);
- qDebug() << "Edit button clicked";
-}
-
-void EmuFrontDataDialog::deleteButtonClicked()
-{
- setButtonsEnabled(false);
- if (!objectList->currentIndex().isValid())
- return;
- int row = objectList->currentIndex().row();
- if ( !model->removeRows(row, 1) ) {
- errorMessage->showMessage(tr("Failed removing selected item."));
- }
-}
-
-
-void EmuFrontDataDialog::addButtonClicked()
-{
- int row = objectList->currentIndex().isValid() ?
- objectList->currentIndex().row() : 0;
- model->insertRows(row, 1);
- QModelIndex ind = model->index(row, 1);
- if (!ind.isValid()){
- return;
- }
- objectList->setCurrentIndex(ind);
- objectList->edit(ind);
-}
-
-void EmuFrontDataDialog::listObjectClicked(const QModelIndex &index)
-{
- setButtonsEnabled(index.isValid());
-}
-
-void EmuFrontDataDialog::setButtonsEnabled(bool b)
-{
- editButton->setEnabled(b);
- deleteButton->setEnabled(b);
-}
-
-void EmuFrontDataDialog::setHiddenColumns()
-{
- // default implementation
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef EMUFRONTDATADIALOG_H
-#define EMUFRONTDATADIALOG_H
-
-#include "emufrontdialog.h"
-#include "db/emufrontquerymodel.h"
-
-class QDialogButtonBox;
-class QTableView;
-
-class EmuFrontDataDialog : public EmuFrontDialog
-{
- Q_OBJECT
-public:
- EmuFrontDataDialog(QWidget *parent = 0);
-
-private slots:
- void editButtonClicked();
- void addButtonClicked();
- void deleteButtonClicked();
- void listObjectClicked(const QModelIndex &);
-
-protected:
- EmuFrontQueryModel *model;
- QList<int> hiddenColumns;
- QDialogButtonBox *buttonBox;
- QTableView *objectList;
- void postInit();
-
-private:
- QPushButton *editButton;
- QPushButton *addButton;
- QPushButton *deleteButton;
- void layout();
- virtual void setHiddenColumns();
- void hideColumns();
- virtual void connectSignals();
- void setButtonsEnabled(bool);
-
-};
-
-#endif // EMUFRONTDATADIALOG_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include "emufrontfileobjectmaindialog.h"
-#include "db/emufrontfileobjectmodel.h"
-
-EmuFrontFileObjectMainDialog::EmuFrontFileObjectMainDialog(QWidget *parent) :
- EmuFrontDataDialog(parent)
-{
-}
-
-void EmuFrontFileObjectMainDialog::setHiddenColumns()
-{
- hiddenColumns << EmuFrontFileObjectModel::EmuFrontFileObject_Id;
- hiddenColumns << EmuFrontFileObjectModel::EmuFrontFileObject_FileId;
- hiddenColumns << EmuFrontFileObjectModel::EmuFrontFileObject_FileType;
- hiddenColumns << EmuFrontFileObjectModel::EmuFrontFileObject_FileCheckSum;
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef EMUFRONTFILEOBJECTMAINDIALOG_H
-#define EMUFRONTFILEOBJECTMAINDIALOG_H
-
-#include "emufrontdatadialog.h"
-
-class EmuFrontFileObjectMainDialog : public EmuFrontDataDialog
-{
- Q_OBJECT
-public:
- EmuFrontFileObjectMainDialog(QWidget *parent = 0);
-
-private:
- virtual void setHiddenColumns();
-};
-
-#endif // EMUFRONTFILEOBJECTMAINDIALOG_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include <QtGui>
-#include "mediatypemaindialog.h"
-#include "db/mediatypemodel.h"
-
-MediaTypeMainDialog::MediaTypeMainDialog(QWidget *parent) :
- EmuFrontFileObjectMainDialog(parent)
-{
- model = new MediaTypeModel(this);
- objectList->setModel(model);
- postInit();
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef MEDIATYPEMAINDIALOG_H
-#define MEDIATYPEMAINDIALOG_H
-
-#include "emufrontfileobjectmaindialog.h"
-
-class MediaTypeMainDialog : public EmuFrontFileObjectMainDialog
-{
- Q_OBJECT
-public:
- MediaTypeMainDialog(QWidget *parent = 0);
-};
-
-#endif // MEDIATYPEMAINDIALOG_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include <QtGui>
-#include "platformmaindialog.h"
-#include "db/platformmodel.h"
-
-PlatformMainDialog::PlatformMainDialog(QWidget *parent) :
- EmuFrontFileObjectMainDialog(parent)
-{
- model = new PlatformModel(this);
- objectList->setModel(model);
- postInit();
-}
-
-
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef PLATFORMMAINDIALOG_H
-#define PLATFORMMAINDIALOG_H
-
-#include "emufrontfileobjectmaindialog.h"
-
-class PlatformMainDialog : public EmuFrontFileObjectMainDialog
-{
- Q_OBJECT
-public:
- PlatformMainDialog(QWidget *parent = 0);
- };
-
-#endif // PLATFORMMAINDIALOG_H
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#include <QtGui>
-#include "setupmainview.h"
-#include "db/setupmodel.h"
-
-SetupMainView::SetupMainView(QWidget *parent) :
- EmuFrontDataDialog(parent)
-{
- model = new SetupModel(this);
- objectList->setModel(model);
- postInit();
-}
+++ /dev/null
-// EmuFront
-// Copyright 2010 Mikko Keinänen
-//
-// This file is part of EmuFront.
-//
-//
-// EmuFront is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License version 2 as published by
-// the Free Software Foundation and appearing in the file gpl.txt included in the
-// packaging of this file.
-//
-// EmuFront is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with EmuFront. If not, see <http://www.gnu.org/licenses/>.
-
-#ifndef SETUPMAINVIEW_H
-#define SETUPMAINVIEW_H
-
-#include "emufrontdatadialog.h"
-
-class SetupMainView : public EmuFrontDataDialog
-{
- Q_OBJECT
-public:
- SetupMainView(QWidget *parent = 0);
-
-signals:
-
-public slots:
-
-};
-
-#endif // SETUPMAINVIEW_H