]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Show toolbars (bug 19151) fix
authorvsv <vsv@opencascade.com>
Wed, 19 Mar 2008 08:09:09 +0000 (08:09 +0000)
committervsv <vsv@opencascade.com>
Wed, 19 Mar 2008 08:09:09 +0000 (08:09 +0000)
src/SVTK/SVTK_ViewModel.cxx

index 990a96ee9ea0713d82f2e88de836fa0a40efcc10..8e5360537a1a9f93064d4581c86f3d556d57c7d6 100644 (file)
@@ -285,11 +285,19 @@ SVTK_Viewer
   QVector<SUIT_ViewWindow*> aViews = myViewManager->getViews();
   for(int i = 0, iEnd = aViews.size(); i < iEnd; i++){
     if(TViewWindow* aView = dynamic_cast<TViewWindow*>(aViews.at(i))){
-      aView->getMainWindow()->getToolBar()->show();
+      //aView->getMainWindow()->getToolBar()->show();
+      const QObjectList& aChildren = aView->getMainWindow()->children();
+      foreach (QObject* aObj, aChildren) {
+       if (aObj->inherits("QToolBar")) {
+         QToolBar* aToolBar = dynamic_cast<QToolBar*>(aObj);
+         if (aToolBar) aToolBar->show();
+       }
+      }
     }
   }
 }
 
+
 /*!
   Display presentation
   \param prs - presentation