Changeset 14398
Legend:
- Unmodified
- Added
- Removed
-
trunk/qt/CMakeLists.txt
r14396 r14398 102 102 103 103 tr_qt_wrap_ui(${PROJECT_NAME}_UI_SOURCES 104 about.ui 104 105 details.ui 105 106 mainwin.ui -
trunk/qt/about.cc
r14394 r14398 32 32 myLicenseDialog (new LicenseDialog (this)) 33 33 { 34 setWindowTitle (tr ("About Transmission")); 35 QLabel * l; 36 QVBoxLayout * v = new QVBoxLayout (this); 34 ui.setupUi (this); 37 35 38 l = new QLabel; 39 l->setPixmap (QApplication::windowIcon ().pixmap (48)); 40 l->setAlignment (Qt::AlignCenter); 41 v->addWidget (l); 42 43 QFont f (font ()); 44 f.setWeight (QFont::Bold); 45 f.setPointSize (int (f.pointSize () * 1.2)); 46 l = new QLabel (tr ("<big>Transmission %1</big>").arg (QString::fromUtf8 (LONG_VERSION_STRING))); 47 l->setAlignment (Qt::AlignCenter); 48 l->setFont (f); 49 l->setMargin (8); 50 v->addWidget (l); 51 52 l = new QLabel (tr ("A fast and easy BitTorrent client")); 53 l->setStyleSheet (QString::fromUtf8 ("text-align: center")); 54 l->setAlignment (Qt::AlignCenter); 55 v->addWidget (l); 56 57 l = new QLabel (tr ("Copyright (c) The Transmission Project")); 58 l->setAlignment (Qt::AlignCenter); 59 v->addWidget (l); 60 61 l = new QLabel (QString::fromUtf8 ("<a href=\"http://www.transmissionbt.com/\">http://www.transmissionbt.com/</a>")); 62 l->setOpenExternalLinks (true); 63 l->setAlignment (Qt::AlignCenter); 64 v->addWidget (l); 65 66 v->addSpacing (HIG::PAD_BIG); 36 ui.iconLabel->setPixmap (QApplication::windowIcon ().pixmap (48)); 37 ui.titleLabel->setText (tr ("<big><b>Transmission %1</b></big>").arg (QString::fromUtf8 (LONG_VERSION_STRING))); 67 38 68 39 QPushButton * b; 69 QDialogButtonBox * box = new QDialogButtonBox;70 40 71 41 b = new QPushButton (tr ("C&redits"), this); 72 box->addButton (b, QDialogButtonBox::ActionRole);42 ui.dialogButtons->addButton (b, QDialogButtonBox::ActionRole); 73 43 connect (b, SIGNAL (clicked ()), this, SLOT (showCredits ())); 74 44 75 45 b = new QPushButton (tr ("&License"), this); 76 box->addButton (b, QDialogButtonBox::ActionRole);46 ui.dialogButtons->addButton (b, QDialogButtonBox::ActionRole); 77 47 connect (b, SIGNAL (clicked ()), myLicenseDialog, SLOT (show ())); 78 48 79 box->addButton (QDialogButtonBox::Close); 80 box->setCenterButtons (true); 81 v->addWidget (box); 82 connect (box, SIGNAL (rejected ()), this, SLOT (hide ())); 49 ui.dialogButtons->button (QDialogButtonBox::Close)->setDefault (true); 83 50 } 84 51 -
trunk/qt/about.h
r14241 r14398 13 13 #include <QDialog> 14 14 15 #include "ui_about.h" 16 15 17 class AboutDialog: public QDialog 16 18 { 17 19 Q_OBJECT 18 20 19 private:20 QDialog * myLicenseDialog;21 22 21 public: 23 22 AboutDialog (QWidget * parent = 0); 24 23 ~AboutDialog () {} 25 QWidget * createAboutTab ();26 QWidget * createAuthorsTab ();27 QWidget * createLicenseTab ();28 24 29 25 public slots: 30 26 void showCredits (); 31 27 28 private: 29 QDialog * myLicenseDialog; 30 Ui::AboutDialog ui; 32 31 }; 33 32 -
trunk/qt/qtr.pro
r14393 r14398 47 47 translations/transmission_uk.ts 48 48 49 FORMS += details.ui \ 49 FORMS += about.ui \ 50 details.ui \ 50 51 mainwin.ui \ 51 52 session-dialog.ui \
Note: See TracChangeset
for help on using the changeset viewer.