Mark overrided methods by override keyword

pull/3015/head
Andrei Kortunov 4 years ago
parent e5392cabf1
commit 8ca3c3b123

@ -431,6 +431,10 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL GNU OR CMAKE_CXX_COMPILER_ID STREQUAL Clang)
if (CMAKE_CXX_COMPILER_ID STREQUAL GNU AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 4.6 OR CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 4.6)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-but-set-parameter")
endif()
if (CMAKE_CXX_COMPILER_ID STREQUAL GNU AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 5.0 OR CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 5.0)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wsuggest-override")
endif()
elseif (MSVC)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /FORCE:MULTIPLE")
endif (CMAKE_CXX_COMPILER_ID STREQUAL GNU OR CMAKE_CXX_COMPILER_ID STREQUAL Clang)

@ -84,7 +84,7 @@ namespace Launcher
inline bool startProgram(const QString &name, bool detached = false) { return startProgram(name, QStringList(), detached); }
bool startProgram(const QString &name, const QStringList &arguments, bool detached = false);
void closeEvent(QCloseEvent *event);
void closeEvent(QCloseEvent *event) override;
PlayPage *mPlayPage;
GraphicsPage *mGraphicsPage;

@ -27,7 +27,7 @@ public:
LineEdit(QWidget *parent = 0);
protected:
void resizeEvent(QResizeEvent *);
void resizeEvent(QResizeEvent *) override;
private slots:
void updateClearButton(const QString &text);

@ -21,7 +21,7 @@ namespace Launcher
inline LineEdit *lineEdit() { return mLineEdit; }
void setOkButtonEnabled(bool enabled);
int exec();
int exec() override;
private:

@ -22,7 +22,7 @@ class Application : public QApplication
{
private:
bool notify (QObject *receiver, QEvent *event)
bool notify (QObject *receiver, QEvent *event) override
{
try
{

@ -37,10 +37,10 @@ namespace CSMDoc
OpenSaveStage (Document& document, SavingState& state, bool projectFile);
///< \param projectFile Saving the project file instead of the content file.
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -55,10 +55,10 @@ namespace CSMDoc
WriteHeaderStage (Document& document, SavingState& state, bool simple);
///< \param simple Simplified header (used for project files).
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -75,10 +75,10 @@ namespace CSMDoc
WriteCollectionStage (const CollectionT& collection, SavingState& state,
CSMWorld::Scope scope = CSMWorld::Scope_Content);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -125,10 +125,10 @@ namespace CSMDoc
WriteDialogueCollectionStage (Document& document, SavingState& state, bool journal);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -142,10 +142,10 @@ namespace CSMDoc
WriteRefIdCollectionStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -159,10 +159,10 @@ namespace CSMDoc
CollectionReferencesStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -175,10 +175,10 @@ namespace CSMDoc
WriteCellCollectionStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -192,10 +192,10 @@ namespace CSMDoc
WritePathgridCollectionStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -209,10 +209,10 @@ namespace CSMDoc
WriteLandCollectionStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -226,10 +226,10 @@ namespace CSMDoc
WriteLandTextureCollectionStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -241,10 +241,10 @@ namespace CSMDoc
CloseSaveStage (SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -257,10 +257,10 @@ namespace CSMDoc
FinalSavingStage (Document& document, SavingState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, Messages& messages);
void perform (int stage, Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
}

@ -11,8 +11,8 @@ namespace CSMFilter
AndNode (const std::vector<std::shared_ptr<Node> >& nodes);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
};

@ -13,12 +13,12 @@ namespace CSMFilter
BooleanNode (bool true_);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
virtual std::string toString (bool numericColumns) const;
std::string toString (bool numericColumns) const override;
///< Return a string that represents this node.
///
/// \param numericColumns Use numeric IDs instead of string to represent columns.

@ -11,7 +11,7 @@ namespace CSMFilter
{
public:
virtual std::vector<int> getReferencedColumns() const;
std::vector<int> getReferencedColumns() const override;
///< Return a list of the IDs of the columns referenced by this node. The column mapping
/// passed into test as columns must contain all columns listed here.
};

@ -21,11 +21,11 @@ namespace CSMFilter
const Node& operator[] (int index) const;
virtual std::vector<int> getReferencedColumns() const;
std::vector<int> getReferencedColumns() const override;
///< Return a list of the IDs of the columns referenced by this node. The column mapping
/// passed into test as columns must contain all columns listed here.
virtual std::string toString (bool numericColumns) const;
std::string toString (bool numericColumns) const override;
///< Return a string that represents this node.
///
/// \param numericColumns Use numeric IDs instead of string to represent columns.

@ -11,8 +11,8 @@ namespace CSMFilter
NotNode (std::shared_ptr<Node> child);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
};

@ -11,8 +11,8 @@ namespace CSMFilter
OrNode (const std::vector<std::shared_ptr<Node> >& nodes);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
};

@ -14,16 +14,16 @@ namespace CSMFilter
TextNode (int columnId, const std::string& text);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
virtual std::vector<int> getReferencedColumns() const;
std::vector<int> getReferencedColumns() const override;
///< Return a list of the IDs of the columns referenced by this node. The column mapping
/// passed into test as columns must contain all columns listed here.
virtual std::string toString (bool numericColumns) const;
std::string toString (bool numericColumns) const override;
///< Return a string that represents this node.
///
/// \param numericColumns Use numeric IDs instead of string to represent columns.

@ -18,11 +18,11 @@ namespace CSMFilter
Node& getChild();
virtual std::vector<int> getReferencedColumns() const;
std::vector<int> getReferencedColumns() const override;
///< Return a list of the IDs of the columns referenced by this node. The column mapping
/// passed into test as columns must contain all columns listed here.
virtual std::string toString (bool numericColumns) const;
std::string toString (bool numericColumns) const override;
///< Return a string that represents this node.
///
/// \param numericColumns Use numeric IDs instead of string to represent columns.

@ -27,16 +27,16 @@ namespace CSMFilter
ValueNode (int columnId, Type lowerType, Type upperType, double lower, double upper);
virtual bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const;
bool test (const CSMWorld::IdTableBase& table, int row,
const std::map<int, int>& columns) const override;
///< \return Can the specified table row pass through to filter?
/// \param columns column ID to column index mapping
virtual std::vector<int> getReferencedColumns() const;
std::vector<int> getReferencedColumns() const override;
///< Return a list of the IDs of the columns referenced by this node. The column mapping
/// passed into test as columns must contain all columns listed here.
virtual std::string toString (bool numericColumns) const;
std::string toString (bool numericColumns) const override;
///< Return a string that represents this node.
///
/// \param numericColumns Use numeric IDs instead of string to represent columns.

@ -23,9 +23,9 @@ namespace CSMPrefs
BoolSetting& setTooltip (const std::string& tooltip);
/// Return label, input widget.
virtual std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent);
std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent) override;
virtual void updateWidget();
void updateWidget() override;
private slots:

@ -29,9 +29,9 @@ namespace CSMPrefs
ColourSetting& setTooltip (const std::string& tooltip);
/// Return label, input widget.
virtual std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent);
std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent) override;
virtual void updateWidget();
void updateWidget() override;
private slots:

@ -36,9 +36,9 @@ namespace CSMPrefs
DoubleSetting& setTooltip (const std::string& tooltip);
/// Return label, input widget.
virtual std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent);
std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent) override;
virtual void updateWidget();
void updateWidget() override;
private slots:

@ -54,9 +54,9 @@ namespace CSMPrefs
EnumSetting& addValue (const std::string& value, const std::string& tooltip);
/// Return label, input widget.
virtual std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent);
std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent) override;
virtual void updateWidget();
void updateWidget() override;
private slots:

@ -32,9 +32,9 @@ namespace CSMPrefs
IntSetting& setTooltip (const std::string& tooltip);
/// Return label, input widget.
virtual std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent);
std::pair<QWidget *, QWidget *> makeWidgets (QWidget *parent) override;
virtual void updateWidget();
void updateWidget() override;
private slots:

@ -19,13 +19,13 @@ namespace CSMPrefs
ModifierSetting(Category* parent, Settings::Manager* values, QMutex* mutex, const std::string& key,
const std::string& label);
virtual std::pair<QWidget*, QWidget*> makeWidgets(QWidget* parent);
std::pair<QWidget*, QWidget*> makeWidgets(QWidget* parent) override;
virtual void updateWidget();
void updateWidget() override;
protected:
bool eventFilter(QObject* target, QEvent* event);
bool eventFilter(QObject* target, QEvent* event) override;
private:

@ -27,7 +27,7 @@ namespace CSMPrefs
protected:
bool eventFilter(QObject* watched, QEvent* event);
bool eventFilter(QObject* watched, QEvent* event) override;
private:

@ -19,13 +19,13 @@ namespace CSMPrefs
ShortcutSetting(Category* parent, Settings::Manager* values, QMutex* mutex, const std::string& key,
const std::string& label);
virtual std::pair<QWidget*, QWidget*> makeWidgets(QWidget* parent);
std::pair<QWidget*, QWidget*> makeWidgets(QWidget* parent) override;
virtual void updateWidget();
void updateWidget() override;
protected:
bool eventFilter(QObject* target, QEvent* event);
bool eventFilter(QObject* target, QEvent* event) override;
private:

@ -22,10 +22,10 @@ namespace CSMTools
BirthsignCheckStage (const CSMWorld::IdCollection<ESM::BirthSign> &birthsigns,
const CSMWorld::Resources &textures);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -25,10 +25,10 @@ namespace CSMTools
const CSMWorld::Resources &meshes,
const CSMWorld::IdCollection<ESM::Race> &races );
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform( int stage, CSMDoc::Messages &messages );
void perform(int stage, CSMDoc::Messages &messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -19,10 +19,10 @@ namespace CSMTools
ClassCheckStage (const CSMWorld::IdCollection<ESM::Class>& classes);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -19,10 +19,10 @@ namespace CSMTools
EnchantmentCheckStage (const CSMWorld::IdCollection<ESM::Enchantment>& enchantments);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};

