Exemplo n.º 1
0
        private void DrawDocumentationLink()
        {
            var width   = m_documentationLink.CalcSize().x + 5f;
            var clicked = m_documentationLink.Draw(GUILayout.Width(width));

            if (clicked)
            {
                Application.OpenURL(m_documentationUrl);
            }
        }
        protected void DrawDocumnetationLink()
        {
            float width   = m_documentationLink.CalcSize().x + 5f;
            bool  clicked = m_documentationLink.Draw(GUILayout.Width(width));

            if (clicked)
            {
                Application.OpenURL(m_documentationUrl);
            }
        }
Exemplo n.º 3
0
        public void OnGUI()
        {
            GUILayout.Space(5);
            using (new SA_GuiBeginHorizontal()) {
                GUILayout.Space(10);

                var content = m_collapsedContent;
                if (m_showExtraFields.target)
                {
                    content = m_expandedContent;
                }

                m_arrrow.SetContent(content);
                bool arClick = m_arrrow.Draw(GUILayout.Width(20));
                GUILayout.Space(-5);

                float headerWidth = m_header.CalcSize().x;
                bool  click       = m_header.Draw(GUILayout.Width(headerWidth));
                if (click || arClick)
                {
                    m_showExtraFields.target = !m_showExtraFields.target;
                }

                OnAfterHeaderGUI();
            }
            using (new SA_GuiHorizontalSpace(10)) {
                if (EditorGUILayout.BeginFadeGroup(m_showExtraFields.faded))
                {
                    GUILayout.Space(5);
                    m_onGUI.Invoke();
                    GUILayout.Space(5);
                }
                EditorGUILayout.EndFadeGroup();
            }


            GUILayout.Space(5);
            EditorGUILayout.BeginVertical(SA_PluginSettingsWindowStyles.SeparationStyle);
            GUILayout.Space(5);
            EditorGUILayout.EndVertical();
        }