public void InitProjectOption(Project project) { m_CurrentProject = project; if (project == Project.Empty) { m_NameText.text = String.Empty; m_OrganizationText.text = String.Empty; m_DateText.text = String.Empty; m_ServerText.text = String.Empty; m_DownloadButton.interactable = false; m_DeleteButton.interactable = false; return; } var organizationName = project.UnityProject.Organization?.Name; if (string.IsNullOrEmpty(organizationName)) { organizationName = "None"; } m_NameText.text = project.name; m_ServerText.text = project.description; m_OrganizationText.text = organizationName; m_DateText.text = project.lastPublished.ToShortDateString(); m_DownloadButton.interactable = project.isAvailableOnline; m_DeleteButton.interactable = ReflectPipelineFactory.HasLocalData(project); }
public void SetUser(UnityUser user) { if (user == null || string.IsNullOrEmpty(user.UserId)) { Debug.LogError("Invalid User"); } // Storage var storage = new PlayerStorage(ProjectServer.ProjectDataPath, true, false); // Client m_AuthClient = new AuthClient(user, storage); ReflectPipelineFactory.SetUser(user, this, m_AuthClient, storage); }
void InitProjectOption(Project project) { if (project == Project.Empty) { m_NameText.text = String.Empty; m_StatusText.text = String.Empty; m_DateText.text = String.Empty; m_ServerText.text = String.Empty; m_DownloadButton.interactable = false; m_DeleteButton.interactable = false; return; } m_NameText.text = project.name; m_StatusText.text = string.Empty; // TODO m_DateText.text = project.lastPublished.ToShortDateString(); m_ServerText.text = project.description; m_DownloadButton.interactable = project.isAvailableOnline; m_DeleteButton.interactable = ReflectPipelineFactory.HasLocalData(project); }
public void ClearUser() { ReflectPipelineFactory.ClearUser(); }