*/
void GLViewer_ViewFrame::createToolBar()
{
- int tid = toolMgr()->createToolBar( tr("LBL_TOOLBAR_LABEL") );
+ int tid = toolMgr()->createToolBar( tr("LBL_TOOLBAR_LABEL"), false );
toolMgr()->append( DumpId, tid );
QtxMultiAction* aScaleAction = new QtxMultiAction( this );
*/
void OCCViewer_ViewWindow::createToolBar()
{
- int tid = toolMgr()->createToolBar( tr( "LBL_TOOLBAR_LABEL" ) );
+ int tid = toolMgr()->createToolBar( tr( "LBL_TOOLBAR_LABEL" ), false );
toolMgr()->append( DumpId, tid );
if( myModel->trihedronActivated() )
void Plot2d_ViewWindow::createToolBar()
{
QtxActionToolMgr* mgr = toolMgr();
- myToolBar = mgr->createToolBar( tr( "LBL_TOOLBAR_LABEL" ) );
+ myToolBar = mgr->createToolBar( tr( "LBL_TOOLBAR_LABEL" ), false );
mgr->append( DumpId, myToolBar );
mgr->append( ScaleOpId, myToolBar );
mgr->append( MoveOpId, myToolBar );
\return id of created/found toolbar
*/
int QtxActionToolMgr::createToolBar( const QString& title, const int tid, QMainWindow* mw )
+{
+ return createToolBar( title, true, Qt::AllToolBarAreas, tid, mw );
+}
+
+int QtxActionToolMgr::createToolBar( const QString& title, bool floatable, Qt::ToolBarAreas dockAreas,
+ int tid, QMainWindow* mw )
{
static int _toolBarId = -1;
if ( !tb )
{
tb = new QtxToolBar( true, tbw );
+ tb->setFloatable( floatable );
+ tb->setAllowedAreas( dockAreas );
+ tb->setMovable( dockAreas & Qt::AllToolBarAreas );
//mainWindow()->addToolBar( tb );
tb->setWindowTitle( title );
tb->setObjectName( title );
QMainWindow* mainWindow() const;
int createToolBar( const QString&, int = -1, QMainWindow* = 0 );
+ int createToolBar( const QString&, bool, Qt::ToolBarAreas = Qt::AllToolBarAreas,
+ int = -1, QMainWindow* = 0 );
void removeToolBar( const QString& );
void removeToolBar( const int );
{
DEBTRACE("QxScene_ViewWindow::createToolBar");
QtxActionToolMgr* mgr = toolMgr();
- myToolBar = mgr->createToolBar( tr( "LBL_TOOLBAR_LABEL" ) );
+ myToolBar = mgr->createToolBar( tr( "LBL_TOOLBAR_LABEL" ), false );
mgr->append( ScaleOpId, myToolBar );
mgr->append( MoveOpId, myToolBar );
mgr->append( ResetId, myToolBar );
setBackgroundColor(QColor(R,G,B));*/
myToolBar = new QToolBar(this);
+ myToolBar->setFloatable(false);
//myToolBar->setCloseMode(QDockWindow::Undocked);
myToolBar->setWindowTitle(tr("LBL_TOOLBAR_LABEL"));
createActions();
aRenderer->Delete();
aSelector->Delete();
- myToolBar = toolMgr()->createToolBar( tr("LBL_TOOLBAR_LABEL"), -1, this );
- myRecordingToolBar = toolMgr()->createToolBar( tr("LBL_TOOLBAR_RECORD_LABEL"), -1, this );
+ myToolBar = toolMgr()->createToolBar( tr("LBL_TOOLBAR_LABEL"), false, Qt::AllToolBarAreas, -1, this );
+ myRecordingToolBar = toolMgr()->createToolBar( tr("LBL_TOOLBAR_RECORD_LABEL"), false, Qt::AllToolBarAreas, -1, this );
createActions( SUIT_Session::session()->activeApplication()->resourceMgr() );
createToolBar();
setCentralWidget( myRenderWindow );
myToolBar = new QtxToolBar( true, tr("LBL_TOOLBAR_LABEL"), this );
+ myToolBar->setFloatable( false );
createActions();
createToolBar();