mirror of
https://github.com/end-4/dots-hyprland.git
synced 2026-06-05 14:59:27 -05:00
add service for privacy indicators
This commit is contained in:
@@ -18,12 +18,7 @@ Singleton {
|
||||
readonly property real hardMaxValue: 2.00 // People keep joking about setting volume to 5172% so...
|
||||
property string audioTheme: Config.options.sounds.theme
|
||||
property real value: sink?.audio.volume ?? 0
|
||||
property bool micBeingAccessed: Pipewire.links.values.filter(link =>
|
||||
!link.source.isStream && !link.source.isSink && link.target.isStream
|
||||
).length > 0
|
||||
onMicBeingAccessedChanged: {
|
||||
print(micBeingAccessed)
|
||||
}
|
||||
|
||||
function friendlyDeviceName(node) {
|
||||
return (node.nickname || node.description || Translation.tr("Unknown"));
|
||||
}
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
pragma Singleton
|
||||
pragma ComponentBehavior: Bound
|
||||
import qs.modules.common
|
||||
import QtQuick
|
||||
import Quickshell
|
||||
import Quickshell.Services.Pipewire
|
||||
|
||||
/**
|
||||
* Screensharing and mic activity.
|
||||
*/
|
||||
Singleton {
|
||||
id: root
|
||||
|
||||
property bool screenSharing: Pipewire.linkGroups.values.filter(pwlg => pwlg.source.type === PwNodeType.VideoSource).map(pwlg => pwlg.target)
|
||||
property bool micActive: Pipewire.linkGroups.values.filter(pwlg => pwlg.source.type === PwNodeType.AudioSource && pwlg.target.type === PwNodeType.AudioInStream).map(pwlg => pwlg.target)
|
||||
}
|
||||
Reference in New Issue
Block a user