Skip to content

Commit

Permalink
Fix first trigger of mediaitem changed
Browse files Browse the repository at this point in the history
  • Loading branch information
martijn00 committed Jan 6, 2021
1 parent ff8b665 commit bb11f2d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<RepositoryUrl>https://github.com/Baseflow/XamarinMediaManager</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<Version>1.0.7</Version>
<Version>1.0.8</Version>

<!--<Nullable>enable</Nullable>-->
<LangVersion>8.0</LangVersion>
Expand Down
10 changes: 4 additions & 6 deletions MediaManager/Queue/MediaQueue.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,11 @@ public int CurrentIndex
get => _currentIndex;
set
{
if (SetProperty(ref _currentIndex, value))
SetProperty(ref _currentIndex, value);
if (Current != null)
{
if (Current != null)
{
OnQueueChanged(this, new QueueChangedEventArgs(Current));
MediaManager.OnMediaItemChanged(this, new MediaItemEventArgs(Current));
}
OnQueueChanged(this, new QueueChangedEventArgs(Current));
MediaManager.OnMediaItemChanged(this, new MediaItemEventArgs(Current));
}
}
}
Expand Down

0 comments on commit bb11f2d

Please sign in to comment.