Salome HOME
Issue #1368: Creation of a Qt panel. Widget creator interface correction to manage...
authornds <nds@opencascade.com>
Tue, 29 Mar 2016 11:24:51 +0000 (14:24 +0300)
committernds <nds@opencascade.com>
Tue, 29 Mar 2016 11:24:51 +0000 (14:24 +0300)
src/ModuleBase/ModuleBase_WidgetFactory.cpp

index e8176696254d4ce51b8a1c0d0aae89c4cdfa22ad..165aa750fa7acdf9aac2c929efd25642edba9067 100644 (file)
@@ -74,8 +74,10 @@ void ModuleBase_WidgetFactory::createWidget(ModuleBase_PageBase* thePage)
   std::string aWType = myWidgetApi->widgetType();
   if (aWType == NODE_FEATURE) {
     QWidget* aPanel = createPanel(thePage->pageWidget());
-    thePage->addWidget(aPanel);
-    return;
+    if (aPanel) {
+      thePage->addWidget(aPanel);
+      return;
+    }
   }
 
   if (!myWidgetApi->toChildWidget())