From 4b3693e9dbbf92d88edbb835a9ee7c7dcb98b68d Mon Sep 17 00:00:00 2001
From: Boris Spinner <bs@infomantis.de>
Date: Thu, 3 Mar 2016 13:38:57 +0100
Subject: [PATCH] Update to Mvx4 stable and fixed Mvx sample

---
 .../ExoPlayer.Core/ExoPlayer.Core.csproj      | 24 +++----
 .../MvvmCross/ExoPlayer.Core/packages.config  |  8 +--
 .../ExoPlayer.Droid/ExoPlayer.Droid.csproj    | 56 +++++++++-------
 .../ExoPlayer.Droid/MvxVideoPlayerActivity.cs |  7 +-
 .../Player/MvxExtractorRendererBuilder.cs     |  9 ++-
 .../Player/MvxHlsRendererBuilder.cs           | 66 +++++++++----------
 .../ExoPlayer.Droid/Player/MvxVideoPlayer.cs  | 11 +++-
 .../Resources/Resource.Designer.cs            | 17 ++---
 .../MvvmCross/ExoPlayer.Droid/packages.config | 10 +--
 Samples/MvvmCross/ExoPlayer.MvvmCross.sln     | 15 +++--
 10 files changed, 120 insertions(+), 103 deletions(-)

diff --git a/Samples/MvvmCross/ExoPlayer.Core/ExoPlayer.Core.csproj b/Samples/MvvmCross/ExoPlayer.Core/ExoPlayer.Core.csproj
index 9e34a3f5..71a1875a 100644
--- a/Samples/MvvmCross/ExoPlayer.Core/ExoPlayer.Core.csproj
+++ b/Samples/MvvmCross/ExoPlayer.Core/ExoPlayer.Core.csproj
@@ -35,6 +35,7 @@
   </PropertyGroup>
   <ItemGroup>
     <!-- A reference to the entire .NET Framework is automatically included -->
+    <None Include="packages.config" />
   </ItemGroup>
   <ItemGroup>
     <Compile Include="Properties\AssemblyInfo.cs" />
@@ -51,20 +52,21 @@
   </Target>
   -->
   <ItemGroup>
-    <Reference Include="MvvmCross.Platform">
-      <HintPath>..\packages\MvvmCross.Platform.4.0.0-beta8\lib\portable-net45+win+wpa81+wp80\MvvmCross.Platform.dll</HintPath>
+    <Reference Include="MvvmCross.Binding, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Binding.4.0.0\lib\portable-net45+win+wpa81+wp80\MvvmCross.Binding.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Localization">
-      <HintPath>..\packages\MvvmCross.Platform.4.0.0-beta8\lib\portable-net45+win+wpa81+wp80\MvvmCross.Localization.dll</HintPath>
+    <Reference Include="MvvmCross.Core, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Core.4.0.0\lib\portable-net45+win+wpa81+wp80\MvvmCross.Core.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Core">
-      <HintPath>..\packages\MvvmCross.Core.4.0.0-beta8\lib\portable-net45+win+wpa81+wp80\MvvmCross.Core.dll</HintPath>
+    <Reference Include="MvvmCross.Localization, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Binding.4.0.0\lib\portable-net45+win+wpa81+wp80\MvvmCross.Localization.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Binding">
-      <HintPath>..\packages\MvvmCross.Binding.4.0.0-beta8\lib\portable-net45+win+wpa81+wp80\MvvmCross.Binding.dll</HintPath>
+    <Reference Include="MvvmCross.Platform, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Platform.4.0.0\lib\portable-net45+win+wpa81+wp80\MvvmCross.Platform.dll</HintPath>
+      <Private>True</Private>
     </Reference>
   </ItemGroup>
-  <ItemGroup>
-    <None Include="packages.config" />
-  </ItemGroup>
 </Project>
\ No newline at end of file
diff --git a/Samples/MvvmCross/ExoPlayer.Core/packages.config b/Samples/MvvmCross/ExoPlayer.Core/packages.config
index 7fcd0a6d..d3ee91d1 100644
--- a/Samples/MvvmCross/ExoPlayer.Core/packages.config
+++ b/Samples/MvvmCross/ExoPlayer.Core/packages.config
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <packages>
-  <package id="MvvmCross" version="4.0.0-beta8" targetFramework="portable-net45+win+wpa81+wp80+MonoTouch10+MonoAndroid10+xamarinmac20+xamarinios10" />
-  <package id="MvvmCross.Binding" version="4.0.0-beta8" targetFramework="portable-net45+win+wpa81+wp80+MonoTouch10+MonoAndroid10+xamarinmac20+xamarinios10" />
-  <package id="MvvmCross.Core" version="4.0.0-beta8" targetFramework="portable-net45+win+wpa81+wp80+MonoTouch10+MonoAndroid10+xamarinmac20+xamarinios10" />
-  <package id="MvvmCross.Platform" version="4.0.0-beta8" targetFramework="portable-net45+win+wpa81+wp80+MonoTouch10+MonoAndroid10+xamarinmac20+xamarinios10" />
+  <package id="MvvmCross" version="4.0.0" targetFramework="portable45-net45+win8+wp8+wpa81" />
+  <package id="MvvmCross.Binding" version="4.0.0" targetFramework="portable45-net45+win8+wp8+wpa81" />
+  <package id="MvvmCross.Core" version="4.0.0" targetFramework="portable45-net45+win8+wp8+wpa81" />
+  <package id="MvvmCross.Platform" version="4.0.0" targetFramework="portable45-net45+win8+wp8+wpa81" />
 </packages>
\ No newline at end of file
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/ExoPlayer.Droid.csproj b/Samples/MvvmCross/ExoPlayer.Droid/ExoPlayer.Droid.csproj
index 972a060e..eaf1107e 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/ExoPlayer.Droid.csproj
+++ b/Samples/MvvmCross/ExoPlayer.Droid/ExoPlayer.Droid.csproj
@@ -33,37 +33,45 @@
     <WarningLevel>4</WarningLevel>
   </PropertyGroup>
   <ItemGroup>
+    <Reference Include="ExoPlayer, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Xam.Plugins.Android.ExoPlayer.1.5.6\lib\MonoAndroid\ExoPlayer.dll</HintPath>
+      <Private>True</Private>
+    </Reference>
     <Reference Include="Mono.Android" />
     <Reference Include="Mono.Android.Export" />
     <Reference Include="mscorlib" />
-    <Reference Include="System" />
-    <Reference Include="System.Core" />
-    <Reference Include="System.Xml.Linq" />
-    <Reference Include="System.Xml" />
-    <Reference Include="ExoPlayer">
-      <HintPath>..\packages\Xam.Plugins.Android.ExoPlayer.1.5.3\lib\MonoAndroid\ExoPlayer.dll</HintPath>
-    </Reference>
-    <Reference Include="MvvmCross.Platform.Droid">
-      <HintPath>..\packages\MvvmCross.Platform.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Platform.Droid.dll</HintPath>
+    <Reference Include="MvvmCross.Binding, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Binding.4.0.0\lib\MonoAndroid\MvvmCross.Binding.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Platform">
-      <HintPath>..\packages\MvvmCross.Platform.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Platform.dll</HintPath>
+    <Reference Include="MvvmCross.Binding.Droid, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Binding.4.0.0\lib\MonoAndroid\MvvmCross.Binding.Droid.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Localization">
-      <HintPath>..\packages\MvvmCross.Platform.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Localization.dll</HintPath>
+    <Reference Include="MvvmCross.Core, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Core.4.0.0\lib\MonoAndroid\MvvmCross.Core.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Droid">
-      <HintPath>..\packages\MvvmCross.Core.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Droid.dll</HintPath>
+    <Reference Include="MvvmCross.Droid, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Core.4.0.0\lib\MonoAndroid\MvvmCross.Droid.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Core">
-      <HintPath>..\packages\MvvmCross.Core.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Core.dll</HintPath>
+    <Reference Include="MvvmCross.Localization, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Binding.4.0.0\lib\MonoAndroid\MvvmCross.Localization.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Binding.Droid">
-      <HintPath>..\packages\MvvmCross.Binding.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Binding.Droid.dll</HintPath>
+    <Reference Include="MvvmCross.Platform, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Platform.4.0.0\lib\MonoAndroid\MvvmCross.Platform.dll</HintPath>
+      <Private>True</Private>
     </Reference>
