void SetActivity() { CallPageActivity = this.Context as Activity; CallView = CallPageActivity.LayoutInflater.Inflate(Resource.Layout.activity_call, this, false); FullScreenRenderer = CallView.FindViewById <SurfaceViewRenderer>(Resource.Id.fullscreen_video_view); PipScreenRenderer = CallView.FindViewById <SurfaceViewRenderer>(Resource.Id.pip_video_view); CallFragment = CreateCallFragment(CallPageActivity.Intent); LocalVideoRenderer = new PlatformVideoRenderer(); RemoteVideoRenderer = new PlatformVideoRenderer(); PipScreenRenderer.Click += PipScreenRenderer_Click; PipScreenRenderer.SetScalingType(RendererCommon.ScalingType.ScaleAspectFit); PipScreenRenderer.SetZOrderMediaOverlay(true); PipScreenRenderer.SetEnableHardwareScaler(true); FullScreenRenderer.Click += FullScreenRenderer_Click; FullScreenRenderer.SetScalingType(RendererCommon.ScalingType.ScaleAspectFill); FullScreenRenderer.SetEnableHardwareScaler(false); SetSwappedFeeds(true); var fragmentTransaction = MainActivity.Instance.SupportFragmentManager.BeginTransaction(); fragmentTransaction.Add(Resource.Id.call_fragment_container, CallFragment); fragmentTransaction.Commit(); CallController = CreateController(); Connect(CallController, CallPageActivity.Intent); }
// Método para lançar o evento que envia o result para a view protected virtual void OnCallView(Result result) { CallView?.Invoke(this, new ResultMessageEventArgs() { Result = result }); }
protected override void OnLayout(bool changed, int left, int top, int right, int bottom) { base.OnLayout(changed, left, top, right, bottom); var msw = MeasureSpec.MakeMeasureSpec(right - left, MeasureSpecMode.Exactly); var msh = MeasureSpec.MakeMeasureSpec(bottom - top, MeasureSpecMode.Exactly); CallView.Measure(msw, msh); CallView.Layout(0, 0, right - left, bottom - top); }
public Call() { InitializeComponent(); CallView model = ObjectPool.Instance.Resolve <CallView>(); if (this.DataContext == null && model != null) { this.DataContext = model; } }
private void LoadContent() { var calls = _csvReader.GetList(); foreach (Call call in calls) { CallView callsGameObject = Instantiate(_callPrefab, _parent.transform); callsGameObject.Caller = call.Caller; callsGameObject.Time = call.CallTime; callsGameObject.Amount = call.AmountOfCalls; } }
public CallForm(IAudioCall call) { InitializeComponent(); _call = call; _call.ModifyCallStyle(MyCallStyle.AudioVideo); _call.StartCamera(); _call.ConnectMedia(); CallView callView = new CallView(); this.Controls.Add(callView); this.Size = callView.Size; callView.SetRemoteProvider(_call.GetRemoteProvider()); callView.SetLocalProvider(_call.GetLocalProvider()); }
public MainWindowViewModel(ServerConfiguration serverConfiguration, MessageCollaborator messageCollection, ApplicationSettings applicationSettings, GeneralView generalView, CallView callView, PortView portView, SMSView smsView) { this.serverConfiguration = serverConfiguration; this.messageCollection = messageCollection; this.applicationSettings = applicationSettings; this.generalView = generalView; this.callView = callView; this.portView = portView; this.smsView = smsView; }