Exemplo n.º 1
0
        private MyDebugNode CreateDebugNode(IMyExecutable executable)
        {
            MyDebugNode result;

            if (executable is MyTask)
            {
                result = new MyDebugTaskNode(executable as MyTask);
            }
            else
            {
                result = new MyDebugNode(executable);
            }

            if (executable is MyExecutionBlock)
            {
                foreach (IMyExecutable child in (executable as MyExecutionBlock).Children)
                {
                    if (child is MySignalTask)
                    {
                        if (showSignalsButton.Checked)
                        {
                            result.Nodes.Add(CreateDebugNode(child));
                        }
                    }
                    else if (showDisabledTasksButton.Checked || child.Enabled)
                    {
                        result.Nodes.Add(CreateDebugNode(child));
                    }
                }
            }

            return result;
        }
Exemplo n.º 2
0
        private MyDebugNode CreateDebugNode(IMyExecutable executable)
        {
            MyDebugNode result;

            if (executable is MyTask)
            {
                result = new MyDebugTaskNode(executable as MyTask);
            }
            else
            {
                result = new MyDebugNode(executable);
            }

            if (executable is MyExecutionBlock)
            {
                foreach (IMyExecutable child in (executable as MyExecutionBlock).Children)
                {
                    if (child is MySignalTask)
                    {
                        if (showSignalsButton.Checked)
                        {
                            result.Nodes.Add(CreateDebugNode(child));
                        }
                    }
                    else if (showDisabledTasksButton.Checked || child.Enabled)
                    {
                        result.Nodes.Add(CreateDebugNode(child));
                    }
                }
            }

            return(result);
        }
Exemplo n.º 3
0
        private MyDebugNode CreateDebugNode(IMyExecutable executable)
        {
            MyDebugNode result;

            if (executable is MyTask)
            {
                result = new MyDebugTaskNode(executable as MyTask, () => m_mainForm.TaskView.RefreshView());
            }
            else
            {
                result = new MyDebugNode(executable);
            }

            var executableBlock = executable as MyExecutionBlock;

            if (executableBlock != null)
            {
                foreach (IMyExecutable child in executableBlock.Children)
                {
                    if (child is MySignalTask)
                    {
                        if (showSignalsButton.Checked)
                        {
                            result.Nodes.Add(CreateDebugNode(child));
                        }
                    }
                    else if (showDisabledTasksButton.Checked || child.Enabled)
                    {
                        result.Nodes.Add(CreateDebugNode(child));
                    }
                }
            }

            result.BreakpointStateChanged += OnBreakpointStateChanged;

            return(result);
        }
Exemplo n.º 4
0
        private MyDebugNode CreateDebugNode(IMyExecutable executable)
        {
            MyDebugNode result;

            if (executable is MyTask)
            {
                result = new MyDebugTaskNode(executable as MyTask);
            }
            else
            {
                result = new MyDebugNode(executable);
            }

            var executableBlock = executable as MyExecutionBlock;
            if (executableBlock != null)
            {
                foreach (IMyExecutable child in executableBlock.Children)
                {
                    if (child is MySignalTask)
                    {
                        if (showSignalsButton.Checked)
                        {
                            result.Nodes.Add(CreateDebugNode(child));
                        }
                    }
                    else if (showDisabledTasksButton.Checked || child.Enabled)
                    {
                        result.Nodes.Add(CreateDebugNode(child));
                    }
                }
            }

            result.BreakpointStateChanged += OnBreakpointStateChanged;

            return result;
        }