1 #include "XGUI_Module.h"
2 #include "XGUI_Constants.h"
3 #include "XGUI_Command.h"
4 #include "XGUI_MainMenu.h"
5 #include "XGUI_MainWindow.h"
6 #include "XGUI_MenuGroupPanel.h"
7 #include "XGUI_Tools.h"
8 #include "XGUI_Workbench.h"
9 #include "XGUI_Workshop.h"
10 #include "XGUI_Viewer.h"
11 #include "ModuleBase_WidgetFactory.h"
12 #include "XGUI_SelectionMgr.h"
13 #include "XGUI_ObjectsBrowser.h"
14 #include "XGUI_Displayer.h"
15 #include "XGUI_OperationMgr.h"
16 #include "XGUI_SalomeConnector.h"
17 #include "XGUI_SalomeViewer.h"
18 #include "XGUI_ActionsMgr.h"
19 #include "XGUI_ErrorDialog.h"
20 #include "XGUI_ViewerProxy.h"
21 #include "XGUI_PropertyPanel.h"
23 #include <Model_Events.h>
24 #include <ModelAPI_PluginManager.h>
25 #include <ModelAPI_Feature.h>
26 #include <ModelAPI_Data.h>
27 #include <ModelAPI_AttributeDocRef.h>
29 #include <Events_Loop.h>
30 #include <Events_Error.h>
31 #include <ModuleBase_Operation.h>
32 #include <ModuleBase_Operation.h>
33 #include <ModuleBase_OperationDescription.h>
34 #include <Config_Common.h>
35 #include <Config_FeatureMessage.h>
36 #include <Config_PointerMessage.h>
37 #include <Config_ModuleReader.h>
39 #include <QApplication>
40 #include <QFileDialog>
41 #include <QMessageBox>
42 #include <QMdiSubWindow>
43 #include <QPushButton>
44 #include <QDockWidget>
58 QMap<QString, QString> XGUI_Workshop::myIcons;
60 QString XGUI_Workshop::featureIcon(const std::string& theId)
62 QString aId(theId.c_str());
63 if (myIcons.contains(aId))
68 XGUI_Workshop::XGUI_Workshop(XGUI_SalomeConnector* theConnector)
70 myCurrentFile(QString()),
71 myPartSetModule(NULL),
72 mySalomeConnector(theConnector),
77 myMainWindow = mySalomeConnector? 0 : new XGUI_MainWindow();
79 myDisplayer = new XGUI_Displayer(this);
81 mySelector = new XGUI_SelectionMgr(this);
82 connect(mySelector, SIGNAL(selectionChanged()), this, SLOT(changeCurrentDocument()));
84 myOperationMgr = new XGUI_OperationMgr(this);
85 myActionsMgr = new XGUI_ActionsMgr(this);
86 myErrorDlg = new XGUI_ErrorDialog(myMainWindow);
88 myViewerProxy = new XGUI_ViewerProxy(this);
90 connect(myOperationMgr, SIGNAL(operationStarted()), this, SLOT(onOperationStarted()));
91 connect(myOperationMgr, SIGNAL(operationStopped(ModuleBase_Operation*)),
92 this, SLOT(onOperationStopped(ModuleBase_Operation*)));
93 connect(this, SIGNAL(errorOccurred(const QString&)), myErrorDlg, SLOT(addError(const QString&)));
96 //******************************************************
97 XGUI_Workshop::~XGUI_Workshop(void)
101 //******************************************************
102 void XGUI_Workshop::startApplication()
105 //Initialize event listening
106 Events_Loop* aLoop = Events_Loop::loop();
107 aLoop->registerListener(this, Events_Error::errorID()); //!< Listening application errors.
108 //TODO(sbh): Implement static method to extract event id [SEID]
109 Events_ID aFeatureId = aLoop->eventByName(EVENT_FEATURE_LOADED);
110 aLoop->registerListener(this, aFeatureId);
111 Events_ID aPartSetId = aLoop->eventByName("PartSetModuleEvent");
112 aLoop->registerListener(this, aPartSetId);
113 Events_ID aFeatureUpdatedId = aLoop->eventByName(EVENT_FEATURE_UPDATED);
114 aLoop->registerListener(this, aFeatureUpdatedId);
117 myMainWindow->show();
118 updateCommandStatus();
123 //******************************************************
124 void XGUI_Workshop::initMenu()
126 if (isSalomeMode()) {
127 // Create only Undo, Redo commands
128 salomeConnector()->addEditCommand("UNDO_CMD",
129 tr("Undo"), tr("Undo last command"),
130 QIcon(":pictures/undo.png"),
131 false, this, SLOT(onUndo()),
133 salomeConnector()->addEditCommand("REDO_CMD",
134 tr("Redo"), tr("Redo last command"),
135 QIcon(":pictures/redo.png"),
136 false, this, SLOT(onRedo()),
138 salomeConnector()->addEditMenuSeparator();
141 XGUI_Workbench* aPage = myMainWindow->menuObject()->generalPage();
143 // File commands group
144 XGUI_MenuGroupPanel* aGroup = aPage->addGroup("Default");
146 XGUI_Command* aCommand;
148 aCommand = aGroup->addFeature("SAVE_CMD", tr("Save..."), tr("Save the document"),
149 QIcon(":pictures/save.png"), QKeySequence::Save);
150 aCommand->connectTo(this, SLOT(onSave()));
151 //aCommand->disable();
153 aCommand = aGroup->addFeature("UNDO_CMD", tr("Undo"), tr("Undo last command"),
154 QIcon(":pictures/undo.png"), QKeySequence::Undo);
155 aCommand->connectTo(this, SLOT(onUndo()));
157 aCommand = aGroup->addFeature("REDO_CMD", tr("Redo"), tr("Redo last command"),
158 QIcon(":pictures/redo.png"), QKeySequence::Redo);
159 aCommand->connectTo(this, SLOT(onRedo()));
161 aCommand = aGroup->addFeature("REBUILD_CMD", tr("Rebuild"), tr("Rebuild data objects"),
162 QIcon(":pictures/rebuild.png"));
164 aCommand = aGroup->addFeature("SAVEAS_CMD", tr("Save as..."), tr("Save the document into a file"),
165 QIcon(":pictures/save.png"));
166 aCommand->connectTo(this, SLOT(onSaveAs()));
167 //aCommand->disable();
169 aCommand = aGroup->addFeature("OPEN_CMD", tr("Open..."), tr("Open a new document"),
170 QIcon(":pictures/open.png"), QKeySequence::Open);
171 aCommand->connectTo(this, SLOT(onOpen()));
173 //aCommand = aGroup->addFeature("NEW_CMD", tr("New"), tr("Create a new document"),
174 // QIcon(":pictures/new.png"), QKeySequence::New);
175 //aCommand->connectTo(this, SLOT(onNew()));
177 aCommand = aGroup->addFeature("EXIT_CMD", tr("Exit"), tr("Exit application"),
178 QIcon(":pictures/close.png"), QKeySequence::Close);
179 aCommand->connectTo(this, SLOT(onExit()));
183 //******************************************************
184 XGUI_Workbench* XGUI_Workshop::addWorkbench(const QString& theName)
186 XGUI_MainMenu* aMenuBar = myMainWindow->menuObject();
187 return aMenuBar->addWorkbench(theName);
190 //******************************************************
191 void XGUI_Workshop::processEvent(const Events_Message* theMessage)
193 //A message to start feature creation received.
194 static Events_ID aFeatureLoadedId = Events_Loop::loop()->eventByName(EVENT_FEATURE_LOADED);
195 if (theMessage->eventID() == aFeatureLoadedId) {
196 const Config_FeatureMessage* aFeatureMsg = dynamic_cast<const Config_FeatureMessage*>(theMessage);
197 addFeature(aFeatureMsg);
200 //Update property panel on corresponding message. If there is no current operation (no
201 //property panel), or received message has different feature to the current - do nothing.
202 static Events_ID aFeatureUpdatedId = Events_Loop::loop()->eventByName(EVENT_FEATURE_UPDATED);
203 if (theMessage->eventID() == aFeatureUpdatedId && myOperationMgr->hasOperation())
205 const Model_FeatureUpdatedMessage* anUpdateMsg =
206 dynamic_cast<const Model_FeatureUpdatedMessage*>(theMessage);
207 boost::shared_ptr<ModelAPI_Feature> aNewFeature = anUpdateMsg->feature();
208 boost::shared_ptr<ModelAPI_Feature> aCurrentFeature = myOperationMgr->currentOperation()->feature();
209 if(aNewFeature == aCurrentFeature) {
210 myPropertyPanel->updateContentWidget(aCurrentFeature);
213 //An operation passed by message. Start it, process and commit.
214 const Config_PointerMessage* aPartSetMsg = dynamic_cast<const Config_PointerMessage*>(theMessage);
216 ModuleBase_Operation* anOperation =
217 (ModuleBase_Operation*)(aPartSetMsg->pointer());
219 if (myOperationMgr->startOperation(anOperation)) {
220 myPropertyPanel->updateContentWidget(anOperation->feature());
221 if (anOperation->getDescription()->xmlRepresentation().isEmpty()) {
222 anOperation->commit();
223 updateCommandStatus();
228 //Show error dialog if error message received.
229 const Events_Error* anAppError = dynamic_cast<const Events_Error*>(theMessage);
231 emit errorOccurred(QString::fromLatin1(anAppError->description()));
234 myErrorDlg->activateWindow();
239 //******************************************************
240 void XGUI_Workshop::onOperationStarted()
242 ModuleBase_Operation* aOperation = myOperationMgr->currentOperation();
244 if(!aOperation->getDescription()->xmlRepresentation().isEmpty()) { //!< No need for property panel
245 connectWithOperation(aOperation);
249 ModuleBase_WidgetFactory aFactory = ModuleBase_WidgetFactory(aOperation);
250 QWidget* aContent = myPropertyPanel->contentWidget();
251 qDeleteAll(aContent->children());
252 aFactory.createWidget(aContent);
253 myPropertyPanel->setModelWidgets(aFactory.getModelWidgets());
254 myPropertyPanel->setWindowTitle(aOperation->getDescription()->description());
258 //******************************************************
259 void XGUI_Workshop::onOperationStopped(ModuleBase_Operation* theOperation)
261 ModuleBase_Operation* aOperation = myOperationMgr->currentOperation();
263 //!< No need for property panel
264 updateCommandStatus();
266 if(myOperationMgr->operationsCount() > 1) {
267 myActionsMgr->updateAction(theOperation->getDescription()->operationId());
270 if(!aOperation->getDescription()->xmlRepresentation().isEmpty()) {
271 myActionsMgr->restoreCommandState();
278 void XGUI_Workshop::addFeature(const Config_FeatureMessage* theMessage)
282 qDebug() << "XGUI_Workshop::addFeature: NULL message.";
286 // Remember features icons
287 myIcons[QString::fromStdString(theMessage->id())] = QString::fromStdString(theMessage->icon());
289 //Find or create Workbench
290 QString aWchName = QString::fromStdString(theMessage->workbenchId());
291 QString aNestedFeatures = QString::fromStdString(theMessage->nestedFeatures());
292 bool isUsePropPanel = theMessage->isUseInput();
293 if (isSalomeMode()) {
294 QString aId = QString::fromStdString(theMessage->id());
295 salomeConnector()->addFeature(aWchName,
296 QString::fromStdString(theMessage->id()),
298 QString::fromStdString(theMessage->tooltip()),
299 QIcon(theMessage->icon().c_str()),
300 isUsePropPanel, this,
301 SLOT(onFeatureTriggered()), QKeySequence());
302 myActionsMgr->addCommand(aId, salomeConnector()->command(aId));
303 salomeConnector()->setNestedActions(aId, aNestedFeatures.split(" "));
307 XGUI_MainMenu* aMenuBar = myMainWindow->menuObject();
308 XGUI_Workbench* aPage = aMenuBar->findWorkbench(aWchName);
310 aPage = addWorkbench(aWchName);
312 //Find or create Group
313 QString aGroupName = QString::fromStdString(theMessage->groupId());
314 XGUI_MenuGroupPanel* aGroup = aPage->findGroup(aGroupName);
316 aGroup = aPage->addGroup(aGroupName);
319 XGUI_Command* aCommand = aGroup->addFeature(QString::fromStdString(theMessage->id()),
320 QString::fromStdString(theMessage->text()),
321 QString::fromStdString(theMessage->tooltip()),
322 QIcon(theMessage->icon().c_str()),
323 QKeySequence(), isUsePropPanel);
324 aCommand->setUnblockableCommands(aNestedFeatures.split(" "));
325 myActionsMgr->addCommand(aCommand);
326 myPartSetModule->featureCreated(aCommand);
331 * Makes a signal/slot connections between Property Panel
332 * and given operation. The given operation becomes a
333 * current operation and previous operation if exists
335 void XGUI_Workshop::connectWithOperation(ModuleBase_Operation* theOperation)
337 QPushButton* aOkBtn = myPropertyPanel->findChild<QPushButton*>(XGUI::PROP_PANEL_OK);
338 connect(aOkBtn, SIGNAL(clicked()), theOperation, SLOT(commit()));
339 QPushButton* aCancelBtn = myPropertyPanel->findChild<QPushButton*>(XGUI::PROP_PANEL_CANCEL);
340 connect(aCancelBtn, SIGNAL(clicked()), theOperation, SLOT(abort()));
342 QAction* aCommand = 0;
343 if (isSalomeMode()) {
344 aCommand = salomeConnector()->command(theOperation->getDescription()->operationId());
346 XGUI_MainMenu* aMenu = myMainWindow->menuObject();
347 aCommand = aMenu->feature(theOperation->getDescription()->operationId());
349 //Abort operation on uncheck the command
350 connect(aCommand, SIGNAL(triggered(bool)), theOperation, SLOT(setRunning(bool)));
354 * Saves document with given name.
356 void XGUI_Workshop::saveDocument(QString theName)
358 QApplication::restoreOverrideCursor();
359 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
360 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
361 aDoc->save(theName.toLatin1().constData());
362 QApplication::restoreOverrideCursor();
365 //******************************************************
366 void XGUI_Workshop::onExit()
368 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
369 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
370 if(aDoc->isModified()) {
371 int anAnswer = QMessageBox::question(
372 myMainWindow, tr("Save current file"),
373 tr("The document is modified, save before exit?"),
374 QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel, QMessageBox::Cancel);
375 if(anAnswer == QMessageBox::Save) {
377 } else if (anAnswer == QMessageBox::Cancel) {
384 //******************************************************
385 void XGUI_Workshop::onNew()
387 QApplication::setOverrideCursor(Qt::WaitCursor);
388 if (objectBrowser() == 0) {
390 mySelector->connectViewers();
392 myViewerProxy->connectToViewer();
394 if (!isSalomeMode()) {
395 myMainWindow->showPythonConsole();
396 QMdiSubWindow* aWnd = myMainWindow->viewer()->createView();
397 aWnd->showMaximized();
398 updateCommandStatus();
400 QApplication::restoreOverrideCursor();
403 //******************************************************
404 void XGUI_Workshop::onOpen()
406 //save current file before close if modified
407 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
408 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
409 if(aDoc->isModified()) {
410 //TODO(sbh): re-launch the app?
411 int anAnswer = QMessageBox::question(
412 myMainWindow, tr("Save current file"),
413 tr("The document is modified, save before opening another?"),
414 QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel, QMessageBox::Cancel);
415 if(anAnswer == QMessageBox::Save) {
417 } else if (anAnswer == QMessageBox::Cancel) {
424 //show file dialog, check if readable and open
425 myCurrentFile = QFileDialog::getOpenFileName(mainWindow());
426 if(myCurrentFile.isEmpty())
428 QFileInfo aFileInfo(myCurrentFile);
429 if(!aFileInfo.exists() || !aFileInfo.isReadable()) {
430 QMessageBox::critical(myMainWindow, tr("Warning"), tr("Unable to open the file."));
434 QApplication::setOverrideCursor(Qt::WaitCursor);
435 aDoc->load(myCurrentFile.toLatin1().constData());
436 QApplication::restoreOverrideCursor();
437 updateCommandStatus();
440 //******************************************************
441 void XGUI_Workshop::onSave()
443 if(myCurrentFile.isEmpty()) {
447 saveDocument(myCurrentFile);
448 updateCommandStatus();
451 //******************************************************
452 void XGUI_Workshop::onSaveAs()
454 QString aTemp = myCurrentFile;
455 myCurrentFile = QFileDialog::getSaveFileName(mainWindow());
456 if(myCurrentFile.isEmpty()) {
457 myCurrentFile = aTemp;
460 QFileInfo aFileInfo(myCurrentFile);
461 if(aFileInfo.exists() && !aFileInfo.isWritable()) {
462 QMessageBox::critical(myMainWindow, tr("Warning"), tr("Unable to save the file."));
468 //******************************************************
469 void XGUI_Workshop::onUndo()
471 objectBrowser()->setCurrentIndex(QModelIndex());
472 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
473 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
475 updateCommandStatus();
478 //******************************************************
479 void XGUI_Workshop::onRedo()
481 objectBrowser()->setCurrentIndex(QModelIndex());
482 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
483 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
485 updateCommandStatus();
488 //******************************************************
489 XGUI_Module* XGUI_Workshop::loadModule(const QString& theModule)
492 QString::fromStdString(library(theModule.toStdString()));
493 if (libName.isEmpty()) {
495 qPrintable( tr( "Information about module \"%1\" doesn't exist." ).arg( theModule ) ));
500 CREATE_FUNC crtInst = 0;
503 HINSTANCE modLib = ::LoadLibrary((LPTSTR) qPrintable(libName));
507 FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
508 0, ::GetLastError(), 0, (LPTSTR) & lpMsgBuf, 0, 0);
509 QString aMsg((char*) &lpMsgBuf);
510 err = QString("Failed to load %1. %2").arg(libName).arg(aMsg);
511 ::LocalFree(lpMsgBuf);
513 crtInst = (CREATE_FUNC) ::GetProcAddress(modLib, CREATE_MODULE);
517 FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM
518 | FORMAT_MESSAGE_IGNORE_INSERTS,
519 0, ::GetLastError(), 0, (LPTSTR) & lpMsgBuf, 0, 0);
520 QString aMsg((char*) &lpMsgBuf);
521 err = QString("Failed to find %1 function. %2").arg( CREATE_MODULE).arg(aMsg);
522 ::LocalFree(lpMsgBuf);
526 void* modLib = dlopen( libName.toLatin1(), RTLD_LAZY );
528 err = QString( "Can not load library %1. %2" ).arg( libName ).arg( dlerror() );
530 crtInst = (CREATE_FUNC)dlsym( modLib, CREATE_MODULE );
532 err = QString( "Failed to find function %1. %2" ).arg( CREATE_MODULE ).arg( dlerror() );
537 XGUI_Module* aModule = crtInst ? crtInst(this) : 0;
539 if (!err.isEmpty()) {
541 QMessageBox::warning(mainWindow(), tr("Error"), err);
543 qWarning( qPrintable( err ));
549 //******************************************************
550 bool XGUI_Workshop::activateModule()
552 Config_ModuleReader aModuleReader;
553 QString moduleName = QString::fromStdString(aModuleReader.getModuleName());
554 myPartSetModule = loadModule(moduleName);
555 if (!myPartSetModule)
557 myPartSetModule->createFeatures();
561 //******************************************************
562 void XGUI_Workshop::updateCommandStatus()
564 if (isSalomeMode()) // TODO: update commands in SALOME
566 XGUI_MainMenu* aMenuBar = myMainWindow->menuObject();
568 QList<XGUI_Command*> aCommands = aMenuBar->features();
569 QList<XGUI_Command*>::const_iterator aIt;
571 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
572 if (aMgr->hasRootDocument()) {
573 XGUI_Command* aUndoCmd;
574 XGUI_Command* aRedoCmd;
575 for (aIt = aCommands.constBegin(); aIt != aCommands.constEnd(); ++aIt) {
576 if ((*aIt)->id() == "UNDO_CMD")
578 else if ((*aIt)->id() == "REDO_CMD")
580 else // Enable all commands
583 boost::shared_ptr<ModelAPI_Document> aDoc = aMgr->rootDocument();
584 aUndoCmd->setEnabled(aDoc->canUndo());
585 aRedoCmd->setEnabled(aDoc->canRedo());
587 for (aIt = aCommands.constBegin(); aIt != aCommands.constEnd(); ++aIt) {
588 if ((*aIt)->id() == "NEW_CMD")
590 else if ((*aIt)->id() == "EXIT_CMD")
598 //******************************************************
599 QDockWidget* XGUI_Workshop::createObjectBrowser(QWidget* theParent)
601 QDockWidget* aObjDock = new QDockWidget(theParent);
602 aObjDock->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea);
603 aObjDock->setWindowTitle(tr("Object browser"));
604 myObjectBrowser = new XGUI_ObjectsBrowser(aObjDock);
605 aObjDock->setWidget(myObjectBrowser);
609 //******************************************************
611 * Creates dock widgets, places them in corresponding area
612 * and tabifies if necessary.
614 void XGUI_Workshop::createDockWidgets()
616 QMainWindow* aDesktop = isSalomeMode()? salomeConnector()->desktop() :
618 QDockWidget* aObjDock = createObjectBrowser(aDesktop);
619 aDesktop->addDockWidget(Qt::LeftDockWidgetArea, aObjDock);
620 myPropertyPanel = new XGUI_PropertyPanel(aDesktop);
621 aDesktop->addDockWidget(Qt::LeftDockWidgetArea, myPropertyPanel);
622 hidePropertyPanel(); //<! Invisible by default
624 aDesktop->tabifyDockWidget(aObjDock, myPropertyPanel);
627 //******************************************************
628 void XGUI_Workshop::showPropertyPanel()
630 QAction* aViewAct = myPropertyPanel->toggleViewAction();
631 //<! Restore ability to close panel from the window's menu
632 aViewAct->setEnabled(true);
633 myPropertyPanel->show();
634 myPropertyPanel->raise();
637 //******************************************************
638 void XGUI_Workshop::hidePropertyPanel()
640 QAction* aViewAct = myPropertyPanel->toggleViewAction();
641 //<! Do not allow to show empty property panel
642 aViewAct->setEnabled(false);
643 myPropertyPanel->hide();
646 //******************************************************
647 void XGUI_Workshop::showObjectBrowser()
649 myObjectBrowser->parentWidget()->show();
652 //******************************************************
653 void XGUI_Workshop::hideObjectBrowser()
655 myObjectBrowser->parentWidget()->hide();
658 //******************************************************
659 void XGUI_Workshop::onFeatureTriggered()
661 QAction* aCmd = dynamic_cast<QAction*>(sender());
663 QString aId = salomeConnector()->commandId(aCmd);
665 myPartSetModule->launchOperation(aId);
669 //******************************************************
670 void XGUI_Workshop::changeCurrentDocument()
672 QFeatureList aFeatures = objectBrowser()->selectedFeatures();
674 // Set current document
675 if (aFeatures.size() > 0) {
676 FeaturePtr aFeature = aFeatures.first();
678 boost::shared_ptr<ModelAPI_PluginManager> aMgr = ModelAPI_PluginManager::get();
679 boost::shared_ptr<ModelAPI_AttributeDocRef> aDocRef = aFeature->data()->docRef("PartDocument");
681 aMgr->setCurrentDocument(aDocRef->value());
685 //******************************************************
686 void XGUI_Workshop::salomeViewerSelectionChanged()
688 emit salomeViewerSelection();
692 //**************************************************************
693 XGUI_SalomeViewer* XGUI_Workshop::salomeViewer() const
695 return mySalomeConnector->viewer();