From 4d72a5da90eaff2d99b787db260c542b88749e24 Mon Sep 17 00:00:00 2001
From: Matthias Puchner <github@mpuchner.de>
Date: Mon, 11 Oct 2021 15:22:20 +0200
Subject: [PATCH] use SelectionDescriptor in MesoCrystalItem

---
 GUI/Models/MesoCrystalItem.cpp | 5 +++++
 GUI/Models/MesoCrystalItem.h   | 4 ++++
 2 files changed, 9 insertions(+)

diff --git a/GUI/Models/MesoCrystalItem.cpp b/GUI/Models/MesoCrystalItem.cpp
index 1911a94092a..707f21a3b55 100644
--- a/GUI/Models/MesoCrystalItem.cpp
+++ b/GUI/Models/MesoCrystalItem.cpp
@@ -125,6 +125,11 @@ std::unique_ptr<IFormFactor> MesoCrystalItem::getOuterShape() const
     return ff_item.createFormFactor();
 }
 
+SelectionDescriptor<FormFactorItem*> MesoCrystalItem::outerShape()
+{
+    return SelectionDescriptor<FormFactorItem*>(item<GroupItem>(P_OUTER_SHAPE));
+}
+
 ItemWithParticles* MesoCrystalItem::basisParticle() const
 {
     return dynamic_cast<ItemWithParticles*>(getItem(T_BASIS_PARTICLE));
diff --git a/GUI/Models/MesoCrystalItem.h b/GUI/Models/MesoCrystalItem.h
index efa6164e967..59c84c858c3 100644
--- a/GUI/Models/MesoCrystalItem.h
+++ b/GUI/Models/MesoCrystalItem.h
@@ -17,6 +17,7 @@
 
 #include "Base/Vector/Vectors3D.h"
 #include "GUI/Models/ItemWithParticles.h"
+#include "GUI/Models/SelectionDescriptor.h"
 #include "Sample/Lattice/Lattice3D.h"
 
 class FormFactorItem;
@@ -46,6 +47,9 @@ public:
     std::unique_ptr<IFormFactor> getOuterShape() const;
     template <typename T> T* setOuterShapeType();
 
+    SelectionDescriptor<FormFactorItem*> outerShape();
+
+
     ItemWithParticles* basisParticle() const;
 
     void setVectorA(const R3& vector_a);
-- 
GitLab