public void UnsetInspectorTab() { if (m_activeInspector == null) { return; } m_activeInspector.SetInactive(); ColorBlock colors = m_activeInspector.tabButton.colors; colors.normalColor = new Color(0.2f, 0.2f, 0.2f, 1); colors.highlightedColor = new Color(0.1f, 0.3f, 0.1f, 1); m_activeInspector.tabButton.colors = colors; m_activeInspector = null; }
public void SetInspectorTab(InspectorBase inspector) { MainMenu.Instance.SetPage(SLPacksPage.Instance); if (m_activeInspector == inspector) { return; } UnsetInspectorTab(); m_activeInspector = inspector; inspector.SetActive(); Color activeColor = new Color(0, 0.25f, 0, 1); ColorBlock colors = inspector.tabButton.colors; colors.normalColor = activeColor; colors.highlightedColor = activeColor; inspector.tabButton.colors = colors; }