EVENT_ADD_DATASOURCE,
EVENT_ADD_PRESENTATION,
EVENT_REMOVE_PRESENTATION,
+ EVENT_MODIFY_PRESENTATION,
EVENT_PLAY_TEST,
EVENT_QUIT_SALOME,
EVENT_ERROR,
else if ( event->type == MEDCALC::EVENT_REMOVE_PRESENTATION ) {
updateTreeViewForPresentationRemoval(event->presentationId);
}
+ else if ( event->type == MEDCALC::EVENT_MODIFY_PRESENTATION ) {
+ // Update parameter widget if shown:
+ if(_currentWidgetHelper)
+ _currentWidgetHelper->udpateWidget();
+ }
}
void
else if ( event->type == MEDCALC::EVENT_REMOVE_PRESENTATION ) {
emit workspaceSignal(event); // forward to PresentationController
}
+ else if ( event->type == MEDCALC::EVENT_MODIFY_PRESENTATION ) {
+ emit workspaceSignal(event); // forward to PresentationController
+ }
else if ( event->type == MEDCALC::EVENT_PLAY_TEST ) {
emit workspaceSignal(event); // forward to TestController
}
else if ( event->type == MEDCALC::EVENT_ERROR ) {
std::string msg(event->msg);
QMessageBox::warning(_salomeModule->getApp()->desktop(), "Error", QString::fromStdString(msg));
- }
+ }
+ else
+ STDLOG("WorkspaceController::processMedEvent(): Unhandled event!!!");
}
/*!
</widget>
</item>
<item row="2" column="1">
- <widget class="QSpinBox" name="spinBox"/>
+ <widget class="QSpinBox" name="spinBox">
+ <property name="minimum">
+ <number>1</number>
+ </property>
+ <property name="maximum">
+ <number>30</number>
+ </property>
+ </widget>
</item>
<item row="2" column="2">
<spacer name="horizontalSpacer">
def notifyGui_error(msg):
__notifyGui(MEDCALC.EVENT_ERROR, msg=msg)
+
+def notifyGui_modifyPresentation(presId):
+ __notifyGui(MEDCALC.EVENT_MODIFY_PRESENTATION, presentationId=presId)
import medcalc
import MEDCALC, SALOME
-from medcalc.medevents import notifyGui_addPresentation, notifyGui_removePresentation, notifyGui_error
+from medcalc.medevents import notifyGui_addPresentation, notifyGui_removePresentation, notifyGui_error, notifyGui_modifyPresentation
__manager = medcalc.medcorba.factory.getPresentationManager()
def __UpdateGENERIC(tag, presentation_id, params):
exec "__manager.update%s(presentation_id, params)" % tag
+ notifyGui_modifyPresentation(presentation_id)
UpdateMeshView = lambda pres_id, params: __UpdateGENERIC("MeshView", pres_id, params)
UpdateScalarMap = lambda pres_id, params: __UpdateGENERIC("ScalarMap", pres_id, params)