mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-31 03:50:20 -07:00
Enable system tray in MACOSX (Nick Korotysh).
This commit is contained in:
parent
c5804aac3c
commit
f99f5f5c7e
2 changed files with 0 additions and 8 deletions
|
@ -106,14 +106,10 @@ options_imp::options_imp(QWidget *parent):
|
||||||
// Load options
|
// Load options
|
||||||
loadOptions();
|
loadOptions();
|
||||||
// Disable systray integration if it is not supported by the system
|
// Disable systray integration if it is not supported by the system
|
||||||
#ifndef Q_OS_MAC
|
|
||||||
if (!QSystemTrayIcon::isSystemTrayAvailable()) {
|
if (!QSystemTrayIcon::isSystemTrayAvailable()) {
|
||||||
#endif
|
|
||||||
checkShowSystray->setChecked(false);
|
checkShowSystray->setChecked(false);
|
||||||
checkShowSystray->setEnabled(false);
|
checkShowSystray->setEnabled(false);
|
||||||
#ifndef Q_OS_MAC
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (!defined(Q_OS_UNIX) || defined(Q_OS_MAC))
|
#if (!defined(Q_OS_UNIX) || defined(Q_OS_MAC))
|
||||||
label_trayIconStyle->setVisible(false);
|
label_trayIconStyle->setVisible(false);
|
||||||
comboTrayIcon->setVisible(false);
|
comboTrayIcon->setVisible(false);
|
||||||
|
|
|
@ -135,11 +135,7 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
bool systrayIntegration() const {
|
bool systrayIntegration() const {
|
||||||
#ifdef Q_OS_MAC
|
|
||||||
return false;
|
|
||||||
#else
|
|
||||||
return value(QString::fromUtf8("Preferences/General/SystrayEnabled"), true).toBool();
|
return value(QString::fromUtf8("Preferences/General/SystrayEnabled"), true).toBool();
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void setSystrayIntegration(bool enabled) {
|
void setSystrayIntegration(bool enabled) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue