mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2024-12-24 16:30:35 +05:00
add synchronization with "Dependency Tree" view
This commit is contained in:
parent
4805532bcf
commit
adfe6b226a
@ -31,6 +31,7 @@ INCLUDE_DIRECTORIES(
|
||||
${PROJECT_SOURCE_DIR}/src/OBJECT
|
||||
${PROJECT_SOURCE_DIR}/src/GEOMUtils
|
||||
${PROJECT_SOURCE_DIR}/src/GEOMClient
|
||||
${PROJECT_SOURCE_DIR}/src/GEOMToolsGUI
|
||||
${PROJECT_BINARY_DIR}/idl
|
||||
)
|
||||
|
||||
|
@ -31,6 +31,7 @@
|
||||
|
||||
// GEOM includes
|
||||
#include <GEOM_Displayer.h>
|
||||
#include <GEOMToolsGUI_ReduceStudyDlg.h>
|
||||
|
||||
// QT includes
|
||||
#include <QMenu>
|
||||
@ -112,6 +113,18 @@ void DependencyTree_ViewModel::onShowOnlySelected()
|
||||
}
|
||||
}
|
||||
|
||||
//=================================================================================
|
||||
// function : onReduceStudy()
|
||||
// purpose : slot for showing dialog box "Reduce Study"
|
||||
//=================================================================================
|
||||
void DependencyTree_ViewModel::onReduceStudy()
|
||||
{
|
||||
DependencyTree_View* viewPort = dynamic_cast<DependencyTree_View*>( getActiveViewPort() );
|
||||
QDialog* dlg = new GEOMToolsGUI_ReduceStudyDlg( viewPort );
|
||||
if( dlg != NULL )
|
||||
dlg->show();
|
||||
}
|
||||
|
||||
//=================================================================================
|
||||
// function : contextMenuPopup()
|
||||
// purpose : process calling of context menu popup
|
||||
@ -127,7 +140,9 @@ void DependencyTree_ViewModel::contextMenuPopup( QMenu* theMenu )
|
||||
theMenu->clear();
|
||||
theMenu->addAction( tr( "MEN_DISPLAY" ), this, SLOT( onShowSelected() ) );
|
||||
theMenu->addAction( tr( "MEN_DISPLAY_ONLY" ), this, SLOT( onShowOnlySelected() ) );
|
||||
theMenu->addAction( tr( "REBUILD_THE_TREE"), viewPort, SLOT( onRebuildModel() ) );
|
||||
theMenu->addAction( tr( "MEN_REBUILD_THE_TREE"), viewPort, SLOT( onRebuildModel() ) );
|
||||
theMenu->addSeparator();
|
||||
theMenu->addAction( tr( "MEN_REDUCE_STUDY" ), this, SLOT( onReduceStudy() ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -39,6 +39,7 @@ private slots:
|
||||
|
||||
void onShowSelected();
|
||||
void onShowOnlySelected();
|
||||
void onReduceStudy();
|
||||
|
||||
};
|
||||
|
||||
|
@ -33,8 +33,12 @@
|
||||
</message>
|
||||
<name>DependencyTree_ViewModel</name>
|
||||
<message>
|
||||
<source>REBUILD_THE_TREE</source>
|
||||
<source>MEN_REBUILD_THE_TREE</source>
|
||||
<translation>Rebuild the tree</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>MEN_REDUCE_STUDY</source>
|
||||
<translation>Reduce study</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
@ -33,8 +33,12 @@
|
||||
</message>
|
||||
<name>DependencyTree_ViewModel</name>
|
||||
<message>
|
||||
<source>REBUILD_THE_TREE</source>
|
||||
<source>MEN_REBUILD_THE_TREE</source>
|
||||
<translation type="unfinished">Rebuild the tree</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>MEN_REDUCE_STUDY</source>
|
||||
<translation type="unfinished">Reduce study</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
@ -33,8 +33,12 @@
|
||||
</message>
|
||||
<name>DependencyTree_ViewModel</name>
|
||||
<message>
|
||||
<source>REBUILD_THE_TREE</source>
|
||||
<source>MEN_REBUILD_THE_TREE</source>
|
||||
<translation type="unfinished">Rebuild the tree</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>MEN_REDUCE_STUDY</source>
|
||||
<translation type="unfinished">Reduce study</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
@ -904,7 +904,6 @@ void GEOMToolsGUI::OnShowDependencyTree()
|
||||
void GEOMToolsGUI::OnReduceStudy()
|
||||
{
|
||||
QDialog* dlg = new GEOMToolsGUI_ReduceStudyDlg( SUIT_Session::session()->activeApplication()->desktop() );
|
||||
if ( dlg != NULL )
|
||||
if( dlg != NULL )
|
||||
dlg->show();
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user