Skip to content

Commit

Permalink
Merge pull request #244 from aiviet/develop_koala
Browse files Browse the repository at this point in the history
Fixed #243
  • Loading branch information
martijn00 authored Aug 21, 2017
2 parents f935ba5 + 230de6f commit ba13150
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions MediaManager.Android/Video/VideoPlayerImplementation.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Android.Media;
Expand Down Expand Up @@ -234,10 +234,11 @@ public async Task Play(IMediaFile mediaFile = null)

if (Status == MediaPlayerStatus.Paused)
{
//We are simply paused so just continue
VideoViewCanvas.SeekTo(lastPosition);
VideoViewCanvas.Start();
Status = MediaPlayerStatus.Playing;
//We are simply paused so just continue
VideoViewCanvas.SeekTo(lastPosition);
VideoViewCanvas.Start();

Status = MediaPlayerStatus.Playing;
return;
}

Expand All @@ -255,7 +256,10 @@ public async Task Play(IMediaFile mediaFile = null)

public async Task Seek(TimeSpan position)
{
VideoViewCanvas.SeekTo(Convert.ToInt32(position.TotalMilliseconds));
int msec = Convert.ToInt32(position.TotalMilliseconds);
VideoViewCanvas.SeekTo(msec);
lastPosition = VideoViewCanvas.CurrentPosition;

await Task.CompletedTask;
}

Expand Down

0 comments on commit ba13150

Please sign in to comment.