Ignore:
Timestamp:
Apr 21, 2010, 3:51:50 PM (14 years ago)
Author:
garnier
Message:

update

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/interfaces/basic/src/G4UIQt.cc

    r1239 r1243  
    116116,fTabWidget(NULL)
    117117,fCoutText("Output")
    118 
    119118{
    120119
     
    249248  fEmptyViewerTabLabel = new QLabel("         If you want to have a Viewer, please use /vis/open commands. ");
    250249
     250  // Only at creation. Will be set visible when sessionStart();
     251  fTabWidget->setVisible(false);
     252  fEmptyViewerTabLabel->setVisible(false);
     253
    251254  fMyVSplitter->addWidget(fToolBox);
    252255  fMyVSplitter->addWidget(fEmptyViewerTabLabel);
     
    300303  connect(fCommandArea, SIGNAL(returnPressed()), SLOT(CommandEnteredCallback()));
    301304  connect(fTabWidget,   SIGNAL(tabCloseRequested(int)), this, SLOT(TabCloseCallback(int)));
    302   //  connect(fTabWidget,   SIGNAL(currentChanged(int)), this, SLOT(CurrentChangedCallback(int)));
    303305  connect(fTabWidget, SIGNAL(currentChanged ( int ) ), SLOT(UpdateTabWidget(int)));
    304306  if(UI!=NULL) UI->SetCoutDestination(this);  // TO KEEP
     
    517519)
    518520{
    519 
    520521#ifdef G4DEBUG_INTERFACES_BASIC
    521522  printf("G4UIQt::AddTabWidget %d %d\n",sizeX, sizeY);
    522523#endif
    523   if (!aWidget) return false;
    524  
     524  if (!aWidget) {
     525    return false;
     526  }
     527
    525528  // Remove QLabel
    526529  if ( fMyVSplitter->indexOf(fEmptyViewerTabLabel) != -1) {
     
    605608// // #endif
    606609 
     610  fTabWidget->setVisible(true);
     611
    607612  return true;
    608613}
     
    623628
    624629  fTabWidget->setCurrentIndex(tabNumber);
     630
     631  // Send this signal to unblock graphic updates !
     632  fTabWidget->setVisible(true);
     633
     634  // This will send a paintEvent to OGL Viewers
    625635  fTabWidget->setTabSelected();
    626636
     
    657667  exitSession = false;
    658668
     669  fTabWidget->setVisible(true);
     670  fEmptyViewerTabLabel->setVisible(true);
     671
    659672#if QT_VERSION >= 0x040000
    660673#if QT_VERSION >= 0x040200
     
    666679  fMainWindow->show();
    667680#endif
     681
     682  QCoreApplication::sendPostedEvents () ;
    668683
    669684#ifdef G4DEBUG_INTERFACES_BASIC
Note: See TracChangeset for help on using the changeset viewer.