예제 #1
0
        private void SessionCreatorComplete_StartInvitingFriend(AsyncLiveOperation op)
        {
            openingSharingRoomMessage.Deactivate();
            openingInviteGuideMessage.Deactivate();

            // We needed to create a session before sending out an invitation to our friend.
            // If we're here, then the session create process is complete.
            UIGridShareFriendElement shareHubElement = op.Param as UIGridShareFriendElement;

            if (op.Succeeded)
            {
                // Session was created, start inviting the friend.

                SessionCreator createOp = op as SessionCreator;

                LiveManager.Session = createOp.Session;
                createOp.Session    = null; // avoid session dispose

                LiveManager.Session.GamerJoined += shared.Session_GamerJoined;
                LiveManager.Session.GamerLeft   += shared.Session_GamerLeft;

                StartInvitingFriend(shareHubElement);
            }
            else
            {
                // TODO: show a message about the failure.
            }
        }
예제 #2
0
        }   // end of Update()

        public void DeactivateMenu(ModularMessageDialog dialog)
        {
            //close the dialog
            dialog.Deactivate();
            Deactivate();
        }