Exemplo n.º 1
0
 public void OnStreamDropped(Session p0, Com.Opentok.Android.Stream p1)
 {
     if (this._subscriber != null)
     {
         UnsubscribeFromStream(p1);
     }
 }
Exemplo n.º 2
0
 public void OnStreamDestroyed(PublisherKit p0, Com.Opentok.Android.Stream p1)
 {
     if ((this._subscriber != null))
     {
         UnsubscribeFromStream(p1);
     }
 }
Exemplo n.º 3
0
 private void SubscribeToStream(Com.Opentok.Android.Stream stream)
 {
     this._subscriber = new Subscriber(this, stream);
     this._subscriber.SetVideoListener(this);
     this._session.Subscribe(_subscriber);
     // start loading spinning
     this._loadingSub.Visibility = ViewStates.Visible;
 }
Exemplo n.º 4
0
 public void OnStreamReceived(Session p0, Com.Opentok.Android.Stream p1)
 {
     this._streams.Add(p1);
     if (this._subscriber == null)
     {
         SubscribeToStream(p1);
     }
 }
Exemplo n.º 5
0
 public void OnStreamCreated(PublisherKit p0, Com.Opentok.Android.Stream p1)
 {
     this._streams.Add(p1);
     //if (this._subscriber == null)
     //{
     //    SubscribeToStream(p1);
     //}
 }
Exemplo n.º 6
0
 private void UnsubscribeFromStream(Com.Opentok.Android.Stream stream)
 {
     this._streams.Remove(stream);
     if (this._subscriber.Stream.StreamId.Equals(stream.StreamId))
     {
         this._subscriberViewContainer.RemoveView(this._subscriber.View);
         this._subscriber = null;
         if (this._streams.Count != 0)
         {
             SubscribeToStream(this._streams[0]);
         }
     }
 }