1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
3 #ifndef ModuleBase_IWidgetCreator_H
4 #define ModuleBase_IWidgetCreator_H
6 #include "ModuleBase.h"
11 class ModuleBase_ModelWidget;
17 * Interface to WidgetCreator which can create specific widgets by type
19 class MODULEBASE_EXPORT ModuleBase_IWidgetCreator
22 /// Default constructor
23 ModuleBase_IWidgetCreator();
25 /// Virtual destructor
26 ~ModuleBase_IWidgetCreator();
28 /// Returns a list of possible widget types, which this creator can process
30 virtual void widgetTypes(std::list<std::string>& theTypes) = 0;
32 /// Create widget by its type
33 /// \param theType a type
34 /// \param theParent a parent widget
35 virtual ModuleBase_ModelWidget* createWidgetByType(const std::string& theType,
36 QWidget* theParent = NULL) = 0;