private void LogoutAsync(bool sendServerLogout) { try { this.TabNavigation = KeyboardNavigationMode.Cycle; m_mainPageBorder.Content = m_topCanvas; if (sendServerLogout) { m_authorisedPersistor.LogoutAsync(); } m_authId = null; m_userPage = null; UpdateAppStatus(); } catch (Exception excp) { m_userPage.LogActivityMessage(MessageLevelsEnum.Error, "Exception LogoutAsync. " + excp.Message); } }
private void Authenticated(string username, string authID) { UIHelper.SetText(m_provisioningStatusMessage, "Initialising..."); UIHelper.SetFill(m_appStatusIcon, Colors.Blue); m_owner = username; m_loginControl.Clear(); m_createAccountControl.Reset(); UIHelper.SetVisibility(m_createAccountControl, Visibility.Collapsed); m_userPage = new UserPage(LogoutAsync, m_owner, m_notificationsServiceURL, m_riaContext); m_mainPageBorder.Content = m_userPage; UpdateAppStatus(); }
private void Authenticated(string username, string authID) { UIHelper.SetText(m_provisioningStatusMessage, "Initialising..."); UIHelper.SetFill(m_appStatusIcon, Colors.Blue); //m_loginControl.DisableNewAccounts(null); m_owner = username; m_authId = authID; #if !BLEND m_authorisedPersistor = SIPSorceryPersistorFactory.CreateSIPSorceryPersistor(SIPPersistorTypesEnum.WebService, m_provisioningServiceURL, m_authId); #else m_authorisedPersistor = SIPSorceryPersistorFactory.CreateSIPSorceryPersistor(SIPPersistorTypesEnum.GUITest, m_provisioningServiceURL, m_authId); #endif m_authorisedPersistor.SessionExpired += SessionExpired; m_authorisedPersistor.LogoutComplete += LogoutComplete; m_authorisedPersistor.GetTimeZoneOffsetMinutesComplete += GetTimeZoneOffsetMinutesComplete; m_authorisedPersistor.GetTimeZoneOffsetMinutesAsync(); m_loginControl.Clear(); //m_loginControl.DisableNewAccounts(null); m_createAccountControl.Clear(); UIHelper.SetVisibility(m_createAccountControl, Visibility.Collapsed); m_userPage = new UserPage(m_authorisedPersistor, LogoutAsync, m_owner, m_authId, m_notificationsServiceURL); m_mainPageBorder.Content = m_userPage; UpdateAppStatus(); }
private void LogoutAsync(bool sendServerLogout) { try { this.TabNavigation = KeyboardNavigationMode.Cycle; m_mainPageBorder.Content = m_topCanvas; if (sendServerLogout) { m_riaContext.Load<User>(m_riaContext.LogoutQuery(), LoadBehavior.RefreshCurrent, LogoutComplete, null); } m_userPage = null; UpdateAppStatus(); } catch (Exception excp) { m_userPage.LogActivityMessage(MessageLevelsEnum.Error, "Exception LogoutAsync. " + excp.Message); } }