Salome HOME
Bug fix: don't set "Loading" state for MacroNodes in InitialState() function (called...
[modules/superv.git] / src / SUPERVGUI / SUPERVGUI_ManagePortsDlg.h
index 5c7039119266e8cd5c3e68043fc7003d4bac48e8..345d1cb424f8b3819e5476761b41638aaa50d810 100644 (file)
 
 #include <qdialog.h>
 #include <qlistbox.h>
+#include <qstringlist.h>
+#include <qlineedit.h>
+#include <qcombobox.h>
 
 class SUPERVGUI_CanvasNode;
-class QLineEdit;
-class QComboBox;
 
 /** 
  * Simple redefinition of ListBoxItem for storing ports name and type without having to parce it
@@ -66,6 +67,7 @@ protected:
   void removePort( QListBox* );
   void moveUp( QListBox* );
   void moveDown( QListBox* );
+  void moveItem( QListBox* theLB, const int from, const int to );
   
 private:
   void init();
@@ -78,7 +80,29 @@ private:
   QListBox*                     myInList;
   QListBox*                     myOutList;
   QListBoxItem*                 myLastItem;
-  bool                          myFromItemChanged;
+};
+
+/*!
+ * Port parameters dialog definition (taken from SUPERVGUI_Node.h without change)
+ */
+class SUPERVGUI_PortParamsDlg: public QDialog {
+  Q_OBJECT
+    
+ public:
+  SUPERVGUI_PortParamsDlg(const QStringList& thePortsNames);
+  ~SUPERVGUI_PortParamsDlg() {};
+
+  QString getName() { return myNameTxt->text(); }
+  QString getType() { return myTypeTxt->currentText(); }
+
+ public slots:
+  void clickOnOk();
+    
+   
+ private:
+  QLineEdit* myNameTxt;
+  QComboBox* myTypeTxt;
+  QStringList myPortsNames;
 };