-    <Reference Include="MvvmCross.Binding">
-      <HintPath>..\packages\MvvmCross.Binding.4.0.0-beta8\lib\MonoAndroid\MvvmCross.Binding.dll</HintPath>
+    <Reference Include="MvvmCross.Platform.Droid, Version=4.0.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\MvvmCross.Platform.4.0.0\lib\MonoAndroid\MvvmCross.Platform.Droid.dll</HintPath>
+      <Private>True</Private>
     </Reference>
+    <Reference Include="System" />
+    <Reference Include="System.Core" />
+    <Reference Include="System.Xml.Linq" />
+    <Reference Include="System.Xml" />
   </ItemGroup>
   <ItemGroup>
     <Compile Include="Player\MvxExtractorRendererBuilder.cs" />
@@ -77,9 +85,6 @@
   <ItemGroup>
     <AndroidResource Include="Resources\layout\activity_videoplayer.axml" />
   </ItemGroup>
-  <ItemGroup>
-    <None Include="packages.config" />
-  </ItemGroup>
   <Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.
@@ -94,4 +99,7 @@
       <Name>ExoPlayer.Core</Name>
     </ProjectReference>
   </ItemGroup>
+  <ItemGroup>
+    <None Include="packages.config" />
+  </ItemGroup>
 </Project>
\ No newline at end of file
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/MvxVideoPlayerActivity.cs b/Samples/MvvmCross/ExoPlayer.Droid/MvxVideoPlayerActivity.cs
index 56afdd00..1471fafd 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/MvxVideoPlayerActivity.cs
+++ b/Samples/MvvmCross/ExoPlayer.Droid/MvxVideoPlayerActivity.cs
@@ -36,7 +36,6 @@
 using MvvmCross.ExoPlayer.ViewModels;
 using Exception = Java.Lang.Exception;
 using Uri = Android.Net.Uri;
-using MvvmCross.ExoPlayer.ViewModels;
 using MvvmCross.Droid.Views;
 using MvvmCross.Platform.Platform;
 using MvvmCross.Binding.BindingContext;
