Beispiel #1
0
        public void NavigateTo(NodeModel node)
        {
            if (node.ObjType == XObjType.Class || node.ObjType == XObjType.Internal)
            {
                SelectedNode               = node;
                FieldFilter                = null;
                SummaryLabel.Text          = node.Name;
                SummaryLabel.ForeColor     = ColorProfile.ClassColor;
                FieldsRadioButton.Visible  = true;
                MethodsRadioButton.Visible = true;
            }
            else if (node.ObjType == XObjType.Field)
            {
                SelectedNode               = node.GetParentClass(false);
                FieldFilter                = node.XNode.UnformattedName;
                SummaryLabel.Text          = node.Name;
                SummaryLabel.ForeColor     = ColorProfile.FieldColor;
                FieldsRadioButton.Visible  = false;
                MethodsRadioButton.Visible = false;
                FieldsRadioButton.Checked  = true;
            }
            else
            {
                SummaryLabel.Text = "";
                return;
            }

            Model = new InstanceModel(SelectedNode.XNode, FieldFilter, GridModel_UpdateTree, GridModel_ExpandedField);

            XRay.UIs[Thread.CurrentThread.ManagedThreadId].CurrentInstance = Model;

            FieldGrid.Nodes.Clear();
            FieldGrid.Columns.Clear();

            if (!Visible)
            {
                return;
            }

            CurrentDisplay = SelectedNode;

            ModelRowMap = new Dictionary <int, FieldRow>();

            Model.BeginUpdateTree(false);

            RefreshSubnodesView();
        }
        public FieldModel(InstanceModel instance, FieldModel parent, RowTypes type)
        {
            Instance = instance;
            RowType = type;

            Nodes = new List<IFieldModel>();
            Cells = new List<string>();

            ID = Instance.RndGen.Next();
            Instance.FieldMap[ID] = this;

            if (parent == null)
                return;

            ParentField = parent;
            Instances = parent.Instances;
        }
Beispiel #3
0
        public FieldModel(InstanceModel instance, FieldModel parent, RowTypes type)
        {
            Instance = instance;
            RowType  = type;

            Nodes = new List <IFieldModel>();
            Cells = new List <string>();

            ID = Instance.RndGen.Next();
            Instance.FieldMap[ID] = this;

            if (parent == null)
            {
                return;
            }

            ParentField = parent;
            Instances   = parent.Instances;
        }
        public void NavigateTo(NodeModel node)
        {
            if (node.ObjType == XObjType.Class)
            {
                SelectedNode = node;
                FieldFilter = null;
                SummaryLabel.Text = node.Name;
                SummaryLabel.ForeColor = ColorProfile.ClassColor;
                FieldsRadioButton.Visible = true;
                MethodsRadioButton.Visible = true;
            }
            else if (node.ObjType == XObjType.Field)
            {
                SelectedNode = node.GetParentClass(false);
                FieldFilter = node.XNode.UnformattedName;
                SummaryLabel.Text = node.Name;
                SummaryLabel.ForeColor = ColorProfile.FieldColor;
                FieldsRadioButton.Visible = false;
                MethodsRadioButton.Visible = false;
                FieldsRadioButton.Checked = true;
            }
            else
            {
                SummaryLabel.Text = "";
                return;
            }

            Model = new InstanceModel(SelectedNode.XNode, FieldFilter, GridModel_UpdateTree, GridModel_ExpandedField);

            XRay.UIs[Thread.CurrentThread.ManagedThreadId].CurrentInstance = Model;

            if (!Visible)
                return;

            CurrentDisplay = SelectedNode;

            FieldGrid.Nodes.Clear();
            FieldGrid.Columns.Clear();

            ModelRowMap = new Dictionary<int, FieldRow>();

            Model.BeginUpdateTree(false);

            RefreshSubnodesView();
        }
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, Type type)
     : this(grid, parent, rowType)
 {
     FieldType = type;
 }
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, FieldInfo info)
     : this(grid, parent, rowType, info.FieldType)
 {
     TypeInfo = info;
 }
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, Type type, int elementIndex)
     : this(grid, parent, rowType, type)
 {
     ElementIndex = elementIndex;
 }
Beispiel #8
0
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, FieldInfo info)
     : this(grid, parent, rowType, info.FieldType)
 {
     TypeInfo = info;
 }
Beispiel #9
0
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, Type type, int elementIndex)
     : this(grid, parent, rowType, type)
 {
     ElementIndex = elementIndex;
 }
Beispiel #10
0
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, Type type)
     : this(grid, parent, rowType)
 {
     FieldType = type;
 }
Beispiel #11
0
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, PropertyInfo info)
     : this(grid, parent, rowType, info.PropertyType)
 {
     PropertyInfo = info;
 }
Beispiel #12
0
 public FieldModel(InstanceModel grid, FieldModel parent, RowTypes rowType, PropertyInfo info)
     : this(grid, parent, rowType, info.PropertyType)
 {
     PropertyInfo = info;
 }