public bool CheckState( ref EngineState state ) { return Backend.theBackend.CheckState( ref state ); }
/// /// Updates the state and returns true if it has changed /// /// \note This is totally inefficient for remoting. /// public bool CheckState( ref EngineState state ) { lock (_serializer) { if (null == state) throw new ArgumentException( "may not be null", "state" ); // No change? nothing to do! if (((EngineState)state).changeCount == _changeCount) return false; _Trace( "CheckState: change occurred" ); state.isPlaying = _shouldBePlaying; state.currentTrackIndex = _playQueueCurrentTrack; state.playQueue = (ITrackInfo[])_playQueue.ToArray(typeof(PlayableData)); state.changeCount = _changeCount; // state = new EngineState( _shouldBePlaying, // _playQueueCurrentTrack, // _playQueue, // _changeCount ); return true; } }