stopAndPlayDelta delta app@(PlayerApp l _ _ (Just (Playback playPos _ _ _ _))) =
    stop app >>= play (Just pos)
  where
    pos = (playPos + delta) `mod` Vec.length (L.listElements l)


-- | Returns the initial state of the application.
stopAndPlayDelta delta app@(PlayerApp l _ _ (Just (Playback playPos _ _ _ _))) =
    stop app >>= play (Just pos)
  where
    pos = (playPos + delta) `mod` Vec.length (L.listElements l)


-- | Returns the initial state of the application.
stopAndPlayDelta delta app@(PlayerApp l _ _ (Just (Playback playPos _ _ _ _))) =
    stop app >>= play (Just pos)
  where
    pos = (playPos + delta) `mod` Vec.length (L.listElements l)


-- | Returns the initial state of the application.