X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FOCCViewer%2FOCCViewer_ViewWindow.cxx;h=0cb903a56372ea3ca754c49719b54fb6fbd8efb8;hb=dcc5c1484f2eaad2eca2e9b4f86ad3fa6de7c370;hp=eae8cda773fc5ec2554955644185a99a8c05d04c;hpb=793d9115c29de08f109508c619dcef05725e92c6;p=modules%2Fgui.git diff --git a/src/OCCViewer/OCCViewer_ViewWindow.cxx b/src/OCCViewer/OCCViewer_ViewWindow.cxx index eae8cda77..0cb903a56 100755 --- a/src/OCCViewer/OCCViewer_ViewWindow.cxx +++ b/src/OCCViewer/OCCViewer_ViewWindow.cxx @@ -655,12 +655,21 @@ void OCCViewer_ViewWindow::createActions() aAction->setStatusTip(tr("DSC_PRESETS_VIEW")); connect(aAction, SIGNAL(activated()), this, SLOT(onRestoreView())); myActionsMap[ RestoreId ] = aAction; + + if (myModel->trihedronActivated()) { + aAction = new QtxAction(tr("MNU_SHOW_TRIHEDRE"), aResMgr->loadPixmap( "OCCViewer", tr( "ICON_OCCVIEWER_VIEW_TRIHEDRON" ) ), + tr( "MNU_SHOW_TRIHEDRE" ), 0, this); + aAction->setStatusTip(tr("DSC_SHOW_TRIHEDRE")); + connect(aAction, SIGNAL(activated()), this, SLOT(onTrihedronShow())); + myActionsMap[ TrihedronShowId ] = aAction; + } } //**************************************************************** void OCCViewer_ViewWindow::createToolBar() { myActionsMap[DumpId]->addTo(myToolBar); + myActionsMap[TrihedronShowId]->addTo(myToolBar); SUIT_ToolButton* aScaleBtn = new SUIT_ToolButton(myToolBar, "scale"); aScaleBtn->AddAction(myActionsMap[FitAllId]); @@ -872,3 +881,8 @@ void OCCViewer_ViewWindow::setRestoreFlag() myRestoreFlag = 1; } +//**************************************************************** +void OCCViewer_ViewWindow::onTrihedronShow() +{ + myModel->toggleTrihedron(); +}