2 Commits

Author SHA1 Message Date
5eb15eb7a5 GetPause implemented 2025-06-28 14:14:55 +02:00
3e68bbda29 added SetPlaylistPosition 2025-06-28 13:47:16 +02:00
2 changed files with 8 additions and 0 deletions

View File

@ -53,6 +53,10 @@ func GetPlaylist(socket string) ([]PlaylistEntry, error) {
return GetProperty[[]PlaylistEntry](socket, "playlist")
}
func GetPause(socket string) (bool, error) {
return GetProperty[bool](socket, "pause")
}
func GetDuration(socket string) (time.Duration, error) {
durationInSeconds, err := GetProperty[float64](socket, "duration")
if err != nil {

View File

@ -21,3 +21,7 @@ func SetPercentPos(socket string, percentPos float64) error {
func SetVolume(socket string, volume float64) error {
return SetProperty[float64](socket, "volume", volume)
}
func SetPlaylistPosition(socket string, index int) error {
return SetProperty(socket, "playlist-pos", index)
}