status-desktop/ui/imports/utils/Audio.qml

16 lines
467 B
QML
Raw Normal View History

import QtQuick 2.14
import QtMultimedia 5.14 as T
T.Audio {
id: audio
property var store
2022-02-09 09:43:23 +00:00
2020-07-10 18:31:12 +00:00
audioRole: Audio.NotificationRole
volume: T.QtMultimedia.convertVolume(store.volume,
T.QtMultimedia.LogarithmicVolumeScale,
T.QtMultimedia.LinearVolumeScale)
muted: !store.notificationSoundsEnabled
onError: console.warn("Audio error:", errorString, "; code:", error)
}