myPopup->insertSeparator();
myPopup->insertItem(tr("MSG_CHANGE_BACKGROUND"), this, SLOT(changeBackground()));
-
+
+ SUPERVGraph_ViewFrame* anActiveVF = (SUPERVGraph_ViewFrame*)myMain->parent();
+ if ( anActiveVF ) {
+ myPopup->insertSeparator();
+ myShowToolBarItem = myPopup->insertItem( tr( "MEN_SHOW_TOOLBAR" ), myMain, SLOT( onShowToolbar() ) );
+ }
+
hide();
}
}
myPopup->setItemEnabled(myAddStudyItem, !myMain->isDataflowInStudy());
+ myPopup->setItemEnabled(myShowToolBarItem, !((SUPERVGraph_ViewFrame*)myMain->parent())->getToolBar()->isVisible());
myMain->showPopup(myPopup, theEvent);
return;
}
SUPERVGUI_Main* myMain;
QPopupMenu* myPopup;
int myAddStudyItem;
+ int myShowToolBarItem;
QCursor myCursor;
// add "change dataflow parameters" popup item
myPopup->insertSeparator();
myDSParamsItem = myPopup->insertItem( tr( "MSG_SET_GRAPHPARAMS" ), myMain, SLOT( changeDSGraphParameters() ) );
+
+ SUPERVGraph_ViewFrame* anActiveVF = (SUPERVGraph_ViewFrame*)myMain->parent();
+ if ( anActiveVF ) {
+ myPopup->insertSeparator();
+ myShowToolBarItem = myPopup->insertItem( tr( "MEN_SHOW_TOOLBAR" ), myMain, SLOT( onShowToolbar() ) );
+ }
}
myPopup->setItemEnabled( myDSParamsItem, isHavingStreamPort()/*myMain->getDataflow()->IsStreamGraph()*/ );
+ myPopup->setItemEnabled( myShowToolBarItem, !((SUPERVGraph_ViewFrame*)myMain->parent())->getToolBar()->isVisible() );
+
myMain->showPopup(myPopup, theEvent);
return;
}
QPopupMenu* mySketchPopup;
int myDelPntItem;
int myOrtoItem;
+ int myShowToolBarItem;
bool myIsPanBtnClicked;
bool myIsPanActivated;
}
}
+void SUPERVGUI_Main::onShowToolbar()
+{
+ SUPERVGraph_ViewFrame* aVF = (SUPERVGraph_ViewFrame*)this->parent();
+ if ( aVF )
+ aVF->getToolBar()->show();
+}
+
void SUPERVGUI_Main::run( const bool andSuspend ) {
Trace("SUPERVGUI_Main::run");
if ( SUPERV_isNull(dataflow) )
void changeDSGraphParameters();
void onSubGraphClosed( SUIT_ViewWindow* );
void onSubGraphActivated( SUIT_ViewWindow* );
+
+ void onShowToolbar();
private slots:
void chooseData(QListViewItem* item);
msgid "MSG_INCORRECT_INDENT"
msgstr "Incorrect indent of the python function name (must be 0)!"
+
+msgid "MEN_SHOW_TOOLBAR"
+msgstr "Show toolbar"