using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using UIKit;
|
using Foundation;
|
using Shared.IO;
|
|
namespace Shared
|
{
|
/// <summary>
|
/// Button 按键
|
/// </summary>
|
public class Video : View
|
{
|
//VitamioIOSBinding.VMediaPlayer player;
|
/// <summary>
|
/// 当前视图
|
/// </summary>
|
/// <value>The android button.</value>
|
private UIView playUIView
|
{
|
get
|
{
|
return this.uiView as UIView;
|
}
|
set
|
{
|
this.uiView = value;
|
}
|
}
|
|
public Video()
|
{
|
this.playUIView = new UIView { };
|
this.playUIView.Frame = new CoreGraphics.CGRect (0, 0, 1024, 1024);
|
//this.player = VMediaPlayer.SharedInstance ();
|
//player.SetupPlayerWithCarrierView (this.playUIView, new VdoDelegate());
|
//player.SetVideoFillMode (FillMode.Stretch);
|
|
}
|
|
public void init()
|
{
|
//player.SetDataSource (new NSUrl (this.URL));
|
//player.PrepareAsync ();
|
}
|
|
public void Start()
|
{
|
//player.Start ();
|
}
|
|
private string url;
|
|
public string URL
|
{
|
get
|
{
|
return this.url;
|
}
|
set
|
{
|
this.url = value;
|
}
|
}
|
|
public void Stop()
|
{
|
|
}
|
|
}
|
|
// public class VdoDelegate : VitamioIOSBinding.VMediaPlayerDelegate
|
// {
|
// public override void DidPrepared(VMediaPlayer player,NSObject obj)
|
// {
|
// //player.Start ();
|
// }
|
//
|
// public override void PlaybackCompleted(VMediaPlayer player,NSObject obj)
|
// {
|
//
|
// }
|
//
|
// public override void Error(VMediaPlayer player,NSObject obj)
|
// {
|
//
|
// }
|
// }
|
}
|