private void RemoveLastDialog(Action_RemoveLastDialog act) { if (UserView.subViews_DialogWithUser.Count > 0) { ViewStateManager.Delete(UserView.subViews_DialogWithUser[UserView.subViews_DialogWithUser.Count - 1]); _SubDialogs.Remove(UserView.subViews_DialogWithUser[UserView.subViews_DialogWithUser.Count - 1]); UserView.subViews_DialogWithUser.RemoveAt(UserView.subViews_DialogWithUser.Count - 1); if (this.UserView.subViews_DialogWithUser.Count < 1) { this.UserView.boolProp_isActionPossible_RemoveLastDialog = false; } if (this.UserView.subViews_DialogWithUser.Count < 5) { this.UserView.boolProp_isActionPossible_AddNewDialog = true; } } }