Changeset 163 in tspsg-svn for trunk/src/mainwindow.cpp
- Timestamp:
- Apr 15, 2011, 4:21:25 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/mainwindow.cpp
r162 r163 545 545 QString about; 546 546 about += QString("%1: <b>%2</b><br>").arg(tr("Target OS (ARCH)"), PLATFROM); 547 #ifndef STATIC_BUILD 548 about += QString("%1 (%2):<br>").arg(tr("Qt library"), tr("shared")); 547 about += QString("%1:<br>").arg(tr("Qt library")); 549 548 about += QString(" %1: <b>%2</b><br>").arg(tr("Build time"), QT_VERSION_STR); 550 549 about += QString(" %1: <b>%2</b><br>").arg(tr("Runtime"), qVersion()); 551 #else552 about += QString("%1: <b>%2</b> (%3)<br>").arg(tr("Qt library"), QT_VERSION_STR, tr("static"));553 #endif // STATIC_BUILD554 550 about.append(QString("%1: <b>%2x%3</b><br>").arg("Logical DPI").arg(logicalDpiX()).arg(logicalDpiY())); 555 551 about += tr("Buid <b>%1</b>, built on <b>%2</b> at <b>%3</b> with <b>%4</b> compiler.").arg(BUILD_NUMBER).arg(__DATE__).arg(__TIME__).arg(COMPILER) + "<br>"; … … 742 738 QPushButton *cancel = new QPushButton(&pd); 743 739 cancel->setIcon(GET_ICON("dialog-cancel")); 744 cancel->setText(QCoreApplication::translate("Q ProgressDialog", "Cancel", "No need to translate this. This translation will be taken from Qt translation files."));740 cancel->setText(QCoreApplication::translate("QDialogButtonBox", "Cancel", "No need to translate this. This translation will be taken from Qt translation files.")); 745 741 pd.setCancelButton(cancel); 746 742 pd.setMaximum(n); … … 838 834 pic.setRenderHints(QPainter::Antialiasing | QPainter::SmoothPixmapTransform); 839 835 QFont font = qvariant_cast<QFont>(settings->value("Output/Font", QFont(DEF_FONT_FACE))); 840 font.setStyleHint(QFont:: Monospace);836 font.setStyleHint(QFont::TypeWriter); 841 837 // Font size in pixels = graph node radius / 2.75. 842 838 // See MainWindow::drawNode() for graph node radius calcualtion description. 839 #ifndef Q_WS_S60 843 840 font.setPixelSize(logicalDpiX() * (settings->value("Output/GraphWidth", DEF_GRAPH_WIDTH).toReal() / CM_IN_INCH) / 4.5 / 2.75); 841 #else 842 // Also, see again MainWindow::drawNode() for why is additional 1.3 divider added in Symbian. 843 font.setPixelSize(logicalDpiX() * (settings->value("Output/GraphWidth", DEF_GRAPH_WIDTH).toReal() / CM_IN_INCH) / 4.5 / 2.75 / 1.3); 844 #endif 844 845 if (settings->value("Output/HQGraph", DEF_HQ_GRAPH).toBool()) { 845 846 font.setWeight(QFont::DemiBold); … … 1474 1475 if (!isWindowModified()) 1475 1476 return true; 1476 int res = QMessageBox::warning(this, tr("Unsaved Changes"), tr("Would you like to save changes in the current task?"), QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel); 1477 #ifdef Q_WS_S60 1478 int res = QSMessageBox(this).exec(); 1479 #else 1480 int res = QMessageBox::warning(this, tr("Unsaved Changes"), tr("Would you like to save changes in the current task?"), QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel); 1481 #endif 1477 1482 if (res == QMessageBox::Save) 1478 1483 return actionFileSaveTriggered(); … … 1664 1669 actionHelpReportBug->setIcon(GET_ICON("tools-report-bug")); 1665 1670 actionHelpAbout->setIcon(GET_ICON("help-about")); 1666 actionHelpAboutQt->setIcon(QIcon(":/ images/icons/"ICON_SIZE"/qtlogo."ICON_FORMAT));1671 actionHelpAboutQt->setIcon(QIcon(":/trolltech/qmessagebox/images/qtlogo-64.png")); 1667 1672 #endif 1668 1673 // Buttons … … 1841 1846 QDesktopServices::openUrl(QUrl("http://tspsg.info/goto/bugtracker")); 1842 1847 } 1848 1849 #ifdef Q_WS_S60 1850 QSMessageBox::QSMessageBox(QWidget *parent) 1851 : QMessageBox(parent) 1852 { 1853 setIcon(QMessageBox::Warning); 1854 setWindowTitle(QApplication::translate("MainWindow", "Unsaved Changes")); 1855 setText(QApplication::translate("MainWindow", "Would you like to save changes in the current task?")); 1856 setStandardButtons(QMessageBox::Save); 1857 1858 QMenu *m = new QMenu(this); 1859 m->addAction(QApplication::translate("QDialogButtonBox", "Discard", "No need to translate this. This translation will be taken from Qt translation files."), 1860 this, SLOT(discard())); 1861 m->addAction(QApplication::translate("QDialogButtonBox", "Cancel", "No need to translate this. This translation will be taken from Qt translation files."), 1862 this, SLOT(cancel())); 1863 1864 QAction *o = new QAction(QApplication::translate("QMenuBar", "Actions", "No need to translate this. This translation will be taken from Qt translation files."), this); 1865 o->setSoftKeyRole(QAction::NegativeSoftKey); 1866 o->setMenu(m); 1867 addAction(o); 1868 } 1869 1870 void QSMessageBox::cancel(){ 1871 done(QMessageBox::Cancel); 1872 } 1873 1874 void QSMessageBox::discard() { 1875 done(QMessageBox::Discard); 1876 } 1877 #endif // Q_WS_S60
Note: See TracChangeset
for help on using the changeset viewer.