ParametersPlugin_WidgetCreator::createWidgetByType(const std::string& theType,
QWidget* theParent,
Config_WidgetAPI* theWidgetApi,
- ModuleBase_IWorkshop* /*theWorkshop*/)
+ ModuleBase_IWorkshop* theWorkshop)
{
ModuleBase_ModelWidget* aModelWidget = 0;
if (theType == "parameters-manager") {
- aModelWidget = new ParametersPlugin_WidgetParamsMgr(theParent, theWidgetApi);
+ aModelWidget = new ParametersPlugin_WidgetParamsMgr(theParent, theWidgetApi, theWorkshop);
}
return aModelWidget;
}
#include <GeomDataAPI_Point2D.h>
#include <ModuleBase_Tools.h>
+#include <ModuleBase_IWorkshop.h>
+#include <ModuleBase_IViewer.h>
#include <Events_Loop.h>
#include <Config_PropManager.h>
/////////////////////////////////////////////////////////////////////////////////////////////////
ParametersPlugin_WidgetParamsMgr::ParametersPlugin_WidgetParamsMgr(QWidget* theParent,
- const Config_WidgetAPI* theData)
+ const Config_WidgetAPI* theData, ModuleBase_IWorkshop* theWorkshop)
: ModuleBase_ModelDialogWidget(theParent, theData),
- isUpplyBlocked(false)
+ myWorkshop(theWorkshop), isUpplyBlocked(false)
{
QVBoxLayout* aLayout = new QVBoxLayout(this);
SessionPtr aMgr = ModelAPI_Session::get();
aMgr->blockAutoUpdate(false);
aMgr->blockAutoUpdate(true);
-}
\ No newline at end of file
+ myWorkshop->viewer()->update();
+}
class ParametersPlugin_ItemDelegate;
class QPushButton;
class QToolButton;
-
+class ModuleBase_IWorkshop;
/*!
* \ingroup GUI
Q_OBJECT
public:
/// Constructs a model widget
- ParametersPlugin_WidgetParamsMgr(QWidget* theParent, const Config_WidgetAPI* theData);
+ ParametersPlugin_WidgetParamsMgr(QWidget* theParent, const Config_WidgetAPI* theData,
+ ModuleBase_IWorkshop* theWorkshop);
/// Destructs the model widget
virtual ~ParametersPlugin_WidgetParamsMgr() {}
void updateParametersFeatures();
+ ModuleBase_IWorkshop* myWorkshop;
+
ParametersPlugin_TreeWidget* myTable;
QTreeWidgetItem* myFeatures;
QTreeWidgetItem* myParameters;