module Mpv.Data.MpvInfo where

import Control.Lens (makeClassy)
import Polysemy.Time.Json (json)

import Mpv.Data.AudioDelay (AudioDelay)
import Mpv.Data.AudioTracks (AudioTracks)
import Mpv.Data.PlaybackState (PlaybackState)
import Mpv.Data.SubDelay (SubDelay)
import Mpv.Data.Subtitles (Subtitles)
import Mpv.Data.VideoDuration (VideoDuration)
import Mpv.Data.VideoExpired (VideoExpired)
import Mpv.Data.VideoProgress (VideoProgress)
import Mpv.Data.Volume (Volume)

data MpvInfo =
  MpvInfo {
    MpvInfo -> PlaybackState
_playback :: PlaybackState,
    MpvInfo -> VideoDuration
_duration :: VideoDuration,
    MpvInfo -> VideoProgress
_progress :: VideoProgress,
    MpvInfo -> VideoExpired
_expired :: VideoExpired,
    MpvInfo -> Subtitles
_subtitles :: Subtitles,
    MpvInfo -> SubDelay
_subDelay :: SubDelay,
    MpvInfo -> AudioTracks
_audio :: AudioTracks,
    MpvInfo -> AudioDelay
_audioDelay :: AudioDelay,
    MpvInfo -> Volume
_volume :: Volume
  }
  deriving stock (MpvInfo -> MpvInfo -> Bool
(MpvInfo -> MpvInfo -> Bool)
-> (MpvInfo -> MpvInfo -> Bool) -> Eq MpvInfo
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MpvInfo -> MpvInfo -> Bool
$c/= :: MpvInfo -> MpvInfo -> Bool
== :: MpvInfo -> MpvInfo -> Bool
$c== :: MpvInfo -> MpvInfo -> Bool
Eq, Int -> MpvInfo -> ShowS
[MpvInfo] -> ShowS
MpvInfo -> String
(Int -> MpvInfo -> ShowS)
-> (MpvInfo -> String) -> ([MpvInfo] -> ShowS) -> Show MpvInfo
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MpvInfo] -> ShowS
$cshowList :: [MpvInfo] -> ShowS
show :: MpvInfo -> String
$cshow :: MpvInfo -> String
showsPrec :: Int -> MpvInfo -> ShowS
$cshowsPrec :: Int -> MpvInfo -> ShowS
Show, (forall x. MpvInfo -> Rep MpvInfo x)
-> (forall x. Rep MpvInfo x -> MpvInfo) -> Generic MpvInfo
forall x. Rep MpvInfo x -> MpvInfo
forall x. MpvInfo -> Rep MpvInfo x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MpvInfo x -> MpvInfo
$cfrom :: forall x. MpvInfo -> Rep MpvInfo x
Generic)

json ''MpvInfo
makeClassy ''MpvInfo