Attempt to get basic tablemimedata subclass.

actorid
Marek Kochanowicz 11 years ago
parent a36cc26434
commit dc80bfff55

@ -1 +1,22 @@
#include "tablemimedata.hpp"
#include "universalid.hpp"
CSMWorld::TableMimeData::TableMimeData (CSMWorld::UniversalId& UniversalId) :
mUniversalId(UniversalId)
{
mSupportedFormats << UniversalId.toString().c_str();
}
QStringList CSMWorld::TableMimeData::formats() const
{
return QMimeData::formats();
}
CSMWorld::TableMimeData::~TableMimeData()
{
}
CSMWorld::UniversalId& CSMWorld::TableMimeData::getId()
{
return mUniversalId;
}

@ -1,10 +1,26 @@
/*This class provides way to construct mimedata object holding the reference to the
* universalid. universalid is used in the majority of the tables to store type, id, argument types*/
#ifndef TABLEMIMEDATA_H
#define TABLEMIMEDATA_H
#include <qt4/QtCore/QMimeData>
#include <QVariant>
class TableMimeData : public QMimeData
namespace CSMWorld
{
};
class UniversalId;
class TableMimeData : public QMimeData
{
public:
TableMimeData(UniversalId& UniversalId);
~TableMimeData();
virtual QStringList formats() const;
UniversalId& getId();
private:
QStringList mSupportedFormats;
UniversalId& mUniversalId;
};
}
#endif // TABLEMIMEDATA_H

@ -13,6 +13,7 @@
#include "../../model/world/idtable.hpp"
#include "../../model/world/record.hpp"
#include "../../model/world/columns.hpp"
#include "../../model/world/tablemimedata.hpp"
#include "recordstatusdelegate.hpp"
#include "util.hpp"

Loading…
Cancel
Save