@ -19,10 +19,10 @@ namespace CSMTools
FactionCheckStage (const CSMWorld::IdCollection<ESM::Faction>& factions);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -16,10 +16,10 @@ namespace CSMTools
GmstCheckStage(const CSMWorld::IdCollection<ESM::GameSetting>& gameSettings);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform(int stage, CSMDoc::Messages& messages);
void perform(int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages
private:

@ -18,10 +18,10 @@ namespace CSMTools
JournalCheckStage(const CSMWorld::IdCollection<ESM::Dialogue>& journals,
const CSMWorld::InfoCollection& journalInfos);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform(int stage, CSMDoc::Messages& messages);
void perform(int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages
private:

@ -32,9 +32,9 @@ namespace CSMTools
const CSMWorld::Resources &icons,
const CSMWorld::Resources &textures);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages &messages);
void perform (int stage, CSMDoc::Messages &messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -27,10 +27,10 @@ namespace CSMTools
MandatoryIdStage (const CSMWorld::CollectionBase& idCollection, const CSMWorld::UniversalId& collectionId,
const std::vector<std::string>& ids);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -31,7 +31,7 @@ namespace CSMTools
protected slots:
virtual void operationDone();
void operationDone() override;
signals:

@ -22,10 +22,10 @@ namespace CSMTools
StartMergeStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -38,10 +38,10 @@ namespace CSMTools
FinishMergedDocumentStage (MergeState& state, ToUTF8::FromType encoding);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -55,10 +55,10 @@ namespace CSMTools
MergeIdCollectionStage (MergeState& state, Collection& (CSMWorld::Data::*accessor)());
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -93,10 +93,10 @@ namespace CSMTools
MergeRefIdsStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -109,10 +109,10 @@ namespace CSMTools
MergeReferencesStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -125,10 +125,10 @@ namespace CSMTools
PopulateLandTexturesMergeStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -140,10 +140,10 @@ namespace CSMTools
MergeLandStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -157,10 +157,10 @@ namespace CSMTools
FixLandsAndLandTexturesMergeStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
@ -174,10 +174,10 @@ namespace CSMTools
CleanupLandTexturesMergeStage (MergeState& state);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
}

@ -32,9 +32,9 @@ namespace CSMTools
PathgridCheckStage (const CSMWorld::SubCellCollection<CSMWorld::Pathgrid,
CSMWorld::IdAccessor<CSMWorld::Pathgrid> >& pathgrids);
virtual int setup();
int setup() override;
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
};
}

@ -24,10 +24,10 @@ namespace CSMTools
RaceCheckStage (const CSMWorld::IdCollection<ESM::Race>& races);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -22,8 +22,8 @@ namespace CSMTools
const CSMWorld::Resources& icons,
const CSMWorld::IdCollection<ESM::BodyPart>& bodyparts);
virtual void perform(int stage, CSMDoc::Messages& messages);
virtual int setup();
void perform(int stage, CSMDoc::Messages& messages) override;
int setup() override;
private:
//CONCRETE CHECKS

@ -14,8 +14,8 @@ namespace CSMTools
const CSMWorld::IdCollection<CSMWorld::Cell>& cells,
const CSMWorld::IdCollection<ESM::Faction>& factions);
virtual void perform(int stage, CSMDoc::Messages& messages);
virtual int setup();
void perform(int stage, CSMDoc::Messages& messages) override;
int setup() override;
private:
const CSMWorld::RefCollection& mReferences;

@ -19,10 +19,10 @@ namespace CSMTools
RegionCheckStage (const CSMWorld::IdCollection<ESM::Region>& regions);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -33,15 +33,15 @@ namespace CSMTools
ReportModel (bool fieldColumn = false, bool severityColumn = true);
virtual int rowCount (const QModelIndex & parent = QModelIndex()) const;
int rowCount (const QModelIndex & parent = QModelIndex()) const override;
virtual int columnCount (const QModelIndex & parent = QModelIndex()) const;
int columnCount (const QModelIndex & parent = QModelIndex()) const override;
virtual QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const;
QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const override;
virtual QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override;
virtual bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex());
bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex()) override;
void add (const CSMDoc::Message& message);

@ -36,20 +36,20 @@ namespace CSMTools
CSMDoc::Message::Severity getSeverity (Type type);
virtual void report (const std::string& message, const Compiler::TokenLoc& loc, Type type);
void report (const std::string& message, const Compiler::TokenLoc& loc, Type type) override;
///< Report error to the user.
virtual void report (const std::string& message, Type type);
void report (const std::string& message, Type type) override;
///< Report a file related error
public:
ScriptCheckStage (const CSMDoc::Document& document);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -24,10 +24,10 @@ namespace CSMTools
SearchStage (const CSMWorld::IdTableBase *model);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages.
void setOperation (const SearchOperation *operation);

@ -19,10 +19,10 @@ namespace CSMTools
SkillCheckStage (const CSMWorld::IdCollection<ESM::Skill>& skills);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -22,10 +22,10 @@ namespace CSMTools
SoundCheckStage (const CSMWorld::IdCollection<ESM::Sound>& sounds,
const CSMWorld::Resources &soundfiles);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -20,10 +20,10 @@ namespace CSMTools
const CSMWorld::IdCollection<ESM::Sound> &sounds,
const CSMWorld::RefIdCollection &objects);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform(int stage, CSMDoc::Messages &messages);
void perform(int stage, CSMDoc::Messages &messages) override;
///< Messages resulting from this stage will be appended to \a messages.
};
}

@ -19,10 +19,10 @@ namespace CSMTools
SpellCheckStage (const CSMWorld::IdCollection<ESM::Spell>& spells);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform (int stage, CSMDoc::Messages& messages);
void perform (int stage, CSMDoc::Messages& messages) override;
///< Messages resulting from this tage will be appended to \a messages.
};
}

@ -21,8 +21,8 @@ namespace CSMTools
StartScriptCheckStage (const CSMWorld::IdCollection<ESM::StartScript>& startScripts,
const CSMWorld::IdCollection<ESM::Script>& scripts);
virtual void perform(int stage, CSMDoc::Messages& messages);
virtual int setup();
void perform(int stage, CSMDoc::Messages& messages) override;
int setup() override;
};
}

@ -40,10 +40,10 @@ namespace CSMTools
const CSMWorld::RefIdData& referencables,
const CSMWorld::Resources& soundFiles);
virtual int setup();
int setup() override;
///< \return number of steps
virtual void perform(int step, CSMDoc::Messages& messages);
void perform(int step, CSMDoc::Messages& messages) override;
///< Messages resulting from this stage will be appended to \a messages
private:

@ -120,19 +120,19 @@ namespace CSMWorld
void add (const ESXRecordT& record);
///< Add a new record (modified)
virtual int getSize() const;
int getSize() const override;
virtual std::string getId (int index) const;
std::string getId (int index) const override;
virtual int getIndex (const std::string& id) const;
int getIndex (const std::string& id) const override;
virtual int getColumns() const;
int getColumns() const override;
virtual QVariant getData (int index, int column) const;
QVariant getData (int index, int column) const override;
virtual void setData (int index, int column, const QVariant& data);
void setData (int index, int column, const QVariant& data) override;
virtual const ColumnBase& getColumn (int column) const;
const ColumnBase& getColumn (int column) const override;
virtual void merge();
///< Merge modified into base.
@ -140,43 +140,43 @@ namespace CSMWorld
virtual void purge();
///< Remove records that are flagged as erased.
virtual void removeRows (int index, int count) ;
void removeRows (int index, int count) override;
virtual void appendBlankRecord (const std::string& id,
UniversalId::Type type = UniversalId::Type_None);
void appendBlankRecord (const std::string& id,
UniversalId::Type type = UniversalId::Type_None) override;
///< \param type Will be ignored, unless the collection supports multiple record types
virtual void cloneRecord(const std::string& origin,
void cloneRecord(const std::string& origin,
const std::string& destination,
const UniversalId::Type type);
const UniversalId::Type type) override;
virtual bool touchRecord(const std::string& id);
bool touchRecord(const std::string& id) override;
///< Change the state of a record from base to modified, if it is not already.
/// \return True if the record was changed.
virtual int searchId (const std::string& id) const;
int searchId (const std::string& id) const override;
////< Search record with \a id.
/// \return index of record (if found) or -1 (not found)
virtual void replace (int index, const RecordBase& record);
void replace (int index, const RecordBase& record) override;
///< If the record type does not match, an exception is thrown.
///
/// \attention \a record must not change the ID.
virtual void appendRecord (const RecordBase& record,
UniversalId::Type type = UniversalId::Type_None);
void appendRecord (const RecordBase& record,
UniversalId::Type type = UniversalId::Type_None) override;
///< If the record type does not match, an exception is thrown.
///< \param type Will be ignored, unless the collection supports multiple record types
virtual const Record<ESXRecordT>& getRecord (const std::string& id) const;
const Record<ESXRecordT>& getRecord (const std::string& id) const override;
virtual const Record<ESXRecordT>& getRecord (int index) const;
const Record<ESXRecordT>& getRecord (int index) const override;
virtual int getAppendIndex (const std::string& id,
UniversalId::Type type = UniversalId::Type_None) const;
int getAppendIndex (const std::string& id,
UniversalId::Type type = UniversalId::Type_None) const override;
///< \param type Will be ignored, unless the collection supports multiple record types
virtual std::vector<std::string> getIds (bool listDeleted = true) const;
std::vector<std::string> getIds (bool listDeleted = true) const override;
///< Return a sorted collection of all IDs
///
/// \param listDeleted include deleted record in the list
@ -190,7 +190,7 @@ namespace CSMWorld
/// If the index is invalid either generally (by being out of range) or for the particular
/// record, an exception is thrown.
virtual bool reorderRows (int baseIndex, const std::vector<int>& newOrder);
bool reorderRows (int baseIndex, const std::vector<int>& newOrder) override;
///< Reorder the rows [baseIndex, baseIndex+newOrder.size()) according to the indices
/// given in \a newOrder (baseIndex+newOrder[0] specifies the new index of row baseIndex).
///

