2013-07-30 10:53:03 +00:00
|
|
|
#ifndef CSV_WORLD_REFERENCECREATOR_H
|
|
|
|
#define CSV_WORLD_REFERENCECREATOR_H
|
|
|
|
|
|
|
|
#include "genericcreator.hpp"
|
|
|
|
|
|
|
|
class QLineEdit;
|
|
|
|
|
|
|
|
namespace CSVWorld
|
|
|
|
{
|
|
|
|
class ReferenceCreator : public GenericCreator
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
QLineEdit *mCell;
|
|
|
|
std::string mId;
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
virtual std::string getId() const;
|
|
|
|
|
|
|
|
virtual void configureCreateCommand (CSMWorld::CreateCommand& command) const;
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
ReferenceCreator (CSMWorld::Data& data, QUndoStack& undoStack,
|
|
|
|
const CSMWorld::UniversalId& id);
|
|
|
|
|
2014-01-27 12:13:39 +00:00
|
|
|
virtual void cloneMode(const std::string& originId,
|
2014-01-27 12:08:14 +00:00
|
|
|
const CSMWorld::UniversalId::Type type);
|
2014-01-27 18:40:05 +00:00
|
|
|
|
2013-07-30 10:53:03 +00:00
|
|
|
virtual void reset();
|
2014-01-23 15:17:04 +00:00
|
|
|
virtual void toggleWidgets(bool active = true);
|
2013-07-30 10:53:03 +00:00
|
|
|
|
|
|
|
virtual std::string getErrors() const;
|
|
|
|
///< Return formatted error descriptions for the current state of the creator. if an empty
|
|
|
|
/// string is returned, there is no error.
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
|
|
|
|
void cellChanged();
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|