-#include "SalomeApp_Application.h"
-#include "LightApp_Application.h"
-#include "LightApp_SelectionMgr.h"
-#include "LightApp_VTKSelector.h"
-
-#include "SUIT_MessageBox.h"
-#include "SUIT_ViewWindow.h"
-#include "SUIT_Session.h"
-#include "SUIT_ResourceMgr.h"
-
-#include "SALOME_ListIO.hxx"
-#include "SALOME_ListIteratorOfListIO.hxx"
-
-#include "SVTK_ViewWindow.h"
-#include "SVTK_Selector.h"
-
-#include "utilities.h"
-
-// OCCT Includes
-#include <TColStd_IndexedMapOfInteger.hxx>
-#include <TColStd_MapOfInteger.hxx>
-
-// QT Includes
-#include <qstring.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qlistbox.h>
-#include <qlayout.h>
-#include <qhbuttongroup.h>
-#include <qradiobutton.h>
-#include <qvalidator.h>
-#include <qpushbutton.h>
-#include <qwidgetstack.h>
-#include <qvbox.h>
-#include <qgroupbox.h>
-#include <qlineedit.h>
-#include <qvalidator.h>
-#include <qtable.h>
-
-// VTK Includes
-#include <vtkDataSetMapper.h>
-#include <vtkDataSet.h>
-#include <vtkPointData.h>
-#include <vtkCellData.h>
-#include <vtkCell.h>
-
-// STL Includes
-#include <map>
-
-using namespace std;
-
-static VisuGUI_SelectionDlg* mySelectionDlg = NULL;
-
-VisuGUI_SelectionDlg::VisuGUI_SelectionDlg (const SalomeApp_Module* theModule):
- QDialog(VISU::GetDesktop(theModule),
- 0,
- false,
- WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu | WDestructiveClose),
- mySelectionMgr(NULL),
- myModule(theModule)
-{
- if (mySelectionDlg)
- mySelectionDlg->close(true);
-
- setCaption( "Data on elements" );
- setSizeGripEnabled(TRUE);
-
- QGridLayout* TopLayout = new QGridLayout (this);
- TopLayout->setSpacing(6);
- TopLayout->setMargin(11);
- TopLayout->setRowStretch(0, 0);
- TopLayout->setRowStretch(1, 0);
- TopLayout->setRowStretch(2, 1);
- TopLayout->setRowStretch(3, 0);
-
- QHButtonGroup* aTypeBox = new QHButtonGroup ("Selection", this);
-
- QRadioButton* aPointBtn =
- new QRadioButton ("Point", aTypeBox);
- new QRadioButton ("Cell" , aTypeBox);
- new QRadioButton ("Actor", aTypeBox);
- aPointBtn->setChecked(true);
-
- connect(aTypeBox, SIGNAL(clicked(int)), this, SLOT(onSelectionChange(int)));
-
- TopLayout->addWidget(aTypeBox, 0, 0);
-
- QWidget* aNamePane = new QWidget (this);
- QGridLayout* aNameLay = new QGridLayout (aNamePane);
-
- QLabel* aMeshLbl = new QLabel ("Mesh name: ", aNamePane);
- myMeshName = new QLabel (aNamePane);
-
- QLabel* aFieldLbl = new QLabel ("Field name: ", aNamePane);
- myFieldName = new QLabel (aNamePane);
-
- aNameLay->addWidget(aMeshLbl, 0, 0);
- aNameLay->addWidget(myMeshName, 0, 1);
- aNameLay->addWidget(aFieldLbl, 1, 0);
- aNameLay->addWidget(myFieldName, 1, 1);
-
- TopLayout->addWidget(aNamePane, 1, 0);
-
- myWidgetStack = new QWidgetStack (this);
-
- // Create Points pane
- myPointsPane = new QVBox (myWidgetStack);
- myPointsPane->layout()->setSpacing(6);
-
- QGroupBox* aDataGrp = new QGroupBox (2, Qt::Horizontal, "Data of Point", myPointsPane);
- aDataGrp->layout()->setSpacing(6);
-
- new QLabel ("ID:", aDataGrp);
- myIDValLbl = new QLineEdit ("", aDataGrp);
- QIntValidator* aIntValidator = new QIntValidator (myIDValLbl);
- aIntValidator->setBottom(0);
- myIDValLbl->setValidator(aIntValidator);
- connect(myIDValLbl, SIGNAL(textChanged(const QString&)), this, SLOT(onPointIdEdit(const QString&)));
-
- new QLabel ("Scalar Value:", aDataGrp);
- myScalarValLbl = new QLabel ("", aDataGrp);
- new QLabel ("Vector Value:", aDataGrp);
- myVectorValLbl = new QLabel ("", aDataGrp);
- myVectorValLbl->setMinimumWidth(150);
-
- QGroupBox* aCoordGrp = new QGroupBox (2, Qt::Horizontal, "Coordinates", myPointsPane);
- aCoordGrp->layout()->setSpacing(6);
- new QLabel ("X:", aCoordGrp);
- myXValLbl = new QLabel ("", aCoordGrp);
- new QLabel ("Y:", aCoordGrp);
- myYValLbl = new QLabel ("", aCoordGrp);
- new QLabel ("Z:",aCoordGrp );
- myZValLbl = new QLabel ("", aCoordGrp);
-
-
- myWidgetStack->addWidget(myPointsPane, 0);
-
- // Create Cells pane
- myCellsPane = new QWidget (myWidgetStack);
- QGridLayout* aCellLayout = new QGridLayout (myCellsPane);
- aCellLayout->setSpacing(6);
- aCellLayout->setRowStretch(0, 0);
- aCellLayout->setRowStretch(1, 1);
-
- QGroupBox* aCellGrp = new QGroupBox(2, Qt::Horizontal, "Data of Cell", myCellsPane);