@ -211,13 +211,13 @@ namespace CSMWorld
: Column<ESXRecordT> (id, ColumnBase::Display_NestedHeader, flags), mFixedRows(fixedRows)
{}
virtual void set (Record<ESXRecordT>& record, const QVariant& data)
void set (Record<ESXRecordT>& record, const QVariant& data) override
{
// There is nothing to do here.
// This prevents exceptions from parent's implementation
}
virtual QVariant get (const Record<ESXRecordT>& record) const
QVariant get (const Record<ESXRecordT>& record) const override
{
// by default editable; also see IdTree::hasChildren()
if (mFixedRows)
@ -226,7 +226,7 @@ namespace CSMWorld
return QVariant::fromValue(ColumnBase::TableEdit_Full);
}
virtual bool isEditable() const
bool isEditable() const override
{
return true;
}
@ -240,7 +240,7 @@ namespace CSMWorld
NestedChildColumn (int id,
Display display, int flags = ColumnBase::Flag_Dialogue, bool isEditable = true);
virtual bool isEditable() const;
bool isEditable() const override;
private:
bool mIsEditable;

File diff suppressed because it is too large Load Diff

@ -142,9 +142,9 @@ namespace CSMWorld
ModifyCommand (QAbstractItemModel& model, const QModelIndex& index, const QVariant& new_,
QUndoCommand *parent = 0);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class CreateCommand : public QUndoCommand
@ -175,9 +175,9 @@ namespace CSMWorld
void addNestedValue(int parentColumn, int nestedColumn, const QVariant &value);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class CloneCommand : public CreateCommand
@ -191,9 +191,9 @@ namespace CSMWorld
const UniversalId::Type type,
QUndoCommand* parent = 0);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class RevertCommand : public QUndoCommand
@ -212,9 +212,9 @@ namespace CSMWorld
virtual ~RevertCommand();
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class DeleteCommand : public QUndoCommand
@ -235,9 +235,9 @@ namespace CSMWorld
virtual ~DeleteCommand();
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class ReorderRowsCommand : public QUndoCommand
@ -250,9 +250,9 @@ namespace CSMWorld
ReorderRowsCommand (IdTable& model, int baseIndex, const std::vector<int>& newOrder);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class CreatePathgridCommand : public CreateCommand
@ -261,7 +261,7 @@ namespace CSMWorld
CreatePathgridCommand(IdTable& model, const std::string& id, QUndoCommand *parent = 0);
virtual void redo();
void redo() override;
};
/// \brief Update cell ID according to x/y-coordinates
@ -281,9 +281,9 @@ namespace CSMWorld
UpdateCellCommand (IdTable& model, int row, QUndoCommand *parent = 0);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
@ -318,9 +318,9 @@ namespace CSMWorld
DeleteNestedCommand (IdTree& model, const std::string& id, int nestedRow, int parentColumn, QUndoCommand* parent = 0);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
class AddNestedCommand : public QUndoCommand, private NestedTableStoring
@ -340,9 +340,9 @@ namespace CSMWorld
AddNestedCommand(IdTree& model, const std::string& id, int nestedRow, int parentColumn, QUndoCommand* parent = 0);
virtual void redo();
void redo() override;
virtual void undo();
void undo() override;
};
}

@ -31,24 +31,23 @@ namespace CSMWorld
virtual ~IdTable();
virtual int rowCount (const QModelIndex & parent = QModelIndex()) const;
int rowCount (const QModelIndex & parent = QModelIndex()) const override;
virtual int columnCount (const QModelIndex & parent = QModelIndex()) const;
int columnCount (const QModelIndex & parent = QModelIndex()) const override;
virtual QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const;
QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const override;
virtual QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override;
virtual bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole) override;
virtual Qt::ItemFlags flags (const QModelIndex & index) const;
Qt::ItemFlags flags (const QModelIndex & index) const override;
virtual bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex());
bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex()) override;
virtual QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex())
const;
QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex()) const override;
virtual QModelIndex parent (const QModelIndex& index) const;
QModelIndex parent (const QModelIndex& index) const override;
void addRecord (const std::string& id, UniversalId::Type type = UniversalId::Type_None);
///< \param type Will be ignored, unless the collection supports multiple record types
@ -66,7 +65,7 @@ namespace CSMWorld
std::string getId(int row) const;
virtual QModelIndex getModelIndex (const std::string& id, int column) const;
QModelIndex getModelIndex (const std::string& id, int column) const override;
void setRecord (const std::string& id, const RecordBase& record,
UniversalId::Type type = UniversalId::Type_None);
@ -74,10 +73,10 @@ namespace CSMWorld
const RecordBase& getRecord (const std::string& id) const;
virtual int searchColumnIndex (Columns::ColumnId id) const;
int searchColumnIndex (Columns::ColumnId id) const override;
///< Return index of column with the given \a id. If no such column exists, -1 is returned.
virtual int findColumnIndex (Columns::ColumnId id) const;
int findColumnIndex (Columns::ColumnId id) const override;
///< Return index of column with the given \a id. If no such column exists, an exception is
/// thrown.
@ -85,14 +84,14 @@ namespace CSMWorld
///< Reorder the rows [baseIndex, baseIndex+newOrder.size()) according to the indices
/// given in \a newOrder (baseIndex+newOrder[0] specifies the new index of row baseIndex).
virtual std::pair<UniversalId, std::string> view (int row) const;
std::pair<UniversalId, std::string> view (int row) const override;
///< Return the UniversalId and the hint for viewing \a row. If viewing is not
/// supported by this table, return (UniversalId::Type_None, "").
/// Is \a id flagged as deleted?
virtual bool isDeleted (const std::string& id) const;
bool isDeleted (const std::string& id) const override;
virtual int getColumnId(int column) const;
int getColumnId(int column) const override;
protected:

@ -39,7 +39,7 @@ namespace CSMWorld
virtual QModelIndex getModelIndex (const std::string& id, int column) const;
virtual void setSourceModel(QAbstractItemModel *model);
void setSourceModel(QAbstractItemModel *model) override;
void setFilter (const std::shared_ptr<CSMFilter::Node>& filter);
@ -47,9 +47,9 @@ namespace CSMWorld
protected:
virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const;
bool lessThan(const QModelIndex &left, const QModelIndex &right) const override;
virtual bool filterAcceptsRow (int sourceRow, const QModelIndex& sourceParent) const;
bool filterAcceptsRow (int sourceRow, const QModelIndex& sourceParent) const override;
QString getRecordId(int sourceRow) const;

@ -44,22 +44,21 @@ namespace CSMWorld
virtual ~IdTree();
virtual int rowCount (const QModelIndex & parent = QModelIndex()) const;
int rowCount (const QModelIndex & parent = QModelIndex()) const override;
virtual int columnCount (const QModelIndex & parent = QModelIndex()) const;
int columnCount (const QModelIndex & parent = QModelIndex()) const override;
virtual QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const;
QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const override;
virtual bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole) override;
virtual Qt::ItemFlags flags (const QModelIndex & index) const;
Qt::ItemFlags flags (const QModelIndex & index) const override;
virtual bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex());
bool removeRows (int row, int count, const QModelIndex& parent = QModelIndex()) override;
virtual QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex())
const;
QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex()) const override;
virtual QModelIndex parent (const QModelIndex& index) const;
QModelIndex parent (const QModelIndex& index) const override;
QModelIndex getNestedModelIndex (const std::string& id, int column) const;
@ -71,7 +70,7 @@ namespace CSMWorld
void addNestedRow (const QModelIndex& parent, int position);
virtual bool hasChildren (const QModelIndex& index) const;
bool hasChildren (const QModelIndex& index) const override;
virtual int searchNestedColumnIndex(int parentColumn, Columns::ColumnId id);
///< \return the column index or -1 if the requested column wasn't found.

@ -29,11 +29,11 @@ namespace CSMWorld
public:
virtual int getAppendIndex (const std::string& id,
UniversalId::Type type = UniversalId::Type_None) const;
int getAppendIndex (const std::string& id,
UniversalId::Type type = UniversalId::Type_None) const override;
///< \param type Will be ignored, unless the collection supports multiple record types
virtual bool reorderRows (int baseIndex, const std::vector<int>& newOrder);
bool reorderRows (int baseIndex, const std::vector<int>& newOrder) override;
///< Reorder the rows [baseIndex, baseIndex+newOrder.size()) according to the indices
/// given in \a newOrder (baseIndex+newOrder[0] specifies the new index of row baseIndex).
///

@ -30,15 +30,15 @@ namespace CSMWorld
public:
InfoTableProxyModel(UniversalId::Type type, QObject *parent = 0);
virtual void setSourceModel(QAbstractItemModel *sourceModel);
void setSourceModel(QAbstractItemModel *sourceModel) override;
protected:
virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const;
bool lessThan(const QModelIndex &left, const QModelIndex &right) const override;
protected slots:
virtual void sourceRowsInserted(const QModelIndex &parent, int start, int end);
virtual void sourceRowsRemoved(const QModelIndex &parent, int start, int end);
virtual void sourceDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight);
void sourceRowsInserted(const QModelIndex &parent, int start, int end) override;
void sourceRowsRemoved(const QModelIndex &parent, int start, int end) override;
void sourceDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight) override;
};
}

