|
|
@ -105,7 +105,13 @@ MainWindow::MainWindow(QWidget *parent, const QStringList& torrentCmdLine) : QMa |
|
|
|
// Clean exit on log out
|
|
|
|
// Clean exit on log out
|
|
|
|
connect(static_cast<SessionApplication*>(qApp), SIGNAL(sessionIsShuttingDown()), this, SLOT(deleteBTSession())); |
|
|
|
connect(static_cast<SessionApplication*>(qApp), SIGNAL(sessionIsShuttingDown()), this, SLOT(deleteBTSession())); |
|
|
|
// Setting icons
|
|
|
|
// Setting icons
|
|
|
|
this->setWindowIcon(QIcon(QString::fromUtf8(":/Icons/skin/qbittorrent32.png"))); |
|
|
|
#if defined(Q_WS_X11) |
|
|
|
|
|
|
|
if (Preferences().useSystemIconTheme()) |
|
|
|
|
|
|
|
setWindowIcon(QIcon::fromTheme("qbittorrent", QString::fromUtf8(":/Icons/skin/qbittorrent32.png"))); |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
#else |
|
|
|
|
|
|
|
setWindowIcon(QIcon(QString::fromUtf8(":/Icons/skin/qbittorrent32.png"))); |
|
|
|
|
|
|
|
#endif |
|
|
|
actionOpen->setIcon(IconProvider::instance()->getIcon("list-add")); |
|
|
|
actionOpen->setIcon(IconProvider::instance()->getIcon("list-add")); |
|
|
|
actionDownload_from_URL->setIcon(IconProvider::instance()->getIcon("insert-link")); |
|
|
|
actionDownload_from_URL->setIcon(IconProvider::instance()->getIcon("insert-link")); |
|
|
|
actionSet_upload_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/seeding.png"))); |
|
|
|
actionSet_upload_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/seeding.png"))); |
|
|
@ -1399,8 +1405,15 @@ QIcon MainWindow::getSystrayIcon() const |
|
|
|
} |
|
|
|
} |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
QIcon icon; |
|
|
|
QIcon icon; |
|
|
|
icon.addFile(":/Icons/skin/qbittorrent22.png", QSize(22, 22)); |
|
|
|
#if defined(Q_WS_X11) |
|
|
|
icon.addFile(":/Icons/skin/qbittorrent16.png", QSize(16, 16)); |
|
|
|
if (Preferences().useSystemIconTheme()) { |
|
|
|
icon.addFile(":/Icons/skin/qbittorrent32.png", QSize(32, 32)); |
|
|
|
icon = QIcon::fromTheme("qbittorrent"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
if (icon.isNull()) { |
|
|
|
|
|
|
|
icon.addFile(":/Icons/skin/qbittorrent22.png", QSize(22, 22)); |
|
|
|
|
|
|
|
icon.addFile(":/Icons/skin/qbittorrent16.png", QSize(16, 16)); |
|
|
|
|
|
|
|
icon.addFile(":/Icons/skin/qbittorrent32.png", QSize(32, 32)); |
|
|
|
|
|
|
|
} |
|
|
|
return icon; |
|
|
|
return icon; |
|
|
|
} |
|
|
|
} |
|
|
|