Changeset 92 in tspsg-svn for trunk/src/mainwindow.cpp
- Timestamp:
- Feb 23, 2010, 9:21:44 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/mainwindow.cpp
r91 r92 225 225 { 226 226 QPrintPreviewDialog ppd(printer, this); 227 228 227 connect(&ppd,SIGNAL(paintRequested(QPrinter *)),SLOT(printPreview(QPrinter *))); 228 ppd.exec(); 229 229 } 230 230 … … 258 258 QApplication::restoreOverrideCursor(); 259 259 } 260 } 261 if (sd.translucencyChanged() != 0) { 262 toggleTranclucency(sd.translucencyChanged() == 1); 260 263 } 261 264 } … … 352 355 txtAbout->moveCursor(QTextCursor::Start); 353 356 357 bb->button(QDialogButtonBox::Ok)->setCursor(QCursor(Qt::PointingHandCursor)); 358 354 359 vb->addLayout(hb); 355 360 vb->addWidget(txtAbout); … … 361 366 362 367 connect(bb, SIGNAL(accepted()), dlg, SLOT(accept())); 368 369 // Adding some eyecandy in Vista and 7 :-) 370 if (QtWin::isCompositionEnabled()) { 371 QtWin::enableBlurBehindWindow(dlg, true); 372 } 363 373 364 374 dlg->resize(410, 300); … … 758 768 759 769 #ifdef Q_OS_WINCE 770 menuBar()->setDefaultAction(menuFile->menuAction()); 771 #endif // Q_OS_WINCE 772 773 #ifdef Q_OS_WINCE 760 774 //! \hack HACK: A little hack for toolbar icons to have a sane size. 761 775 toolBar->setIconSize(QSize(logicalDpiX() / 4, logicalDpiY() / 4)); 762 #endif 776 #endif // Q_OS_WINCE 763 777 764 778 solutionText->document()->setDefaultFont(settings->value("Output/Font",QFont(DEF_FONT_FAMILY,DEF_FONT_SIZE)).value<QFont>()); … … 794 808 retranslateUi(false); 795 809 796 setCentralWidget(tabWidget); 810 // Adding some eyecandy in Vista and 7 :-) 811 if (QtWin::isCompositionEnabled() && settings->value("UseTranslucency", DEF_USE_TRANSLUCENCY).toBool()) { 812 toggleTranclucency(true); 813 } 797 814 } 798 815 … … 809 826 #endif // QT_NO_PRINTER 810 827 } 828 829 void MainWindow::toggleTranclucency(bool enable) 830 { 831 QtWin::enableBlurBehindWindow(this, enable); 832 QtWin::enableBlurBehindWindow(tabWidget, enable); 833 834 if (QtWin::enableBlurBehindWindow(tabTask, enable)) 835 tabTask->setAutoFillBackground(enable); 836 if (QtWin::enableBlurBehindWindow(tabSolution, enable)) 837 tabSolution->setAutoFillBackground(enable); 838 }
Note: See TracChangeset
for help on using the changeset viewer.