@ -30,24 +30,24 @@ namespace CSMWorld
public:
PathgridPointListAdapter ();
virtual void addRow(Record<Pathgrid>& record, int position) const;
void addRow(Record<Pathgrid>& record, int position) const override;
virtual void removeRow(Record<Pathgrid>& record, int rowToRemove) const;
void removeRow(Record<Pathgrid>& record, int rowToRemove) const override;
virtual void setTable(Record<Pathgrid>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<Pathgrid>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<Pathgrid>& record) const;
NestedTableWrapperBase* table(const Record<Pathgrid>& record) const override;
virtual QVariant getData(const Record<Pathgrid>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<Pathgrid>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<Pathgrid>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<Pathgrid>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<Pathgrid>& record) const;
int getColumnsCount(const Record<Pathgrid>& record) const override;
virtual int getRowsCount(const Record<Pathgrid>& record) const;
int getRowsCount(const Record<Pathgrid>& record) const override;
};
class PathgridEdgeListAdapter : public NestedColumnAdapter<Pathgrid>
@ -55,24 +55,24 @@ namespace CSMWorld
public:
PathgridEdgeListAdapter ();
virtual void addRow(Record<Pathgrid>& record, int position) const;
void addRow(Record<Pathgrid>& record, int position) const override;
virtual void removeRow(Record<Pathgrid>& record, int rowToRemove) const;
void removeRow(Record<Pathgrid>& record, int rowToRemove) const override;
virtual void setTable(Record<Pathgrid>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<Pathgrid>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<Pathgrid>& record) const;
NestedTableWrapperBase* table(const Record<Pathgrid>& record) const override;
virtual QVariant getData(const Record<Pathgrid>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<Pathgrid>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<Pathgrid>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<Pathgrid>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<Pathgrid>& record) const;
int getColumnsCount(const Record<Pathgrid>& record) const override;
virtual int getRowsCount(const Record<Pathgrid>& record) const;
int getRowsCount(const Record<Pathgrid>& record) const override;
};
class FactionReactionsAdapter : public NestedColumnAdapter<ESM::Faction>
@ -80,24 +80,24 @@ namespace CSMWorld
public:
FactionReactionsAdapter ();
virtual void addRow(Record<ESM::Faction>& record, int position) const;
void addRow(Record<ESM::Faction>& record, int position) const override;
virtual void removeRow(Record<ESM::Faction>& record, int rowToRemove) const;
void removeRow(Record<ESM::Faction>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Faction>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Faction>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Faction>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Faction>& record) const override;
virtual QVariant getData(const Record<ESM::Faction>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Faction>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Faction>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Faction>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Faction>& record) const;
int getColumnsCount(const Record<ESM::Faction>& record) const override;
virtual int getRowsCount(const Record<ESM::Faction>& record) const;
int getRowsCount(const Record<ESM::Faction>& record) const override;
};
class FactionRanksAdapter : public NestedColumnAdapter<ESM::Faction>
@ -105,24 +105,24 @@ namespace CSMWorld
public:
FactionRanksAdapter ();
virtual void addRow(Record<ESM::Faction>& record, int position) const;
void addRow(Record<ESM::Faction>& record, int position) const override;
virtual void removeRow(Record<ESM::Faction>& record, int rowToRemove) const;
void removeRow(Record<ESM::Faction>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Faction>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Faction>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Faction>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Faction>& record) const override;
virtual QVariant getData(const Record<ESM::Faction>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Faction>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Faction>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Faction>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Faction>& record) const;
int getColumnsCount(const Record<ESM::Faction>& record) const override;
virtual int getRowsCount(const Record<ESM::Faction>& record) const;
int getRowsCount(const Record<ESM::Faction>& record) const override;
};
class RegionSoundListAdapter : public NestedColumnAdapter<ESM::Region>
@ -130,24 +130,24 @@ namespace CSMWorld
public:
RegionSoundListAdapter ();
virtual void addRow(Record<ESM::Region>& record, int position) const;
void addRow(Record<ESM::Region>& record, int position) const override;
virtual void removeRow(Record<ESM::Region>& record, int rowToRemove) const;
void removeRow(Record<ESM::Region>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Region>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Region>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Region>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Region>& record) const override;
virtual QVariant getData(const Record<ESM::Region>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Region>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Region>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Region>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Region>& record) const;
int getColumnsCount(const Record<ESM::Region>& record) const override;
virtual int getRowsCount(const Record<ESM::Region>& record) const;
int getRowsCount(const Record<ESM::Region>& record) const override;
};
template<typename ESXRecordT>
@ -156,7 +156,7 @@ namespace CSMWorld
public:
SpellListAdapter () {}
virtual void addRow(Record<ESXRecordT>& record, int position) const
void addRow(Record<ESXRecordT>& record, int position) const override
{
ESXRecordT raceOrBthSgn = record.get();
@ -170,7 +170,7 @@ namespace CSMWorld
record.setModified (raceOrBthSgn);
}
virtual void removeRow(Record<ESXRecordT>& record, int rowToRemove) const
void removeRow(Record<ESXRecordT>& record, int rowToRemove) const override
{
ESXRecordT raceOrBthSgn = record.get();
@ -184,7 +184,7 @@ namespace CSMWorld
record.setModified (raceOrBthSgn);
}
virtual void setTable(Record<ESXRecordT>& record, const NestedTableWrapperBase& nestedTable) const
void setTable(Record<ESXRecordT>& record, const NestedTableWrapperBase& nestedTable) const override
{
ESXRecordT raceOrBthSgn = record.get();
@ -194,13 +194,13 @@ namespace CSMWorld
record.setModified (raceOrBthSgn);
}
virtual NestedTableWrapperBase* table(const Record<ESXRecordT>& record) const
NestedTableWrapperBase* table(const Record<ESXRecordT>& record) const override
{
// deleted by dtor of NestedTableStoring
return new NestedTableWrapper<std::vector<std::string> >(record.get().mPowers.mList);
}
virtual QVariant getData(const Record<ESXRecordT>& record, int subRowIndex, int subColIndex) const
QVariant getData(const Record<ESXRecordT>& record, int subRowIndex, int subColIndex) const override
{
ESXRecordT raceOrBthSgn = record.get();
@ -217,8 +217,8 @@ namespace CSMWorld
}
}
virtual void setData(Record<ESXRecordT>& record, const QVariant& value,
int subRowIndex, int subColIndex) const
void setData(Record<ESXRecordT>& record, const QVariant& value,
int subRowIndex, int subColIndex) const override
{
ESXRecordT raceOrBthSgn = record.get();
@ -239,12 +239,12 @@ namespace CSMWorld
record.setModified (raceOrBthSgn);
}
virtual int getColumnsCount(const Record<ESXRecordT>& record) const
int getColumnsCount(const Record<ESXRecordT>& record) const override
{
return 1;
}
virtual int getRowsCount(const Record<ESXRecordT>& record) const
int getRowsCount(const Record<ESXRecordT>& record) const override
{
return static_cast<int>(record.get().mPowers.mList.size());
}
@ -256,7 +256,7 @@ namespace CSMWorld
public:
EffectsListAdapter () {}
virtual void addRow(Record<ESXRecordT>& record, int position) const
void addRow(Record<ESXRecordT>& record, int position) const override
{
ESXRecordT magic = record.get();
@ -278,7 +278,7 @@ namespace CSMWorld
record.setModified (magic);
}
virtual void removeRow(Record<ESXRecordT>& record, int rowToRemove) const
void removeRow(Record<ESXRecordT>& record, int rowToRemove) const override
{
ESXRecordT magic = record.get();
@ -292,7 +292,7 @@ namespace CSMWorld
record.setModified (magic);
}
virtual void setTable(Record<ESXRecordT>& record, const NestedTableWrapperBase& nestedTable) const
void setTable(Record<ESXRecordT>& record, const NestedTableWrapperBase& nestedTable) const override
{
ESXRecordT magic = record.get();
@ -302,13 +302,13 @@ namespace CSMWorld
record.setModified (magic);
}
virtual NestedTableWrapperBase* table(const Record<ESXRecordT>& record) const
NestedTableWrapperBase* table(const Record<ESXRecordT>& record) const override
{
// deleted by dtor of NestedTableStoring
return new NestedTableWrapper<std::vector<ESM::ENAMstruct> >(record.get().mEffects.mList);
}
virtual QVariant getData(const Record<ESXRecordT>& record, int subRowIndex, int subColIndex) const
QVariant getData(const Record<ESXRecordT>& record, int subRowIndex, int subColIndex) const override
{
ESXRecordT magic = record.get();
@ -370,8 +370,8 @@ namespace CSMWorld
}
}
virtual void setData(Record<ESXRecordT>& record, const QVariant& value,
int subRowIndex, int subColIndex) const
void setData(Record<ESXRecordT>& record, const QVariant& value,
int subRowIndex, int subColIndex) const override
{
ESXRecordT magic = record.get();
@ -415,12 +415,12 @@ namespace CSMWorld
record.setModified (magic);
}
virtual int getColumnsCount(const Record<ESXRecordT>& record) const
int getColumnsCount(const Record<ESXRecordT>& record) const override
{
return 8;
}
virtual int getRowsCount(const Record<ESXRecordT>& record) const
int getRowsCount(const Record<ESXRecordT>& record) const override
{
return static_cast<int>(record.get().mEffects.mList.size());
}
@ -431,24 +431,24 @@ namespace CSMWorld
public:
InfoListAdapter ();
virtual void addRow(Record<Info>& record, int position) const;
void addRow(Record<Info>& record, int position) const override;
virtual void removeRow(Record<Info>& record, int rowToRemove) const;
void removeRow(Record<Info>& record, int rowToRemove) const override;
virtual void setTable(Record<Info>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<Info>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<Info>& record) const;
NestedTableWrapperBase* table(const Record<Info>& record) const override;
virtual QVariant getData(const Record<Info>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<Info>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<Info>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<Info>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<Info>& record) const;
int getColumnsCount(const Record<Info>& record) const override;
virtual int getRowsCount(const Record<Info>& record) const;
int getRowsCount(const Record<Info>& record) const override;
};
class InfoConditionAdapter : public NestedColumnAdapter<Info>
@ -456,24 +456,24 @@ namespace CSMWorld
public:
InfoConditionAdapter ();
virtual void addRow(Record<Info>& record, int position) const;
void addRow(Record<Info>& record, int position) const override;
virtual void removeRow(Record<Info>& record, int rowToRemove) const;
void removeRow(Record<Info>& record, int rowToRemove) const override;
virtual void setTable(Record<Info>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<Info>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<Info>& record) const;
NestedTableWrapperBase* table(const Record<Info>& record) const override;
virtual QVariant getData(const Record<Info>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<Info>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<Info>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<Info>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<Info>& record) const;
int getColumnsCount(const Record<Info>& record) const override;
virtual int getRowsCount(const Record<Info>& record) const;
int getRowsCount(const Record<Info>& record) const override;
};
class RaceAttributeAdapter : public NestedColumnAdapter<ESM::Race>
@ -481,24 +481,24 @@ namespace CSMWorld
public:
RaceAttributeAdapter ();
virtual void addRow(Record<ESM::Race>& record, int position) const;
void addRow(Record<ESM::Race>& record, int position) const override;
virtual void removeRow(Record<ESM::Race>& record, int rowToRemove) const;
void removeRow(Record<ESM::Race>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Race>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Race>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Race>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Race>& record) const override;
virtual QVariant getData(const Record<ESM::Race>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Race>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Race>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Race>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Race>& record) const;
int getColumnsCount(const Record<ESM::Race>& record) const override;
virtual int getRowsCount(const Record<ESM::Race>& record) const;
int getRowsCount(const Record<ESM::Race>& record) const override;
};
class RaceSkillsBonusAdapter : public NestedColumnAdapter<ESM::Race>
@ -506,24 +506,24 @@ namespace CSMWorld
public:
RaceSkillsBonusAdapter ();
virtual void addRow(Record<ESM::Race>& record, int position) const;
void addRow(Record<ESM::Race>& record, int position) const override;
virtual void removeRow(Record<ESM::Race>& record, int rowToRemove) const;
void removeRow(Record<ESM::Race>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Race>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Race>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Race>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Race>& record) const override;
virtual QVariant getData(const Record<ESM::Race>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Race>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Race>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Race>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Race>& record) const;
int getColumnsCount(const Record<ESM::Race>& record) const override;
virtual int getRowsCount(const Record<ESM::Race>& record) const;
int getRowsCount(const Record<ESM::Race>& record) const override;
};
class CellListAdapter : public NestedColumnAdapter<CSMWorld::Cell>
@ -531,24 +531,24 @@ namespace CSMWorld
public:
CellListAdapter ();
virtual void addRow(Record<CSMWorld::Cell>& record, int position) const;
void addRow(Record<CSMWorld::Cell>& record, int position) const override;
virtual void removeRow(Record<CSMWorld::Cell>& record, int rowToRemove) const;
void removeRow(Record<CSMWorld::Cell>& record, int rowToRemove) const override;
virtual void setTable(Record<CSMWorld::Cell>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<CSMWorld::Cell>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<CSMWorld::Cell>& record) const;
NestedTableWrapperBase* table(const Record<CSMWorld::Cell>& record) const override;
virtual QVariant getData(const Record<CSMWorld::Cell>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<CSMWorld::Cell>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<CSMWorld::Cell>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<CSMWorld::Cell>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<CSMWorld::Cell>& record) const;
int getColumnsCount(const Record<CSMWorld::Cell>& record) const override;
virtual int getRowsCount(const Record<CSMWorld::Cell>& record) const;
int getRowsCount(const Record<CSMWorld::Cell>& record) const override;
};
class RegionWeatherAdapter : public NestedColumnAdapter<ESM::Region>
@ -556,24 +556,24 @@ namespace CSMWorld
public:
RegionWeatherAdapter ();
virtual void addRow(Record<ESM::Region>& record, int position) const;
void addRow(Record<ESM::Region>& record, int position) const override;
virtual void removeRow(Record<ESM::Region>& record, int rowToRemove) const;
void removeRow(Record<ESM::Region>& record, int rowToRemove) const override;
virtual void setTable(Record<ESM::Region>& record,
const NestedTableWrapperBase& nestedTable) const;
void setTable(Record<ESM::Region>& record,
const NestedTableWrapperBase& nestedTable) const override;
virtual NestedTableWrapperBase* table(const Record<ESM::Region>& record) const;
NestedTableWrapperBase* table(const Record<ESM::Region>& record) const override;
virtual QVariant getData(const Record<ESM::Region>& record,
int subRowIndex, int subColIndex) const;
QVariant getData(const Record<ESM::Region>& record,
int subRowIndex, int subColIndex) const override;
virtual void setData(Record<ESM::Region>& record,
const QVariant& value, int subRowIndex, int subColIndex) const;
void setData(Record<ESM::Region>& record,
const QVariant& value, int subRowIndex, int subColIndex) const override;
virtual int getColumnsCount(const Record<ESM::Region>& record) const;
int getColumnsCount(const Record<ESM::Region>& record) const override;
virtual int getRowsCount(const Record<ESM::Region>& record) const;
int getRowsCount(const Record<ESM::Region>& record) const override;
};
}

