blob: 6630b815446b6d63ebe940a07eb00364a36a22eb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
import QtQuick
import Quickshell
import Quickshell.Services.Pipewire
Item {
id: root
width: indicator.width
height: parent.height
visible: root.recording
readonly property bool recording: {
const nodes = Pipewire.nodes?.values || [];
for (const node of nodes) {
if (node && node.isStream && (node.type & PwNodeType.VideoSource))
return true;
}
return false;
}
Squircle {
id: indicator
anchors.verticalCenter: parent.verticalCenter
width: 28
height: 22
cornerRadius: 8
fillColor: Theme.destructive
Image {
anchors.centerIn: parent
width: 15
height: 15
source: Quickshell.iconPath("media-record-symbolic")
sourceSize: Qt.size(width, height)
smooth: true
mipmap: true
}
}
}
|