summaryrefslogtreecommitdiff
path: root/src/gui/widgets
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/tabs/setup_relations.cpp26
1 files changed, 1 insertions, 25 deletions
diff --git a/src/gui/widgets/tabs/setup_relations.cpp b/src/gui/widgets/tabs/setup_relations.cpp
index 8fa377e3d..1f85a23b4 100644
--- a/src/gui/widgets/tabs/setup_relations.cpp
+++ b/src/gui/widgets/tabs/setup_relations.cpp
@@ -26,6 +26,7 @@
#include "being/localplayer.h"
+#include "gui/models/ignorechoiceslistmodel.h"
#include "gui/models/playerrelationlistmodel.h"
#include "gui/widgets/button.h"
@@ -178,31 +179,6 @@ protected:
PlayerRelationListModel *mListModel;
};
-/**
- * Class for choosing one of the various `what to do when ignoring a player' options
- */
-class IgnoreChoicesListModel final : public ListModel
-{
-public:
- ~IgnoreChoicesListModel()
- { }
-
- int getNumberOfElements() override final
- {
- return static_cast<int>(player_relations.getPlayerIgnoreStrategies()
- ->size());
- }
-
- std::string getElementAt(int i) override final
- {
- if (i >= getNumberOfElements() || i < 0)
- return "???";
-
- return (*player_relations.getPlayerIgnoreStrategies())
- [i]->mDescription;
- }
-};
-
static const std::string ACTION_DELETE("delete");
static const std::string ACTION_TABLE("table");
static const std::string ACTION_STRATEGY("strategy");