#include <appli/PipelineEditor/PipelineEditorMainWindow.h>
#include <appli/PipelineEditor/ui_PipelineEditorMainWindow.h>
-#include <QMessageBox>
-
-// -------------------------------------------------------------------------
-#define _QT_CONNECT_ACTION( ACTION ) \
- this->connect( \
- this->m_UI->Action##ACTION, SIGNAL( triggered( ) ), \
- this, SLOT( _Action##ACTION( ) ) \
- )
-
// -------------------------------------------------------------------------
PipelineEditorMainWindow::
PipelineEditorMainWindow(
cpPlugins_NormalizePaths(_source_dir ${source_dir})
STRING(REPLACE "${_global_source_dir}" "" _local_source_dir ${_source_dir})
SET(_binary_dir ${_global_binary_dir}${_local_source_dir})
-GET_FILENAME_COMPONENT(_app_name ${_source_dir} NAME_WE)
-OPTION(BUILD_${_app_name} "Build \"${_app_name}\" application" OFF)
+IF(${output_app})
+ SET(_app_name ${${output_app}})
+ELSE(${output_app})
+ GET_FILENAME_COMPONENT(_app_name ${_source_dir} NAME_WE)
+ENDIF(${output_app})
+SET(_app_name_option OFF)
+IF(ARGN)
+ LIST(GET ARGN 0 _app_name_option)
+ENDIF(ARGN)
+OPTION(
+ BUILD_${_app_name}
+ "Build \"${_app_name}\" application"
+ ${_app_name_option}
+ )
+## -- Real build commands
IF(BUILD_${_app_name})
-
## -- Some useful variables
SET(_sources_extensions .c .cpp .cxx)
SET(_headers_extensions .h .hpp .hxx)
IF(_qt_moc_sources)
SET(_sources ${_sources} ${_qt_moc_sources})
ENDIF(_qt_moc_sources)
-
## -- Guess what qt-ui's sould be qt-uic'ed
## -- Wrap qt-ui headers: this is equivalent to QT4_WRAP_UI except to
## -- change the output file
ADD_EXECUTABLE(${_app_name} ${_sources})
SET(${output_app} ${_app_name} PARENT_SCOPE)
ELSE(_sources)
+ SET(${output_app} "" PARENT_SCOPE)
MESSAGE(FATAL_ERROR "No source code found to build \"${_app_name}\"")
ENDIF(_sources)
ENDIF(BUILD_${_app_name})
return( empty );
}
+// -------------------------------------------------------------------------
+void cpExtensions::QT::SimpleMPRWidget::
+SetWindowLevel( double win, double lev )
+{
+ for( unsigned int i = 0; i < 3; ++i )
+ {
+ if( this->m_2DSlices[ i ].GetPointer( ) != NULL )
+ {
+ this->m_2DSlices[ i ]->SetWindowLevel( win, lev );
+ this->m_2DSlices[ i ]->Render( );
+
+ } // fi
+ if( this->m_3DSlices[ i ].GetPointer( ) != NULL )
+ {
+ this->m_3DSlices[ i ]->SetWindowLevel( win, lev );
+ this->m_3DSlices[ i ]->Render( );
+
+ } // fi
+
+ } // rof
+}
+
+// -------------------------------------------------------------------------
+void cpExtensions::QT::SimpleMPRWidget::
+ResetWindowLevel( )
+{
+}
+
// -------------------------------------------------------------------------
vtkRenderWindowInteractor* cpExtensions::QT::SimpleMPRWidget::
GetInteractor( unsigned int i )
void AddActor( vtkProp* actor, const std::string& name );
const TActors& GetActors( const std::string& name ) const;
+ void SetWindowLevel( double win, double lev );
+ void ResetWindowLevel( );
+
// Visual objects
vtkRenderWindowInteractor* GetInteractor( unsigned int i );
vtkRenderer* GetRenderer( unsigned int i );