Changeset 1283
- Timestamp:
- Jun 1, 2010, 4:39:03 PM (14 years ago)
- Location:
- trunk/source/interfaces/basic
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/interfaces/basic/include/G4UIQt.hh
r1281 r1283 209 209 void ResizeTabWidget( QResizeEvent* ); 210 210 void CoutFilterCallback(const QString&); 211 #if QT_VERSION >= 0x040500 211 212 void TabCloseCallback(int); 212 213 void ToolBoxActivated(int); -
trunk/source/interfaces/basic/src/G4UIQt.cc
r1282 r1283 324 324 // Connect signal 325 325 connect(fCommandArea, SIGNAL(returnPressed()), SLOT(CommandEnteredCallback())); 326 #if QT_VERSION >= 0x040500 326 327 connect(fTabWidget, SIGNAL(tabCloseRequested(int)), this, SLOT(TabCloseCallback(int))); 328 #endif 327 329 connect(fTabWidget, SIGNAL(currentChanged ( int ) ), SLOT(UpdateTabWidget(int))); 328 330 connect(fToolBox, SIGNAL(currentChanged(int)), SLOT(ToolBoxActivated(int))); … … 2082 2084 2083 2085 2086 #if QT_VERSION >= 0x040500 2084 2087 void G4UIQt::TabCloseCallback(int a){ 2085 #if QT_VERSION < 0x0400002086 QWidget* temp = fTabWidget->page(a);2087 fTabWidget->removePage (temp);2088 #else2089 2088 QWidget* temp = fTabWidget->widget(a); 2090 2089 fTabWidget->removeTab (a); 2091 #endif2092 2090 2093 2091 delete temp; 2094 2092 2095 2093 if (fTabWidget->count() == 0) { 2096 #if QT_VERSION < 0x0400002097 fEmptyViewerTabLabel->reparent(fMyVSplitter,0,QPoint(0,0));2098 fTabWidget->reparent(0,0,QPoint(0,0));2099 #else2100 2094 fMyVSplitter->addWidget(fEmptyViewerTabLabel); 2101 2095 fTabWidget->setParent(0); 2102 #endif 2103 2104 } 2096 } 2097 } 2098 #endif 2105 2099 2106 2100
Note: See TracChangeset
for help on using the changeset viewer.