@ -32,24 +32,24 @@ namespace CSMWorld
NestedIdCollection ();
~NestedIdCollection();
virtual void addNestedRow(int row, int column, int position);
void addNestedRow(int row, int column, int position) override;
virtual void removeNestedRows(int row, int column, int subRow);
void removeNestedRows(int row, int column, int subRow) override;
virtual QVariant getNestedData(int row, int column, int subRow, int subColumn) const;
QVariant getNestedData(int row, int column, int subRow, int subColumn) const override;
virtual void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn);
void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn) override;
virtual NestedTableWrapperBase* nestedTable(int row, int column) const;
NestedTableWrapperBase* nestedTable(int row, int column) const override;
virtual void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable);
void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable) override;
virtual int getNestedRowsCount(int row, int column) const;
int getNestedRowsCount(int row, int column) const override;
virtual int getNestedColumnsCount(int row, int column) const;
int getNestedColumnsCount(int row, int column) const override;
// this method is inherited from NestedCollection, not from Collection<ESXRecordT>
virtual NestableColumn *getNestableColumn(int column);
NestableColumn *getNestableColumn(int column) override;
void addAdapter(std::pair<const ColumnBase*, NestedColumnAdapter<ESXRecordT>* > adapter);
};

@ -24,24 +24,24 @@ namespace CSMWorld
NestedInfoCollection ();
~NestedInfoCollection();
virtual void addNestedRow(int row, int column, int position);
void addNestedRow(int row, int column, int position) override;
virtual void removeNestedRows(int row, int column, int subRow);
void removeNestedRows(int row, int column, int subRow) override;
virtual QVariant getNestedData(int row, int column, int subRow, int subColumn) const;
QVariant getNestedData(int row, int column, int subRow, int subColumn) const override;
virtual void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn);
void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn) override;
virtual NestedTableWrapperBase* nestedTable(int row, int column) const;
NestedTableWrapperBase* nestedTable(int row, int column) const override;
virtual void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable);
void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable) override;
virtual int getNestedRowsCount(int row, int column) const;
int getNestedRowsCount(int row, int column) const override;
virtual int getNestedColumnsCount(int row, int column) const;
int getNestedColumnsCount(int row, int column) const override;
// this method is inherited from NestedCollection, not from Collection<Info, IdAccessor<Info> >
virtual NestableColumn *getNestableColumn(int column);
NestableColumn *getNestableColumn(int column) override;
void addAdapter(std::pair<const ColumnBase*, NestedColumnAdapter<Info>* > adapter);
};

@ -39,25 +39,25 @@ namespace CSMWorld
CSMWorld::IdTree* model() const;
virtual QModelIndex mapFromSource(const QModelIndex& sourceIndex) const;
QModelIndex mapFromSource(const QModelIndex& sourceIndex) const override;
virtual QModelIndex mapToSource(const QModelIndex& proxyIndex) const;
QModelIndex mapToSource(const QModelIndex& proxyIndex) const override;
virtual int rowCount(const QModelIndex& parent) const;
int rowCount(const QModelIndex& parent) const override;
virtual int columnCount(const QModelIndex& parent) const;
int columnCount(const QModelIndex& parent) const override;
virtual QModelIndex index(int row, int column, const QModelIndex& parent = QModelIndex()) const;
QModelIndex index(int row, int column, const QModelIndex& parent = QModelIndex()) const override;
virtual QModelIndex parent(const QModelIndex& index) const;
QModelIndex parent(const QModelIndex& index) const override;
virtual QVariant headerData (int section, Qt::Orientation orientation, int role) const;
QVariant headerData (int section, Qt::Orientation orientation, int role) const override;
virtual QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const;
QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const override;
virtual bool setData (const QModelIndex & index, const QVariant & value, int role = Qt::EditRole);
bool setData (const QModelIndex & index, const QVariant & value, int role = Qt::EditRole) override;
virtual Qt::ItemFlags flags(const QModelIndex& index) const;
Qt::ItemFlags flags(const QModelIndex& index) const override;
private:
void setupHeaderVectors(ColumnBase::Display columnId);

@ -22,7 +22,7 @@ namespace CSMWorld
virtual ~NestedTableWrapper() {}
virtual int size() const
int size() const override
{
return mNestedTable.size(); //i hope that this will be enough
}

