]> Creatis software - cpPlugins.git/blobdiff - lib/cpExtensions/QT/DicomSeriesSelectorWidget.h
...
[cpPlugins.git] / lib / cpExtensions / QT / DicomSeriesSelectorWidget.h
index b30df8e2cd83ec54bfd36e56ed13629a52442820..172d545746269e960902a6c51d45abd0748350c7 100644 (file)
@@ -1,11 +1,12 @@
-#ifndef __CPEXTENSIONS__QT__DICOMSERIESSELECTORWIDGET__H__
-#define __CPEXTENSIONS__QT__DICOMSERIESSELECTORWIDGET__H__
+#ifndef __cpExtensions__QT__DicomSeriesSelectorWidget__H__
+#define __cpExtensions__QT__DicomSeriesSelectorWidget__H__
 
 #include <cpExtensions/Config.h>
 
 #ifdef cpExtensions_QT4
 
 #include <QWidget>
+#include <gdcmSerieHelper.h>
 
 // -------------------------------------------------------------------------
 namespace Ui
@@ -28,6 +29,27 @@ namespace cpExtensions
     public:
       typedef DicomSeriesSelectorWidget Self;
 
+    protected:
+      /**
+       */
+      class _GDCMSerieHelper
+        : public gdcm::SerieHelper
+      {
+      public:
+        _GDCMSerieHelper( )
+          {
+          }
+        virtual ~_GDCMSerieHelper( )
+          {
+          }
+        template< class _TIt >
+        void SetFileNames( _TIt b, _TIt e )
+          {
+            for( _TIt i = b; i != e; ++i )
+              this->AddFileName( *i );
+          }
+      };
+
     public:
       explicit DicomSeriesSelectorWidget( QWidget* parent = 0 );
       virtual ~DicomSeriesSelectorWidget( );
@@ -35,13 +57,15 @@ namespace cpExtensions
       QString startDir( ) const;
       void setStartDir( const QString& dir, bool build = true );
 
-      std::vector< std::string > selectedFilenames( );
+      std::vector< std::string >* selectedFilenames( );
 
     protected slots:
       void _Choose( );
 
     protected:
       Ui::DicomSeriesSelectorWidget* m_UI;
+      _GDCMSerieHelper m_GDCMHelper;
+      std::map< std::string, std::vector< std::string > > m_Series;
     };
 
   } // ecapseman
@@ -50,6 +74,6 @@ namespace cpExtensions
 
 #endif // cpExtensions_QT4
 
-#endif // __CPEXTENSIONS__QT__DICOMSERIESSELECTORWIDGET__H__
+#endif // __cpExtensions__QT__DicomSeriesSelectorWidget__H__
 
 // eof - $RCSfile$