public override bool HasReferencedProject(Project project)
        {
            if (this.IsLoaded)
            {
                return(GameProjectContent.CheckReferenceProjectInObject(this.RootVisualObject as NodeObject, project));
            }
            if (this.Content == null || this.Content.ObjectData == null)
            {
                return(false);
            }
            ResourceData resourceData = project.GetResourceData();

            return(GameProjectContent.CheckReferenceProjectInObjectData(this.Content.ObjectData, project, resourceData));
        }
        private static bool CheckReferenceProjectInObject(NodeObject parentNode, Project project)
        {
            bool result;

            if (parentNode == null)
            {
                result = false;
            }
            else
            {
                ProjectNodeObject projectNodeObject = parentNode as ProjectNodeObject;
                if (projectNodeObject != null)
                {
                    ResourceFile fileData = projectNodeObject.FileData;
                    if (fileData == project)
                    {
                        result = true;
                        return(result);
                    }
                    if (projectNodeObject.Project != null)
                    {
                        bool flag = projectNodeObject.Project.HasReferencedProject(project);
                        if (flag)
                        {
                            result = true;
                            return(result);
                        }
                    }
                }
                if (parentNode.Children != null)
                {
                    foreach (NodeObject current in parentNode.Children)
                    {
                        bool flag2 = GameProjectContent.CheckReferenceProjectInObject(current, project);
                        if (flag2)
                        {
                            result = true;
                            return(result);
                        }
                    }
                }
                result = false;
            }
            return(result);
        }
        public override bool HasReferencedProject(Project project)
        {
            bool result;

            if (this.IsLoaded)
            {
                result = GameProjectContent.CheckReferenceProjectInObject(this.RootVisualObject as NodeObject, project);
            }
            else if (this.Content == null || this.Content.ObjectData == null)
            {
                result = false;
            }
            else
            {
                ResourceData resourceData = project.GetResourceData();
                result = GameProjectContent.CheckReferenceProjectInObjectData(this.Content.ObjectData, project, resourceData);
            }
            return(result);
        }
        private static bool CheckReferenceProjectInObject(NodeObject parentNode, Project project)
        {
            if (parentNode == null)
            {
                return(false);
            }
            ProjectNodeObject projectNodeObject = parentNode as ProjectNodeObject;

            if (projectNodeObject != null && (projectNodeObject.FileData == project || projectNodeObject.Project != null && projectNodeObject.Project.HasReferencedProject(project)))
            {
                return(true);
            }
            if (parentNode.Children != null)
            {
                foreach (NodeObject child in (Collection <NodeObject>)parentNode.Children)
                {
                    if (GameProjectContent.CheckReferenceProjectInObject(child, project))
                    {
                        return(true);
                    }
                }
            }
            return(false);
        }