summaryrefslogtreecommitdiff
path: root/utils/themeeditor/projectsettings.cpp
diff options
context:
space:
mode:
authorRobert Bieber <robby@bieberphoto.com>2010-06-14 06:20:07 +0000
committerRobert Bieber <robby@bieberphoto.com>2010-06-14 06:20:07 +0000
commit046832c821276cb07b86519ab3c0dae4ff68173d (patch)
tree39c3177daf1ecfb4bbce17387a1726486e0aab3f /utils/themeeditor/projectsettings.cpp
parent4b0c1cf23bdd3c54296b05ce52f8fec3f29c408e (diff)
downloadrockbox-046832c821276cb07b86519ab3c0dae4ff68173d.zip
rockbox-046832c821276cb07b86519ab3c0dae4ff68173d.tar.gz
rockbox-046832c821276cb07b86519ab3c0dae4ff68173d.tar.bz2
rockbox-046832c821276cb07b86519ab3c0dae4ff68173d.tar.xz
Theme Editor: Stripped out the sub-classes for ProjectModel and turned ProjectModel into a list model, also replaced the project tree view with a list view
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26839 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/themeeditor/projectsettings.cpp')
-rw-r--r--utils/themeeditor/projectsettings.cpp120
1 files changed, 0 insertions, 120 deletions
diff --git a/utils/themeeditor/projectsettings.cpp b/utils/themeeditor/projectsettings.cpp
deleted file mode 100644
index a477f2b..0000000
--- a/utils/themeeditor/projectsettings.cpp
+++ /dev/null
@@ -1,120 +0,0 @@
-/***************************************************************************
- * __________ __ ___.
- * Open \______ \ ____ ____ | | _\_ |__ _______ ___
- * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
- * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
- * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
- * \/ \/ \/ \/ \/
- * $Id$
- *
- * Copyright (C) 2010 Robert Bieber
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- ****************************************************************************/
-
-#include "projectsettings.h"
-
-ProjectSettings::ProjectSettings(QHash<QString, QString>& settings,
- ProjectModel* model, ProjectNode* parent)
- : parentLink(parent)
-{
- QHash<QString, QString>::iterator i;
- for(i = settings.begin(); i != settings.end(); i++)
- {
- QPair<QString, QString> value(i.key(), i.value());
- children.append(new ProjectSetting(value, model, this));
- }
-}
-
-ProjectSettings::~ProjectSettings()
-{
- for(int i = 0; i < children.count(); i++)
- delete children[i];
-}
-
-ProjectNode* ProjectSettings::parent() const
-{
- return parentLink;
-}
-
-ProjectNode* ProjectSettings::child(int row) const
-{
- if(row >= 0 && row < children.count())
- return children[row];
-
- return 0;
-}
-
-int ProjectSettings::numChildren() const
-{
- return children.count();
-}
-
-int ProjectSettings::row() const
-{
- return parentLink->indexOf(const_cast<ProjectSettings*>(this));
-}
-
-QVariant ProjectSettings::data(int column) const
-{
- if(column == 0)
- return QObject::tr("Project Settings");
- else
- return QVariant();
-}
-
-Qt::ItemFlags ProjectSettings::flags(int column) const
-{
- if(column == 0)
- return Qt::ItemIsEnabled | Qt::ItemIsSelectable;
- else
- return 0;
-}
-
-void ProjectSettings::activated()
-{
-
-}
-
-/* Project File functions */
-ProjectSetting::ProjectSetting(QPair<QString, QString> setting,
- ProjectModel* model, ProjectNode* parent)
- :parentLink(parent), setting(setting)
-{
- this->model = model;
-}
-
-ProjectSetting::~ProjectSetting()
-{
-
-}
-
-QVariant ProjectSetting::data(int column) const
-{
- if(column == 0)
- return setting.first;
- else if(column == 1)
- return setting.second;
- else
- return QVariant();
-}
-
-Qt::ItemFlags ProjectSetting::flags(int column) const
-{
- if(column == 0 || column == 1)
- return Qt::ItemIsEnabled | Qt::ItemIsSelectable;
- else
- return 0;
-}
-
-void ProjectSetting::activated()
-{
-}
-