@ -45,11 +45,11 @@ namespace CSMWorld
Record(State state,
const ESXRecordT *base = 0, const ESXRecordT *modified = 0);
virtual RecordBase *clone() const;
RecordBase *clone() const override;
virtual RecordBase *modifiedCopy() const;
RecordBase *modifiedCopy() const override;
virtual void assign (const RecordBase& record);
void assign (const RecordBase& record) override;
const ESXRecordT& get() const;
///< Throws an exception, if the record is deleted.

File diff suppressed because it is too large Load Diff

@ -32,9 +32,9 @@ namespace CSMWorld
int flag = Flag_Table | Flag_Dialogue, bool editable = true,
bool userEditable = true);
virtual bool isEditable() const;
bool isEditable() const override;
virtual bool isUserEditable() const;
bool isUserEditable() const override;
};
class RefIdCollection : public CollectionBase, public NestedCollection
@ -60,82 +60,82 @@ namespace CSMWorld
virtual ~RefIdCollection();
virtual int getSize() const;
int getSize() const override;
virtual std::string getId (int index) const;
std::string getId (int index) const override;
virtual int getIndex (const std::string& id) const;
int getIndex (const std::string& id) const override;
virtual int getColumns() const;
int getColumns() const override;
virtual const ColumnBase& getColumn (int column) const;
const ColumnBase& getColumn (int column) const override;
virtual QVariant getData (int index, int column) const;
QVariant getData (int index, int column) const override;
virtual void setData (int index, int column, const QVariant& data);
void setData (int index, int column, const QVariant& data) override;
virtual void removeRows (int index, int count);
void removeRows (int index, int count) override;
virtual void cloneRecord(const std::string& origin,
void cloneRecord(const std::string& origin,
const std::string& destination,
const UniversalId::Type type);
const UniversalId::Type type) override;
virtual bool touchRecord(const std::string& id);
bool touchRecord(const std::string& id) override;
virtual void appendBlankRecord (const std::string& id, UniversalId::Type type);
void appendBlankRecord (const std::string& id, UniversalId::Type type) override;
///< \param type Will be ignored, unless the collection supports multiple record types
virtual int searchId (const std::string& id) const;
int searchId (const std::string& id) const override;
////< Search record with \a id.
/// \return index of record (if found) or -1 (not found)
virtual void replace (int index, const RecordBase& record);
void replace (int index, const RecordBase& record) override;
///< If the record type does not match, an exception is thrown.
///
/// \attention \a record must not change the ID.
virtual void appendRecord (const RecordBase& record, UniversalId::Type type);
void appendRecord (const RecordBase& record, UniversalId::Type type) override;
///< If the record type does not match, an exception is thrown.
///
///< \param type Will be ignored, unless the collection supports multiple record types
virtual const RecordBase& getRecord (const std::string& id) const;
const RecordBase& getRecord (const std::string& id) const override;
virtual const RecordBase& getRecord (int index) const;
const RecordBase& getRecord (int index) const override;
void load (ESM::ESMReader& reader, bool base, UniversalId::Type type);
virtual int getAppendIndex (const std::string& id, UniversalId::Type type) const;
int getAppendIndex (const std::string& id, UniversalId::Type type) const override;
///< \param type Will be ignored, unless the collection supports multiple record types
virtual std::vector<std::string> getIds (bool listDeleted) const;
std::vector<std::string> getIds (bool listDeleted) const override;
///< Return a sorted collection of all IDs
///
/// \param listDeleted include deleted record in the list
virtual bool reorderRows (int baseIndex, const std::vector<int>& newOrder);
bool reorderRows (int baseIndex, const std::vector<int>& newOrder) override;
///< Reorder the rows [baseIndex, baseIndex+newOrder.size()) according to the indices
/// given in \a newOrder (baseIndex+newOrder[0] specifies the new index of row baseIndex).
///
/// \return Success?
virtual QVariant getNestedData(int row, int column, int subRow, int subColumn) const;
QVariant getNestedData(int row, int column, int subRow, int subColumn) const override;
virtual NestedTableWrapperBase* nestedTable(int row, int column) const;
NestedTableWrapperBase* nestedTable(int row, int column) const override;
virtual void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable);
void setNestedTable(int row, int column, const NestedTableWrapperBase& nestedTable) override;
virtual int getNestedRowsCount(int row, int column) const;
int getNestedRowsCount(int row, int column) const override;
virtual int getNestedColumnsCount(int row, int column) const;
int getNestedColumnsCount(int row, int column) const override;
NestableColumn *getNestableColumn(int column);
NestableColumn *getNestableColumn(int column) override;
virtual void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn);
void setNestedData(int row, int column, const QVariant& data, int subRow, int subColumn) override;
virtual void removeNestedRows(int row, int column, int subRow);
void removeNestedRows(int row, int column, int subRow) override;
virtual void addNestedRow(int row, int col, int position);
void addNestedRow(int row, int col, int position) override;
void save (int index, ESM::ESMWriter& writer) const;

@ -66,24 +66,24 @@ namespace CSMWorld
{
std::vector<Record<RecordT> > mContainer;
virtual int getSize() const;
int getSize() const override;
virtual const RecordBase& getRecord (int index) const;
const RecordBase& getRecord (int index) const override;
virtual RecordBase& getRecord (int index);
RecordBase& getRecord (int index) override;
virtual void appendRecord (const std::string& id, bool base);
void appendRecord (const std::string& id, bool base) override;
virtual void insertRecord (RecordBase& record);
void insertRecord (RecordBase& record) override;
virtual int load (ESM::ESMReader& reader, bool base);
int load (ESM::ESMReader& reader, bool base) override;
///< \return index of a loaded record or -1 if no record was loaded
virtual void erase (int index, int count);
void erase (int index, int count) override;
virtual std::string getId (int index) const;
std::string getId (int index) const override;
virtual void save (int index, ESM::ESMWriter& writer) const;
void save (int index, ESM::ESMWriter& writer) const override;
};
template<typename RecordT>

@ -91,15 +91,15 @@ namespace CSMWorld
RegionMap (Data& data);
virtual int rowCount (const QModelIndex& parent = QModelIndex()) const;
int rowCount (const QModelIndex& parent = QModelIndex()) const override;
virtual int columnCount (const QModelIndex& parent = QModelIndex()) const;
int columnCount (const QModelIndex& parent = QModelIndex()) const override;
virtual QVariant data (const QModelIndex& index, int role = Qt::DisplayRole) const;
QVariant data (const QModelIndex& index, int role = Qt::DisplayRole) const override;
///< \note Calling this function with role==Role_CellId may return the ID of a cell
/// that does not exist.
virtual Qt::ItemFlags flags (const QModelIndex& index) const;
Qt::ItemFlags flags (const QModelIndex& index) const override;
private slots:

@ -18,41 +18,40 @@ namespace CSMWorld
virtual ~ResourceTable();
virtual int rowCount (const QModelIndex & parent = QModelIndex()) const;
int rowCount (const QModelIndex & parent = QModelIndex()) const override;
virtual int columnCount (const QModelIndex & parent = QModelIndex()) const;
int columnCount (const QModelIndex & parent = QModelIndex()) const override;
virtual QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const;
QVariant data (const QModelIndex & index, int role = Qt::DisplayRole) const override;
virtual QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override;
virtual bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
bool setData ( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole) override;
virtual Qt::ItemFlags flags (const QModelIndex & index) const;
Qt::ItemFlags flags (const QModelIndex & index) const override;
virtual QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex())
const;
QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex()) const override;
virtual QModelIndex parent (const QModelIndex& index) const;
QModelIndex parent (const QModelIndex& index) const override;
virtual QModelIndex getModelIndex (const std::string& id, int column) const;
QModelIndex getModelIndex (const std::string& id, int column) const override;
/// Return index of column with the given \a id. If no such column exists, -1 is
/// returned.
virtual int searchColumnIndex (Columns::ColumnId id) const;
int searchColumnIndex (Columns::ColumnId id) const override;
/// Return index of column with the given \a id. If no such column exists, an
/// exception is thrown.
virtual int findColumnIndex (Columns::ColumnId id) const;
int findColumnIndex (Columns::ColumnId id) const override;
/// Return the UniversalId and the hint for viewing \a row. If viewing is not
/// supported by this table, return (UniversalId::Type_None, "").
virtual std::pair<UniversalId, std::string> view (int row) const;
std::pair<UniversalId, std::string> view (int row) const override;
/// Is \a id flagged as deleted?
virtual bool isDeleted (const std::string& id) const;
bool isDeleted (const std::string& id) const override;
virtual int getColumnId (int column) const;
int getColumnId (int column) const override;
/// Signal Qt that the data is about to change.
void beginReset();

@ -23,23 +23,23 @@ namespace CSMWorld
ScriptContext (const Data& data);
virtual bool canDeclareLocals() const;
bool canDeclareLocals() const override;
///< Is the compiler allowed to declare local variables?
virtual char getGlobalType (const std::string& name) const;
char getGlobalType (const std::string& name) const override;
///< 'l: long, 's': short, 'f': float, ' ': does not exist.
virtual std::pair<char, bool> getMemberType (const std::string& name,
const std::string& id) const;
std::pair<char, bool> getMemberType (const std::string& name,
const std::string& id) const override;
///< Return type of member variable \a name in script \a id or in script of reference of
/// \a id
/// \return first: 'l: long, 's': short, 'f': float, ' ': does not exist.
/// second: true: script of reference
virtual bool isId (const std::string& name) const;
bool isId (const std::string& name) const override;
///< Does \a name match an ID, that can be referenced?
virtual bool isJournalId (const std::string& name) const;
bool isJournalId (const std::string& name) const override;
///< Does \a name match a journal ID?
void invalidateIds();

