Add Player passthru for new items

This commit is contained in:
Matt Nadareski
2021-10-04 23:03:10 -07:00
parent 0a5c3f49c3
commit 76415ae04f

View File

@@ -31,6 +31,17 @@ namespace RedBookPlayer.GUI.ViewModels
#region Player Passthrough
/// <summary>
/// Currently selected disc
/// </summary>
public int CurrentDisc
{
get => _currentDisc;
private set => this.RaiseAndSetIfChanged(ref _currentDisc, value);
}
private int _currentDisc;
#region OpticalDisc Passthrough
/// <summary>
@@ -417,6 +428,16 @@ namespace RedBookPlayer.GUI.ViewModels
/// </summary>
public void ExecuteEject() => _player?.Eject();
/// <summary>
/// Move to the next disc
/// </summary>
public void ExecuteNextDisc() => _player?.NextDisc();
/// <summary>
/// Move to the previous disc
/// </summary>
public void ExecutePreviousDisc() => _player?.PreviousDisc();
/// <summary>
/// Move to the next playable track
/// </summary>
@@ -800,6 +821,7 @@ namespace RedBookPlayer.GUI.ViewModels
Initialized = _player.Initialized;
CurrentDisc = _player.CurrentDisc;
CurrentTrackNumber = _player.CurrentTrackNumber;
CurrentTrackIndex = _player.CurrentTrackIndex;
CurrentTrackSession = _player.CurrentTrackSession;