mirror of
https://github.com/kavishdevar/librepods.git
synced 2026-01-28 22:01:50 +00:00
linux: Use white text for tray icon battery percentage (#243)
* docs: add troubleshooting section for media controls not working * always use white text for the battery percentage in the system tray icon which matches what other applications like Bluetooth battery indicators do in Plasma * init librepods asset * remove update script for librepods
This commit is contained in:
@@ -83,3 +83,5 @@ install(TARGETS librepods
|
|||||||
)
|
)
|
||||||
install(FILES assets/me.kavishdevar.librepods.desktop
|
install(FILES assets/me.kavishdevar.librepods.desktop
|
||||||
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/applications")
|
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/applications")
|
||||||
|
install(FILES assets/librepods.png
|
||||||
|
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/icons/hicolor/512x512/apps")
|
||||||
|
|||||||
BIN
linux/assets/librepods.png
Normal file
BIN
linux/assets/librepods.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 78 KiB |
@@ -127,7 +127,7 @@ void TrayIconManager::updateIconFromBattery(const QString &status)
|
|||||||
QPixmap pixmap(32, 32);
|
QPixmap pixmap(32, 32);
|
||||||
pixmap.fill(Qt::transparent);
|
pixmap.fill(Qt::transparent);
|
||||||
QPainter painter(&pixmap);
|
QPainter painter(&pixmap);
|
||||||
painter.setPen(QApplication::palette().color(QPalette::WindowText));
|
painter.setPen(Qt::white);
|
||||||
painter.setFont(QFont("Arial", 12, QFont::Bold));
|
painter.setFont(QFont("Arial", 12, QFont::Bold));
|
||||||
painter.drawText(pixmap.rect(), Qt::AlignCenter, QString::number(minLevel) + "%");
|
painter.drawText(pixmap.rect(), Qt::AlignCenter, QString::number(minLevel) + "%");
|
||||||
painter.end();
|
painter.end();
|
||||||
@@ -141,4 +141,5 @@ void TrayIconManager::onTrayIconActivated(QSystemTrayIcon::ActivationReason reas
|
|||||||
{
|
{
|
||||||
emit trayClicked();
|
emit trayClicked();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user