@ -20,7 +20,7 @@ namespace CSMWorld
{
const IdCollection<Cell>& mCells;
virtual void loadRecord (ESXRecordT& record, ESM::ESMReader& reader, bool& isDeleted);
void loadRecord (ESXRecordT& record, ESM::ESMReader& reader, bool& isDeleted) override;
public:

@ -36,7 +36,7 @@ namespace CSMWorld
~TableMimeData();
virtual QStringList formats() const;
QStringList formats() const override;
std::string getIcon() const;

@ -38,7 +38,7 @@ namespace CSVDoc
private:
void closeEvent (QCloseEvent *event);
void closeEvent (QCloseEvent *event) override;
public:

@ -44,7 +44,7 @@ namespace CSVDoc
void create();
void reject();
void reject() override;
};
}

@ -13,7 +13,7 @@ namespace CSVDoc
RunLogSubView (const CSMWorld::UniversalId& id, CSMDoc::Document& document);
virtual void setEditLock (bool locked);
void setEditLock (bool locked) override;
};
}

@ -14,7 +14,7 @@ namespace CSVDoc
SizeHintWidget(QWidget *parent = 0);
~SizeHintWidget();
virtual QSize sizeHint() const;
QSize sizeHint() const override;
void setSizeHint(const QSize &size);
};
}

@ -34,7 +34,7 @@ namespace CSVDoc
void setUniversalId(const CSMWorld::UniversalId& id);
bool event (QEvent *event);
bool event (QEvent *event) override;
public:
@ -54,7 +54,7 @@ namespace CSVDoc
private:
void closeEvent (QCloseEvent *event);
void closeEvent (QCloseEvent *event) override;
signals:

@ -12,7 +12,7 @@ namespace CSVDoc
{
public:
virtual CSVDoc::SubView *makeSubView (const CSMWorld::UniversalId& id, CSMDoc::Document& document);
CSVDoc::SubView *makeSubView (const CSMWorld::UniversalId& id, CSMDoc::Document& document) override;
};
template<class SubViewT>
@ -32,7 +32,7 @@ namespace CSVDoc
SubViewFactoryWithCreator (bool sorting = true);
virtual CSVDoc::SubView *makeSubView (const CSMWorld::UniversalId& id, CSMDoc::Document& document);
CSVDoc::SubView *makeSubView (const CSMWorld::UniversalId& id, CSMDoc::Document& document) override;
};
template<class SubViewT, class CreatorFactoryT>

@ -64,7 +64,7 @@ namespace CSVDoc
private:
void closeEvent (QCloseEvent *event);
void closeEvent (QCloseEvent *event) override;
QAction* createMenuEntry(CSMWorld::UniversalId::Type type, QMenu* menu, const char* shortcutName);
QAction* createMenuEntry(const std::string& title, const std::string& iconName, QMenu* menu, const char* shortcutName);

@ -34,11 +34,11 @@ namespace CSVFilter
private:
void dragEnterEvent (QDragEnterEvent* event);
void dragEnterEvent (QDragEnterEvent* event) override;
void dropEvent (QDropEvent* event);
void dropEvent (QDropEvent* event) override;
void dragMoveEvent(QDragMoveEvent *event);
void dragMoveEvent(QDragMoveEvent *event) override;
signals:
void recordFilterChanged (std::shared_ptr<CSMFilter::Node> filter);

@ -18,9 +18,9 @@ namespace CSVPrefs
protected:
void contextMenuEvent(QContextMenuEvent* e);
void contextMenuEvent(QContextMenuEvent* e) override;
void mousePressEvent(QMouseEvent* e);
void mousePressEvent(QMouseEvent* e) override;
private slots:

@ -34,7 +34,7 @@ namespace CSVPrefs
protected:
void closeEvent (QCloseEvent *event);
void closeEvent (QCloseEvent *event) override;
public slots:

@ -26,7 +26,7 @@ namespace CSVPrefs
protected:
void contextMenuEvent(QContextMenuEvent*);
void contextMenuEvent(QContextMenuEvent*) override;
private slots:

@ -96,10 +96,10 @@ namespace CSVRender
void fixUpAxis(const osg::Vec3d& up);
void unfixUpAxis();
void handleMouseMoveEvent(int x, int y);
void handleMouseScrollEvent(int x);
void handleMouseMoveEvent(int x, int y) override;
void handleMouseScrollEvent(int x) override;
void update(double dt);
void update(double dt) override;
private:
@ -152,10 +152,10 @@ namespace CSVRender
void setOrbitSpeedMultiplier(double value);
void setPickingMask(unsigned int value);
void handleMouseMoveEvent(int x, int y);
void handleMouseScrollEvent(int x);
void handleMouseMoveEvent(int x, int y) override;
void handleMouseScrollEvent(int x) override;
void update(double dt);
void update(double dt) override;
/// \brief Flag controller to be re-initialized.
void reset();

@ -45,7 +45,7 @@ namespace CSVRender
{
public:
virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
void operator()(osg::Node* node, osg::NodeVisitor* nv) override
{
traverse(node, nv);
CellNodeContainer* container = static_cast<CellNodeContainer*>(node->getUserData());

@ -27,7 +27,7 @@ namespace CSVRender
CellArrow *getCellArrow() const;
virtual QString getToolTip (bool hideBasics) const;
QString getToolTip (bool hideBasics) const override;
};

@ -34,7 +34,7 @@ namespace CSVRender
unsigned int getInteractionMask() const;
virtual void activate (CSVWidget::SceneToolbar *toolbar);
void activate (CSVWidget::SceneToolbar *toolbar) override;
/// Default-implementation: Ignored.
virtual void setEditLock (bool locked);
@ -90,15 +90,15 @@ namespace CSVRender
virtual void dragWheel (int diff, double speedFactor);
/// Default-implementation: ignored
virtual void dragEnterEvent (QDragEnterEvent *event);
void dragEnterEvent (QDragEnterEvent *event) override;
/// Default-implementation: ignored
virtual void dropEvent (QDropEvent *event);
void dropEvent (QDropEvent *event) override;
/// Default-implementation: ignored
virtual void dragMoveEvent (QDragMoveEvent *event);
void dragMoveEvent (QDragMoveEvent *event) override;
virtual void mouseMoveEvent (QMouseEvent *event);
void mouseMoveEvent (QMouseEvent *event) override;
/// Default: return -1
virtual int getSubMode() const;

@ -64,41 +64,41 @@ namespace CSVRender
InstanceMode (WorldspaceWidget *worldspaceWidget, osg::ref_ptr<osg::Group> parentNode, QWidget *parent = 0);
virtual void activate (CSVWidget::SceneToolbar *toolbar);
void activate (CSVWidget::SceneToolbar *toolbar) override;
virtual void deactivate (CSVWidget::SceneToolbar *toolbar);
void deactivate (CSVWidget::SceneToolbar *toolbar) override;
virtual void setEditLock (bool locked);
void setEditLock (bool locked) override;
virtual void primaryOpenPressed (const WorldspaceHitResult& hit);
void primaryOpenPressed (const WorldspaceHitResult& hit) override;
virtual void primaryEditPressed (const WorldspaceHitResult& hit);
void primaryEditPressed (const WorldspaceHitResult& hit) override;
virtual void secondaryEditPressed (const WorldspaceHitResult& hit);
void secondaryEditPressed (const WorldspaceHitResult& hit) override;
virtual void primarySelectPressed (const WorldspaceHitResult& hit);
void primarySelectPressed (const WorldspaceHitResult& hit) override;
virtual void secondarySelectPressed (const WorldspaceHitResult& hit);
void secondarySelectPressed (const WorldspaceHitResult& hit) override;
virtual bool primaryEditStartDrag (const QPoint& pos);
bool primaryEditStartDrag (const QPoint& pos) override;
virtual bool secondaryEditStartDrag (const QPoint& pos);
bool secondaryEditStartDrag (const QPoint& pos) override;
virtual void drag (const QPoint& pos, int diffX, int diffY, double speedFactor);
void drag (const QPoint& pos, int diffX, int diffY, double speedFactor) override;
virtual void dragCompleted(const QPoint& pos);
void dragCompleted(const QPoint& pos) override;
/// \note dragAborted will not be called, if the drag is aborted via changing
/// editing mode
virtual void dragAborted();
void dragAborted() override;
virtual void dragWheel (int diff, double speedFactor);
void dragWheel (int diff, double speedFactor) override;
virtual void dragEnterEvent (QDragEnterEvent *event);
void dragEnterEvent (QDragEnterEvent *event) override;
virtual void dropEvent (QDropEvent *event);
void dropEvent (QDropEvent *event) override;
virtual int getSubMode() const;
int getSubMode() const override;
signals:

@ -21,7 +21,7 @@ namespace CSVRender
///
/// \return Have there been any menu items to be added (if menu is 0 and there
/// items to be added, the function must return true anyway.
bool createContextMenu(QMenu* menu);
bool createContextMenu(QMenu* menu) override;
private:

@ -14,7 +14,7 @@ public:
, mIndex(index)
{ }
virtual void apply(osg::Switch &switchNode)
void apply(osg::Switch &switchNode) override
{
if (switchNode.getName() == Constants::NightDayLabel)
switchNode.setSingleChildOn(mIndex);

@ -17,11 +17,11 @@ namespace CSVRender
LightingBright();
virtual void activate (osg::Group* rootNode, bool /*isExterior*/);
void activate (osg::Group* rootNode, bool /*isExterior*/) override;
virtual void deactivate();
void deactivate() override;
virtual osg::Vec4f getAmbientColour(osg::Vec4f* defaultAmbient);
osg::Vec4f getAmbientColour(osg::Vec4f* defaultAmbient) override;
};
}

@ -11,11 +11,11 @@ namespace CSVRender
LightingDay();
virtual void activate (osg::Group* rootNode, bool /*isExterior*/);
void activate (osg::Group* rootNode, bool /*isExterior*/) override;
virtual void deactivate();
void deactivate() override;
virtual osg::Vec4f getAmbientColour(osg::Vec4f *defaultAmbient);
osg::Vec4f getAmbientColour(osg::Vec4f *defaultAmbient) override;
};
}

