summaryrefslogtreecommitdiffstats
path: root/sigmodr/tree/WeatherGroupModel.cpp
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2009-02-25 01:19:46 -0500
committerBen Boeckel <MathStuf@gmail.com>2009-02-25 01:19:46 -0500
commit8dddfc1ef55773cdf878e413d82142781a6e444b (patch)
tree1fbd160be276c0cc89aa11971d2daab4ecc1791c /sigmodr/tree/WeatherGroupModel.cpp
parent0d38afceb6fe92f1a315c527635522dc6e0346cb (diff)
downloadsigen-8dddfc1ef55773cdf878e413d82142781a6e444b.tar.gz
sigen-8dddfc1ef55773cdf878e413d82142781a6e444b.tar.xz
sigen-8dddfc1ef55773cdf878e413d82142781a6e444b.zip
Renamed from Sigmod to Game in sigmodr tree
Diffstat (limited to 'sigmodr/tree/WeatherGroupModel.cpp')
-rw-r--r--sigmodr/tree/WeatherGroupModel.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/sigmodr/tree/WeatherGroupModel.cpp b/sigmodr/tree/WeatherGroupModel.cpp
index 41aaf70d..73929be6 100644
--- a/sigmodr/tree/WeatherGroupModel.cpp
+++ b/sigmodr/tree/WeatherGroupModel.cpp
@@ -22,17 +22,17 @@
#include "WeatherModel.h"
// Sigmod includes
-#include <sigmod/Sigmod.h>
+#include <sigmod/Game.h>
#include <sigmod/Weather.h>
// KDE includes
#include <KMenu>
-Sigmodr::Tree::WeatherGroupModel::WeatherGroupModel(BaseModel* parent, Sigmod::Sigmod* sigmod) :
- GroupModel(parent, sigmod, "Weathers")
+Sigmodr::Tree::WeatherGroupModel::WeatherGroupModel(BaseModel* parent, Sigmod::Game* game) :
+ GroupModel(parent, game, "Weathers")
{
- for (int i = 0; i < sigmod->weatherCount(); ++i)
- addObject(sigmod->weather(i));
+ for (int i = 0; i < game->weatherCount(); ++i)
+ addObject(game->weather(i));
}
QVariant Sigmodr::Tree::WeatherGroupModel::data(const int role) const
@@ -56,7 +56,7 @@ bool Sigmodr::Tree::WeatherGroupModel::setData(const QVariant& value, int role)
QDomDocument xml;
if (loadFromData(data, &xml) && (xml.doctype().name() == "Weather"))
{
- addObject(qobject_cast<Sigmod::Sigmod*>(m_object)->newWeather(xml.documentElement()));
+ addObject(qobject_cast<Sigmod::Game*>(m_object)->newWeather(xml.documentElement()));
return true;
}
}
@@ -72,7 +72,7 @@ QString Sigmodr::Tree::WeatherGroupModel::types() const
void Sigmodr::Tree::WeatherGroupModel::addObject(Sigmod::Object* object)
{
if (!object)
- object = qobject_cast<Sigmod::Sigmod*>(m_object)->newWeather();
+ object = qobject_cast<Sigmod::Game*>(m_object)->newWeather();
if (object->className() == "Weather")
addChild(new WeatherModel(this, qobject_cast<Sigmod::Weather*>(object)));
}
@@ -82,7 +82,7 @@ void Sigmodr::Tree::WeatherGroupModel::deleteObject(BaseModel* model)
const int index = find(model);
if (0 <= index)
{
- qobject_cast<Sigmod::Sigmod*>(m_object)->deleteWeather(index);
+ qobject_cast<Sigmod::Game*>(m_object)->deleteWeather(index);
m_objects[index]->deleteLater();
m_objects.removeAt(index);
childRowChanged(index);