protected virtual void OnBytesMoved(int bytesMoved, bool isRead)
 {
     if (BytesMoved != null)
     {
         var args = new ProgressStreamReportEventArgs(bytesMoved, innerStream.Length, innerStream.Position, isRead);
         BytesMoved(this, args);
     }
 }
 protected virtual void OnBytesWritten(int bytesMoved)
 {
     if (BytesWritten != null)
     {
         var args = new ProgressStreamReportEventArgs(bytesMoved, innerStream.Length, innerStream.Position, false);
         BytesWritten(this, args);
     }
 }
        private void OnGameSaveUploadBytesRead(int gameId, ProgressStreamReportEventArgs args)
        {
            var saveTransfer = CurrentSaveTransfers.FirstOrDefault(st => st.GameId == gameId);
            if (saveTransfer != null)
            {
                double progress = ((double)args.StreamPosition / (double)args.StreamLength) * 100.0;
                progress = (progress > 99.0) ? 99.0 : progress;

                UpdateSaveTransfer(saveTransfer, (int)progress);
            }
        }