@@ -338,7 +337,7 @@ public void OnAudioCapabilitiesChanged(AudioCapabilities audioCapabilities)
 
 		private MvxVideoPlayer.IRendererBuilder GetRendererBuilder()
 		{
-			var userAgent = Util.GetUserAgent(this, "ExoPlayerDemo");
+			var userAgent = ExoPlayerUtil.GetUserAgent(this, "ExoPlayerDemo");
 			var url = Item.Url;
 			switch (Item.Type)
 			{
@@ -432,7 +431,7 @@ public void OnError(Exception e)
 			{
 				// TODO
 				// Special case DRM failures.
-				var msg = Util.SdkInt < 18
+				var msg = ExoPlayerUtil.SdkInt < 18
 					? "drm_error_not_supported"
 					: exception.Reason == UnsupportedDrmException.ReasonUnsupportedScheme
 						? "drm_error_unsupported_scheme"
@@ -549,7 +548,7 @@ private void ConfigureSubtitleView()
 		{
 			CaptionStyleCompat style;
 			float fontScale;
-			if (Util.SdkInt >= 19)
+			if (ExoPlayerUtil.SdkInt >= 19)
 			{
 				style = GetUserCaptionStyleV19();
 				fontScale = GetUserCaptionFontScaleV19();
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxExtractorRendererBuilder.cs b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxExtractorRendererBuilder.cs
index e54e1861..7916df4b 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxExtractorRendererBuilder.cs
+++ b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxExtractorRendererBuilder.cs
@@ -17,9 +17,11 @@
 using Android.Content;
 using Android.Media;
 using Android.Net;
+using Android.Net.Rtp;
 using Android.Runtime;
 using Com.Google.Android.Exoplayer;
 using Com.Google.Android.Exoplayer.Audio;
+using Com.Google.Android.Exoplayer.Drm;
 using Com.Google.Android.Exoplayer.Extractor;
 using Com.Google.Android.Exoplayer.Text;
 using Com.Google.Android.Exoplayer.Upstream;
@@ -50,16 +52,17 @@ public void BuildRenderers(MvxVideoPlayer player)
 		{
 			var allocator = new DefaultAllocator(BufferSegmentSize);
 
+
 			// Build the video and audio renderers.
 			var bandwidthMeter = new DefaultBandwidthMeter(player.MainHandler, null);
 			var dataSource = new DefaultUriDataSource(_context, bandwidthMeter, _userAgent);
 			var sampleSource = new ExtractorSampleSource(_uri, dataSource, allocator,
 				BufferSegmentCount*BufferSegmentSize);
 			var videoRenderer = new MediaCodecVideoTrackRenderer(_context,
-				sampleSource, (int) VideoScalingMode.ScaleToFit, 5000, player.MainHandler,
+				sampleSource, MediaCodecSelector.Default, (int) VideoScalingMode.ScaleToFit, 5000, player.MainHandler,
 				player, 50);
-			var audioRenderer = new MediaCodecAudioTrackRenderer(sampleSource,
-				null, true, player.MainHandler, player, AudioCapabilities.GetCapabilities(_context));
+            var audioRenderer = new MediaCodecAudioTrackRenderer(sampleSource,
+                MediaCodecSelector.Default, null, true, player.MainHandler, player, AudioCapabilities.GetCapabilities(_context), (int) Stream.Music);
 			var textRenderer = new TextTrackRenderer(sampleSource, player,
 				player.MainHandler.Looper);
 
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxHlsRendererBuilder.cs b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxHlsRendererBuilder.cs
index d6b8183e..870cabfa 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxHlsRendererBuilder.cs
+++ b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxHlsRendererBuilder.cs
@@ -14,13 +14,11 @@
  * limitations under the License.
  */
 
-using System.Linq;
 using Android.Content;
 using Android.Media;
 using Android.Runtime;
 using Com.Google.Android.Exoplayer;
 using Com.Google.Android.Exoplayer.Audio;
-using Com.Google.Android.Exoplayer.Chunk;
 using Com.Google.Android.Exoplayer.Hls;
 using Com.Google.Android.Exoplayer.Text.Eia608;
 using Com.Google.Android.Exoplayer.Upstream;
@@ -119,37 +117,39 @@ public void OnSingleManifest(Object obj)
 				var mainHandler = _player.MainHandler;
 				var loadControl = new DefaultLoadControl(new DefaultAllocator(BufferSegmentSize));
 				var bandwidthMeter = new DefaultBandwidthMeter();
-
-				int[] variantIndices = null;
-				if (manifest is HlsMasterPlaylist)
-				{
-					var masterPlaylist = (HlsMasterPlaylist) manifest;
-					try
-					{
-						variantIndices = VideoFormatSelectorUtil.SelectVideoFormatsForDefaultDisplay(
-							_context, masterPlaylist.Variants.Cast<IFormatWrapper>().ToList(), null, false);
-					}
-					catch (MediaCodecUtil.DecoderQueryException e)
-					{
-						_player.OnRenderersError(e);
-						return;
-					}
-					if (variantIndices.Length == 0)
-					{
-						_player.OnRenderersError(new IllegalStateException($"No variants selected. Possible reason: your video's resolution could be too high. This device maximum H264 framesize is {MediaCodecUtil.MaxH264DecodableFrameSize()}."));
-						return;
-					}
-				}
-
-				var dataSource = new DefaultUriDataSource(_context, bandwidthMeter, _userAgent);
-				var chunkSource = new HlsChunkSource(dataSource, _url, manifest, bandwidthMeter,
-					variantIndices, HlsChunkSource.AdaptiveModeSplice);
-				var sampleSource = new HlsSampleSource(chunkSource, loadControl,
-					BufferSegments*BufferSegmentSize, mainHandler, _player, MvxVideoPlayer.TypeVideo);
-				var videoRenderer = new MediaCodecVideoTrackRenderer(_context,
-					sampleSource, (int) VideoScalingMode.ScaleToFit, 5000, mainHandler, _player, 50);
-				var audioRenderer = new MediaCodecAudioTrackRenderer(sampleSource,
-					null, true, _player.MainHandler, _player, AudioCapabilities.GetCapabilities(_context));
+                var timestampAdjusterProvider = new PtsTimestampAdjusterProvider();
+
+                var dataSource = new DefaultUriDataSource(_context, bandwidthMeter, _userAgent);
+				var chunkSource = new HlsChunkSource(true
+                    , dataSource
+                    , _url
+                    , manifest
+                    , DefaultHlsTrackSelector.NewDefaultInstance(_context)
+                    , bandwidthMeter
+                    , timestampAdjusterProvider
+                    , HlsChunkSource.AdaptiveModeSplice);
+				var sampleSource = new HlsSampleSource(chunkSource
+                    , loadControl
+                    , BufferSegments*BufferSegmentSize
+                    , mainHandler
+                    , _player
+                    , MvxVideoPlayer.TypeVideo);
+				var videoRenderer = new MediaCodecVideoTrackRenderer(_context
+                    , sampleSource
+                    , MediaCodecSelector.Default
+                    , (int) VideoScalingMode.ScaleToFit
+                    , 5000
+                    , mainHandler
+                    , _player
+                    , 50);
+				var audioRenderer = new MediaCodecAudioTrackRenderer(sampleSource
+                    , MediaCodecSelector.Default
+                    , null
+                    , true
+                    , _player.MainHandler
+                    , _player
+                    , AudioCapabilities.GetCapabilities(_context)
+                    , (int) Stream.Music);
 				// TODO: The Id3Parser is currently not part of the binding
 				//MetadataTrackRenderer id3Renderer = new MetadataTrackRenderer(sampleSource, new Id3Parser(), player, mainHandler.getLooper());
 				var closedCaptionRenderer = new Eia608TrackRenderer(sampleSource, _player,
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxVideoPlayer.cs b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxVideoPlayer.cs
index 6996fc55..46b7b90a 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxVideoPlayer.cs
+++ b/Samples/MvvmCross/ExoPlayer.Droid/Player/MvxVideoPlayer.cs
@@ -681,7 +681,12 @@ private void PushSurface(bool blockForSurfacePush)
 
 		public void OnAudioTrackUnderrun (int p0, long p1, long p2)
 		{
-			throw new System.NotImplementedException ();
-		}
-	}
+            // Do nothing.
+        }
+
+        public void OnAvailableRangeChanged(int p0, ITimeRange p1)
+	    {
+            // Do nothing.
+        }
+    }
 }
\ No newline at end of file
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/Resources/Resource.Designer.cs b/Samples/MvvmCross/ExoPlayer.Droid/Resources/Resource.Designer.cs
index 66b14dcf..3da8f034 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/Resources/Resource.Designer.cs
+++ b/Samples/MvvmCross/ExoPlayer.Droid/Resources/Resource.Designer.cs
@@ -9,7 +9,7 @@
 //  </autogenerated>
 // ------------------------------------------------------------------------------
 
-[assembly: Android.Runtime.ResourceDesignerAttribute("MvvmCross.ExoPlayer.Droid.Resource", IsApplication=false)]
+[assembly: global::Android.Runtime.ResourceDesignerAttribute("MvvmCross.ExoPlayer.Droid.Resource", IsApplication=false)]
 
 namespace MvvmCross.ExoPlayer.Droid
 {
@@ -114,8 +114,7 @@ private Layout()
 		public partial class Styleable
 		{
 			
-			public static int[] MvxBinding = new int[]
-			{
+			public static int[] MvxBinding = new int[] {
 					2130771968,
 					2130771969};
 			
@@ -125,29 +124,25 @@ public partial class Styleable
 			// aapt resource value: 1
 			public static int MvxBinding_MvxLang = 1;
 			
-			public static int[] MvxControl = new int[]
-			{
+			public static int[] MvxControl = new int[] {
 					2130771970};
 			
 			// aapt resource value: 0
 			public static int MvxControl_MvxTemplate = 0;
 			
-			public static int[] MvxExpandableListView = new int[]
-			{
+			public static int[] MvxExpandableListView = new int[] {
 					2130771973};
 			
 			// aapt resource value: 0
 			public static int MvxExpandableListView_MvxGroupItemTemplate = 0;
 			
-			public static int[] MvxImageView = new int[]
-			{
+			public static int[] MvxImageView = new int[] {
 					2130771974};
 			
 			// aapt resource value: 0
 			public static int MvxImageView_MvxSource = 0;
 			
-			public static int[] MvxListView = new int[]
-			{
+			public static int[] MvxListView = new int[] {
 					2130771971,
 					2130771972};
 			
diff --git a/Samples/MvvmCross/ExoPlayer.Droid/packages.config b/Samples/MvvmCross/ExoPlayer.Droid/packages.config
index 6e9cebbf..6c4f085b 100644
--- a/Samples/MvvmCross/ExoPlayer.Droid/packages.config
+++ b/Samples/MvvmCross/ExoPlayer.Droid/packages.config
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="utf-8"?>
 <packages>
-  <package id="MvvmCross" version="4.0.0-beta8" targetFramework="MonoAndroid60" />
-  <package id="MvvmCross.Binding" version="4.0.0-beta8" targetFramework="MonoAndroid60" />
-  <package id="MvvmCross.Core" version="4.0.0-beta8" targetFramework="MonoAndroid60" />
-  <package id="MvvmCross.Platform" version="4.0.0-beta8" targetFramework="MonoAndroid60" />
-  <package id="Xam.Plugins.Android.ExoPlayer" version="1.5.3" targetFramework="MonoAndroid60" />
+  <package id="MvvmCross" version="4.0.0" targetFramework="monoandroid60" />
+  <package id="MvvmCross.Binding" version="4.0.0" targetFramework="monoandroid60" />
+  <package id="MvvmCross.Core" version="4.0.0" targetFramework="monoandroid60" />
+  <package id="MvvmCross.Platform" version="4.0.0" targetFramework="monoandroid60" />
+  <package id="Xam.Plugins.Android.ExoPlayer" version="1.5.6" targetFramework="monoandroid60" />
 </packages>
\ No newline at end of file
diff --git a/Samples/MvvmCross/ExoPlayer.MvvmCross.sln b/Samples/MvvmCross/ExoPlayer.MvvmCross.sln
index cb01aeb2..3ce3bfd1 100644
--- a/Samples/MvvmCross/ExoPlayer.MvvmCross.sln
+++ b/Samples/MvvmCross/ExoPlayer.MvvmCross.sln
@@ -1,6 +1,8 @@
 
 Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 2012
+# Visual Studio 14
+VisualStudioVersion = 14.0.24720.0
+MinimumVisualStudioVersion = 10.0.40219.1
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ExoPlayer.Core", "ExoPlayer.Core\ExoPlayer.Core.csproj", "{BF2EF832-FF56-4342-BB4D-A95C908B3CB7}"
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ExoPlayer.Droid", "ExoPlayer.Droid\ExoPlayer.Droid.csproj", "{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}"
@@ -11,13 +13,16 @@ Global
 		Release|Any CPU = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
-		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Release|Any CPU.Build.0 = Release|Any CPU
 		{BF2EF832-FF56-4342-BB4D-A95C908B3CB7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{BF2EF832-FF56-4342-BB4D-A95C908B3CB7}.Debug|Any CPU.Build.0 = Debug|Any CPU
 		{BF2EF832-FF56-4342-BB4D-A95C908B3CB7}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{BF2EF832-FF56-4342-BB4D-A95C908B3CB7}.Release|Any CPU.Build.0 = Release|Any CPU
+		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{702DC8FE-A697-4FB0-B998-0305AE2E1DF1}.Release|Any CPU.Build.0 = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
 	EndGlobalSection
 EndGlobal