private async void CommunicationService_Packet0003Received(object sender, Packet0003ReceivedEventArgs e) { if (e.IsLoginSuccess) { ProgressRing_Information.IsActive = false; TextBlock_Message.Text = "로그인에 성공하였습니다"; NotificationStoryboard.RepeatBehavior = new RepeatBehavior(1); NotificationStoryboard.Begin(); OnLoginSuccessStoryboard.Begin(); } else { OnLoginFailedStoryboard.Begin(); ContentDialog dialog = new ContentDialog() { Title = "로그인 실패", Content = $"{e.Message}", CloseButtonText = "닫기", DefaultButton = ContentDialogButton.Close }; dialog.Loading += async(send, args) => await this.Blur(value : 5, duration : 1000, delay : 0).StartAsync(); dialog.Closing += async(send, args) => await this.Blur(value : 0, duration : 500, delay : 0).StartAsync(); await dialog.ShowAsync(); } }
private void CommunicationService_Packet0003Received(object sender, Packet0003ReceivedEventArgs e) { UserName = e.UserName; if (e.IsLoginSuccess) { LoginEnable = false; LogoutEnable = true; Singleton <CommunicationService> .Instance.RequestMoveGroup(UserID, CurrentLocation.Init.ToString(), CurrentLocation.None.ToString()); Singleton <GGTService> .Instance.UserId = e.Request.UserID; Singleton <GGTService> .Instance.UserName = e.Response.UserName; } else { LoginEnable = true; Singleton <GGTService> .Instance.UserId = String.Empty; Singleton <GGTService> .Instance.UserName = String.Empty; } }