1 #ifndef CSV_WORLD_GENERICCREATOR_H
2 #define CSV_WORLD_GENERICCREATOR_H
6 #include "../../model/world/universalid.hpp"
65 virtual std::string
getId()
const;
76 virtual void pushCommand (std::unique_ptr<CSMWorld::CreateCommand> command,
77 const std::string&
id);
92 const QString& tooltip);
101 virtual void reset();
105 virtual void cloneMode(
const std::string& originId,
108 virtual void touch(
const std::vector<CSMWorld::UniversalId>& ids);
114 virtual void setScope (
unsigned int scope);
117 virtual void focus();
Record creator UI base class.
Definition: creator.hpp:21
QUndoStack & getUndoStack()
Definition: genericcreator.cpp:82
virtual std::string getId() const
Definition: genericcreator.cpp:49
virtual void focus()
Focus main input widget.
Definition: genericcreator.cpp:282
virtual void setEditLock(bool locked)
Definition: genericcreator.cpp:187
const CSMWorld::UniversalId & getCollectionId() const
Definition: genericcreator.cpp:87
Definition: commands.hpp:150
Definition: idvalidator.hpp:10
QLabel * mScopeLabel
Definition: genericcreator.hpp:45
virtual void pushCommand(std::unique_ptr< CSMWorld::CreateCommand > command, const std::string &id)
Definition: genericcreator.cpp:71
IdValidator * mValidator
Definition: genericcreator.hpp:46
std::string mClonedId
Definition: genericcreator.hpp:41
CSMWorld::Data & mData
Definition: genericcreator.hpp:32
std::string mErrors
Definition: genericcreator.hpp:38
void insertAtBeginning(QWidget *widget, bool stretched)
Definition: genericcreator.cpp:35
virtual void toggleWidgets(bool active=true)
Definition: genericcreator.cpp:278
unsigned int mScopes
Definition: genericcreator.hpp:43
Type
Definition: universalid.hpp:40
void textChanged(const QString &text)
Definition: genericcreator.cpp:213
bool mLocked
Definition: genericcreator.hpp:40
CSMWorld::Data & getData() const
Definition: genericcreator.cpp:77
void scopeChanged(int index)
Definition: genericcreator.cpp:334
virtual void setManualEditing(bool enabled)
Enable/disable manual ID editing (enabled by default).
Definition: genericcreator.cpp:30
QPushButton * mCancel
Definition: genericcreator.hpp:36
void create()
Definition: genericcreator.cpp:226
QUndoStack & mUndoStack
Definition: genericcreator.hpp:33
virtual void setScope(unsigned int scope)
Default implementation: Throw an exception if scope!=Scope_Content.
Definition: genericcreator.cpp:287
virtual void touch(const std::vector< CSMWorld::UniversalId > &ids)
Touches a record, if the creator supports it.
Definition: genericcreator.cpp:262
QHBoxLayout * mLayout
Definition: genericcreator.hpp:39
Scope
Definition: scope.hpp:8
GenericCreator(CSMWorld::Data &data, QUndoStack &undoStack, const CSMWorld::UniversalId &id, bool relaxedIdRules=false)
Definition: genericcreator.cpp:148
std::string getNamespace() const
Definition: genericcreator.cpp:92
void dataIdListChanged()
Definition: genericcreator.cpp:340
void update()
Definition: genericcreator.cpp:20
QPushButton * mCreate
Definition: genericcreator.hpp:35
Definition: genericcreator.hpp:28
QComboBox * mScope
Definition: genericcreator.hpp:44
void addScope(const QString &name, CSMWorld::Scope scope, const QString &tooltip)
Definition: genericcreator.cpp:141
void updateNamespace()
Definition: genericcreator.cpp:118
virtual std::string getErrors() const
Definition: genericcreator.cpp:201
CSMWorld::UniversalId mListId
Definition: genericcreator.hpp:34
QLineEdit * mId
Definition: genericcreator.hpp:37
virtual void reset()
Definition: genericcreator.cpp:193
std::string getClonedId() const
Definition: genericcreator.cpp:54
virtual void cloneMode(const std::string &originId, const CSMWorld::UniversalId::Type type)
Definition: genericcreator.cpp:254
CSMWorld::UniversalId::Type mClonedType
Definition: genericcreator.hpp:42
void insertBeforeButtons(QWidget *widget, bool stretched)
Insert given widget before Create and Cancel buttons.
Definition: genericcreator.cpp:40
bool mCloneMode
Definition: genericcreator.hpp:49
void inputReturnPressed()
Create record if able to after Return key is pressed on input.
Definition: genericcreator.cpp:218
virtual void configureCreateCommand(CSMWorld::CreateCommand &command) const
Allow subclasses to add additional data to command.
Definition: genericcreator.cpp:69
virtual std::string getIdValidatorResult() const
Definition: genericcreator.cpp:59
const char * name
Definition: crashcatcher.cpp:67
Definition: universalid.hpp:12