Add tray icon tool tip

This commit is contained in:
BlackMark 2020-07-08 22:51:01 +02:00
parent eb18ab9f1e
commit 4bb32f0bd0

View File

@ -61,6 +61,7 @@ MainWindow::MainWindow(QWidget* parent) : QMainWindow(parent)
m_trayIcon->setIcon(*m_errorIcon);
m_trayIcon->setContextMenu(m_trayIconMenu);
m_trayIcon->show();
m_trayIcon->setToolTip(tr("AdaptiveBrightness"));
qDebug(ltr("Tray icon initialized"));
}
@ -195,4 +196,8 @@ void MainWindow::updateState()
else if(m_trayIcon) {
m_trayIcon->setIcon(*m_errorIcon);
}
if(m_trayIcon) {
m_trayIcon->setToolTip(tr("AdaptiveBrightness - %1%").arg(m_brightness * 100, 0, 'f', 0));
}
}