@ -11,10 +11,10 @@ namespace CSVRender
LightingNight();
virtual void activate (osg::Group* rootNode, bool isExterior);
virtual void deactivate();
void activate (osg::Group* rootNode, bool isExterior) override;
void deactivate() override;
virtual osg::Vec4f getAmbientColour(osg::Vec4f *defaultAmbient);
osg::Vec4f getAmbientColour(osg::Vec4f *defaultAmbient) override;
};
}

@ -54,7 +54,7 @@ namespace CSVRender
Object* mObject;
virtual QString getToolTip (bool hideBasics) const;
QString getToolTip (bool hideBasics) const override;
};
class ObjectMarkerTag : public ObjectTag

@ -24,9 +24,9 @@ namespace CSVRender
QWidget* parent = nullptr);
~OrbitCameraMode();
virtual void activate(CSVWidget::SceneToolbar* toolbar);
virtual void deactivate(CSVWidget::SceneToolbar* toolbar);
virtual bool createContextMenu(QMenu* menu);
void activate(CSVWidget::SceneToolbar* toolbar) override;
void deactivate(CSVWidget::SceneToolbar* toolbar) override;
bool createContextMenu(QMenu* menu) override;
private:

@ -39,26 +39,26 @@ namespace CSVRender
/// \return Any cells added or removed?
bool adjustCells();
virtual void referenceableDataChanged (const QModelIndex& topLeft,
const QModelIndex& bottomRight);
void referenceableDataChanged (const QModelIndex& topLeft,
const QModelIndex& bottomRight) override;
virtual void referenceableAboutToBeRemoved (const QModelIndex& parent, int start, int end);
void referenceableAboutToBeRemoved (const QModelIndex& parent, int start, int end) override;
virtual void referenceableAdded (const QModelIndex& index, int start, int end);
void referenceableAdded (const QModelIndex& index, int start, int end) override;
virtual void referenceDataChanged (const QModelIndex& topLeft, const QModelIndex& bottomRight);
void referenceDataChanged (const QModelIndex& topLeft, const QModelIndex& bottomRight) override;
virtual void referenceAboutToBeRemoved (const QModelIndex& parent, int start, int end);
void referenceAboutToBeRemoved (const QModelIndex& parent, int start, int end) override;
virtual void referenceAdded (const QModelIndex& index, int start, int end);
void referenceAdded (const QModelIndex& index, int start, int end) override;
virtual void pathgridDataChanged (const QModelIndex& topLeft, const QModelIndex& bottomRight);
void pathgridDataChanged (const QModelIndex& topLeft, const QModelIndex& bottomRight) override;
virtual void pathgridAboutToBeRemoved (const QModelIndex& parent, int start, int end);
void pathgridAboutToBeRemoved (const QModelIndex& parent, int start, int end) override;
virtual void pathgridAdded (const QModelIndex& parent, int start, int end);
void pathgridAdded (const QModelIndex& parent, int start, int end) override;
virtual std::string getStartupInstruction();
std::string getStartupInstruction() override;
/// \note Does not update the view or any cell marker
void addCellToScene (const CSMWorld::CellCoordinates& coordinates);
@ -86,45 +86,45 @@ namespace CSVRender
virtual ~PagedWorldspaceWidget();
/// Decodes the the hint string to set of cell that are rendered.
void useViewHint (const std::string& hint);
void useViewHint (const std::string& hint) override;
void setCellSelection(const CSMWorld::CellSelection& selection);
const CSMWorld::CellSelection& getCellSelection() const;
/// \return Drop handled?
virtual bool handleDrop (const std::vector<CSMWorld::UniversalId>& data,
DropType type);
bool handleDrop (const std::vector<CSMWorld::UniversalId>& data,
DropType type) override;
virtual dropRequirments getDropRequirements(DropType type) const;
dropRequirments getDropRequirements(DropType type) const override;
/// \attention The created tool is not added to the toolbar (via addTool). Doing
/// that is the responsibility of the calling function.
virtual CSVWidget::SceneToolToggle2 *makeControlVisibilitySelector (
CSVWidget::SceneToolbar *parent);
virtual unsigned int getVisibilityMask() const;
unsigned int getVisibilityMask() const override;
/// \param elementMask Elements to be affected by the clear operation
virtual void clearSelection (int elementMask);
void clearSelection (int elementMask) override;
/// \param elementMask Elements to be affected by the select operation
virtual void invertSelection (int elementMask);
void invertSelection (int elementMask) override;
/// \param elementMask Elements to be affected by the select operation
virtual void selectAll (int elementMask);
void selectAll (int elementMask) override;
// Select everything that references the same ID as at least one of the elements
// already selected
//
/// \param elementMask Elements to be affected by the select operation
virtual void selectAllWithSameParentId (int elementMask);
void selectAllWithSameParentId (int elementMask) override;
virtual std::string getCellId (const osg::Vec3f& point) const;
std::string getCellId (const osg::Vec3f& point) const override;
virtual Cell* getCell(const osg::Vec3d& point) const;
Cell* getCell(const osg::Vec3d& point) const override;
virtual Cell* getCell(const CSMWorld::CellCoordinates& coords) const;
Cell* getCell(const CSMWorld::CellCoordinates& coords) const override;
void setCellAlteredHeight(const CSMWorld::CellCoordinates& coords, int inCellX, int inCellY, float height);
@ -132,24 +132,24 @@ namespace CSVRender
void resetAllAlteredHeights();
virtual std::vector<osg::ref_ptr<TagBase> > getSelection (unsigned int elementMask)
const;
std::vector<osg::ref_ptr<TagBase> > getSelection (unsigned int elementMask)
const override;
virtual std::vector<osg::ref_ptr<TagBase> > getEdited (unsigned int elementMask)
const;
std::vector<osg::ref_ptr<TagBase> > getEdited (unsigned int elementMask)
const override;
virtual void setSubMode (int subMode, unsigned int elementMask);
void setSubMode (int subMode, unsigned int elementMask) override;
/// Erase all overrides and restore the visual representation to its true state.
virtual void reset (unsigned int elementMask);
void reset (unsigned int elementMask) override;
protected:
virtual void addVisibilitySelectorButtons (CSVWidget::SceneToolToggle2 *tool);
void addVisibilitySelectorButtons (CSVWidget::SceneToolToggle2 *tool) override;
virtual void addEditModeSelectorButtons (CSVWidget::SceneToolMode *tool);
void addEditModeSelectorButtons (CSVWidget::SceneToolMode *tool) override;
virtual void handleInteractionPress (const WorldspaceHitResult& hit, InteractionType type);
void handleInteractionPress (const WorldspaceHitResult& hit, InteractionType type) override;
signals:

@ -23,7 +23,7 @@ namespace CSVRender
{
public:
virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
void operator()(osg::Node* node, osg::NodeVisitor* nv) override
{
PathgridTag* tag = static_cast<PathgridTag*>(node->getUserData());
tag->getPathgrid()->update();

@ -40,7 +40,7 @@ namespace CSVRender
Pathgrid* getPathgrid () const;
virtual QString getToolTip (bool hideBasics) const;
QString getToolTip (bool hideBasics) const override;
private:

@ -17,31 +17,31 @@ namespace CSVRender
PathgridMode(WorldspaceWidget* worldspace, QWidget* parent=0);
virtual void activate(CSVWidget::SceneToolbar* toolbar);
void activate(CSVWidget::SceneToolbar* toolbar) override;
virtual void deactivate(CSVWidget::SceneToolbar* toolbar);
void deactivate(CSVWidget::SceneToolbar* toolbar) override;
virtual void primaryOpenPressed(const WorldspaceHitResult& hit);
void primaryOpenPressed(const WorldspaceHitResult& hit) override;
virtual void primaryEditPressed(const WorldspaceHitResult& hit);
void primaryEditPressed(const WorldspaceHitResult& hit) override;
virtual void secondaryEditPressed(const WorldspaceHitResult& hit);
void secondaryEditPressed(const WorldspaceHitResult& hit) override;
virtual void primarySelectPressed(const WorldspaceHitResult& hit);
void primarySelectPressed(const WorldspaceHitResult& hit) override;
virtual void secondarySelectPressed(const WorldspaceHitResult& hit);
void secondarySelectPressed(const WorldspaceHitResult& hit) override;
virtual bool primaryEditStartDrag (const QPoint& pos);
bool primaryEditStartDrag (const QPoint& pos) override;
virtual bool secondaryEditStartDrag (const QPoint& pos);
bool secondaryEditStartDrag (const QPoint& pos) override;
virtual void drag (const QPoint& pos, int diffX, int diffY, double speedFactor);
void drag (const QPoint& pos, int diffX, int diffY, double speedFactor) override;
virtual void dragCompleted(const QPoint& pos);
void dragCompleted(const QPoint& pos) override;
/// \note dragAborted will not be called, if the drag is aborted via changing
/// editing mode
virtual void dragAborted();
void dragAborted() override;
private:

@ -21,7 +21,7 @@ namespace CSVRender
///
/// \return Have there been any menu items to be added (if menu is 0 and there
/// items to be added, the function must return true anyway.
bool createContextMenu(QMenu* menu);
bool createContextMenu(QMenu* menu) override;
private:

@ -97,8 +97,8 @@ namespace CSVRender
void setAmbient(const osg::Vec4f& ambient);
virtual void mouseMoveEvent (QMouseEvent *event);
virtual void wheelEvent (QWheelEvent *event);
void mouseMoveEvent (QMouseEvent *event) override;
void wheelEvent (QWheelEvent *event) override;
std::shared_ptr<Resource::ResourceSystem> mResourceSystem;

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save