Salome HOME
Construction of vertices/edges/faces on the base of sketch: Widget Creator Factory
[modules/shaper.git] / src / SketchShapePlugin / SketchShapePlugin_WidgetCreator.cpp
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 #include "SketchShapePlugin_WidgetCreator.h"
4 #include "SketchShapePlugin_PageGroupBox.h"
5
6 SketchShapePlugin_WidgetCreator::SketchShapePlugin_WidgetCreator()
7 : ModuleBase_IWidgetCreator()
8 {
9   myTypes.insert("sketchshape_groupbox");
10 }
11
12 const std::set<std::string>& SketchShapePlugin_WidgetCreator::widgetTypes()
13 {
14   return myTypes;
15 }
16
17 ModuleBase_ModelWidget* SketchShapePlugin_WidgetCreator::createWidgetByType(
18                                    const std::string& theType, QWidget* theParent)
19 {
20   ModuleBase_ModelWidget* aWidget = 0;
21   if (myTypes.find(theType) == myTypes.end())
22     return aWidget;
23
24   //if (theType == "sketchshape_groupbox") {
25   //  aWidget = new SketchShapePlugin_PageGroupBox(theParent);
26   //}
27
28   return aWidget;
29 }