private void JoinRequested(RemoteSystemSessionController sender, RemoteSystemSessionJoinRequestedEventArgs args) { Debug.WriteLine("joinrequested"); var deferral = args.GetDeferral(); Debug.WriteLine(args.JoinRequest.Participant); args.JoinRequest.Accept(); //ParticipantJoined(this, new ParticipantJoinedEventArgs() { Participant = args.JoinRequest.Participant }); deferral.Complete(); }
private void Manager_JoinRequested(RemoteSystemSessionController sender, RemoteSystemSessionJoinRequestedEventArgs args) { var deferral = args.GetDeferral(); SendDebugMessage($"Added the participant {args.JoinRequest.Participant.RemoteSystem.DisplayName} to the session {m_currentSessionName}."); args.JoinRequest.Accept(); ParticipantJoined(this, new ParticipantJoinedEventArgs() { Participant = args.JoinRequest.Participant }); deferral.Complete(); }
private async void SessionController_JoinRequested(RemoteSystemSessionController sender, RemoteSystemSessionJoinRequestedEventArgs args) { var deferral = args.GetDeferral(); var remoteSystem = args.JoinRequest.Participant.RemoteSystem; await dispatcher.RunAsync(CoreDispatcherPriority.Normal, async() => { var dialog = new MessageDialog($"do you access {remoteSystem.DisplayName} to join the session?"); dialog.Commands.Add(new UICommand("Accept", (cmd) => { args.JoinRequest.Accept(); })); dialog.Commands.Add(new UICommand("Abort")); dialog.DefaultCommandIndex = 0; await dialog.ShowAsync(); }); deferral.Complete(); }
private static void OnSessionControllerJoinRequested(RemoteSystemSessionController sender, RemoteSystemSessionJoinRequestedEventArgs args) { args.JoinRequest.Accept(); DebugString($"Join Requested {args.JoinRequest.Participant.RemoteSystem.Id}: {args.JoinRequest.Participant.GetHostNames()[0]}"); }