UnityEditor.HierarchyProperty.Parent C# (CSharp) Method

Parent() private method

private Parent ( ) : bool
return bool
        public extern bool Parent();
        [MethodImpl(MethodImplOptions.InternalCall)]

Usage Example

示例#1
0
        private float DoSearchResultPathGUI()
        {
            if (!base.hasSearchFilter)
            {
                return(0f);
            }
            GUILayout.FlexibleSpace();
            Rect rect = EditorGUILayout.BeginVertical(EditorStyles.inspectorBig, new GUILayoutOption[0]);

            GUILayout.Label("Path:", new GUILayoutOption[0]);
            if (this.m_TreeView.HasSelection())
            {
                int instanceID = this.m_TreeView.GetSelection()[0];
                IHierarchyProperty property = new HierarchyProperty(HierarchyType.GameObjects);
                property.Find(instanceID, null);
                if (property.isValid)
                {
                    do
                    {
                        EditorGUILayout.BeginHorizontal(new GUILayoutOption[0]);
                        GUILayout.Label(property.icon, new GUILayoutOption[0]);
                        GUILayout.Label(property.name, new GUILayoutOption[0]);
                        GUILayout.FlexibleSpace();
                        EditorGUILayout.EndHorizontal();
                    }while (property.Parent());
                }
            }
            EditorGUILayout.EndVertical();
            GUILayout.Space(0f);
            return(rect.height);
        }
All Usage Examples Of UnityEditor.HierarchyProperty::Parent