Update changelog for v1.0.0-101pika7; improve ActiveWindow icon retrieval and adjust image dimensions for better display
All checks were successful
PikaOS Package Build & Release (amd64-v3) / build (push) Successful in 50s

This commit is contained in:
ferreo 2024-11-17 22:16:58 +00:00
parent bc894da4a9
commit f1f4fb1f2c
3 changed files with 13 additions and 11 deletions

View File

@ -1 +1 @@
1
2

View File

@ -1,4 +1,4 @@
pikabar (1.0.0-101pika6) pika; urgency=medium
pikabar (1.0.0-101pika7) pika; urgency=medium
* Font fixes and icon fixes

View File

@ -2,32 +2,34 @@ import QtQuick
import QtQuick.Layouts
import Quickshell
import Quickshell.Wayland
import Quickshell.Widgets
import "root:/"
Row {
spacing: 10
function getIcon() {
var icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId.toLowerCase())
var icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId.toLowerCase());
if (!icon) {
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId)
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.appId);
}
if (!icon) {
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title)
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title);
}
if (!icon) {
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title.toLowerCase())
icon = Quickshell.iconPath(ToplevelManager.activeToplevel.title.toLowerCase());
}
if (!icon) {
icon = Quickshell.iconPath("application-x-executable")
icon = Quickshell.iconPath("application-x-executable");
}
return icon
return icon;
}
SimpleImage {
IconImage {
height: 42
Layout.fillHeight: true
implicitWidth: parent.height / 2
implicitWidth: parent.height * 0.6
source: ToplevelManager.activeToplevel ? getIcon() : ""
}
@ -43,4 +45,4 @@ Row {
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
}
}
}