Changeset 1283


Ignore:
Timestamp:
Jun 1, 2010, 4:39:03 PM (14 years ago)
Author:
garnier
Message:

try to fix recursive paint

Location:
trunk/source/interfaces/basic
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/interfaces/basic/include/G4UIQt.hh

    r1281 r1283  
    209209  void ResizeTabWidget( QResizeEvent* );
    210210  void CoutFilterCallback(const QString&);
     211#if QT_VERSION >= 0x040500
    211212  void TabCloseCallback(int);
    212213  void ToolBoxActivated(int);
  • trunk/source/interfaces/basic/src/G4UIQt.cc

    r1282 r1283  
    324324  // Connect signal
    325325  connect(fCommandArea, SIGNAL(returnPressed()), SLOT(CommandEnteredCallback()));
     326#if QT_VERSION >= 0x040500
    326327  connect(fTabWidget,   SIGNAL(tabCloseRequested(int)), this, SLOT(TabCloseCallback(int)));
     328#endif
    327329  connect(fTabWidget, SIGNAL(currentChanged ( int ) ), SLOT(UpdateTabWidget(int)));
    328330  connect(fToolBox, SIGNAL(currentChanged(int)), SLOT(ToolBoxActivated(int)));
     
    20822084
    20832085 
     2086#if QT_VERSION >= 0x040500
    20842087void G4UIQt::TabCloseCallback(int a){
    2085 #if QT_VERSION < 0x040000
    2086   QWidget* temp = fTabWidget->page(a);
    2087   fTabWidget->removePage (temp);
    2088 #else
    20892088  QWidget* temp = fTabWidget->widget(a);
    20902089  fTabWidget->removeTab (a);
    2091 #endif
    20922090
    20932091  delete temp;
    20942092
    20952093  if (fTabWidget->count() == 0) {
    2096 #if QT_VERSION < 0x040000
    2097     fEmptyViewerTabLabel->reparent(fMyVSplitter,0,QPoint(0,0));
    2098     fTabWidget->reparent(0,0,QPoint(0,0)); 
    2099 #else
    21002094    fMyVSplitter->addWidget(fEmptyViewerTabLabel);
    21012095    fTabWidget->setParent(0);
    2102 #endif
    2103   }
    2104 }
     2096  }
     2097}
     2098#endif
    21052099
    21062100
Note: See TracChangeset for help on using the changeset viewer.