#include <cpBaseQtApplication/MainWindow.h>
#include <cpBaseQtApplication/Plugins/Navigator.h>
#include <cpBaseQtApplication/Pipeline/Canvas.h>
+#include <cpExtensions/QT/ConfigurationChooser.h>
+#include <cpExtensions/QT/ActorsWidgetInterface.h>
#include <QDir>
#include <QFileDialog>
setViewer( cpExtensions::QT::ActorsWidgetInterface* v )
{
this->m_Viewer = v;
+ if( this->m_Viewer != NULL )
+ {
+ auto interactors = this->m_Viewer->GetInteractors( );
+ for( auto wIt : this->m_Workspaces )
+ for( auto i : interactors )
+ wIt.second->AddInteractor( i );
+
+ } // fi
}
// -------------------------------------------------------------------------
if( this->m_SingleWorkspace )
this->m_Workspaces.clear( );
this->m_Workspaces[ name ] = TWorkspace::New( );
+ if( this->m_Canvas != NULL )
+ this->m_Canvas->setWorkspace( this->m_Workspaces[ name ] );
+ if( this->m_Viewer != NULL )
+ {
+ auto interactors = this->m_Viewer->GetInteractors( );
+ auto wIt = this->m_Workspaces.find( name );
+ for( auto i : interactors )
+ wIt->second->AddInteractor( i );
+
+ } // fi
this->setWindowTitle( ( this->m_BaseWindowTitle + name ).c_str( ) );
} // fi
this->_loadWorkspace( dlg.selectedFiles( ).begin( )->toStdString( ) );
}
+// -------------------------------------------------------------------------
+void cpBaseQtApplication::MainWindow::
+_actorsProperties( )
+{
+ auto data =
+ dynamic_cast< cpExtensions::QT::ActorsWidgetInterface* >(
+ this->m_Viewer
+ );
+ if( data != NULL )
+ {
+ auto dlg = new cpExtensions::QT::ConfigurationChooser( this );
+ dlg->setData( data );
+ dlg->exec( );
+
+ } // fi
+}
+
// eof - $RCSfile$