Esempio n. 1
0
        public DebugNode GetOrCreateChild(string name)
        {
            if (_children.ContainsKey(name))
            {
                return(_children[name]);
            }

            var node = new DebugNode(name);

            _children.Add(name, node);
            return(node);
        }
Esempio n. 2
0
 public void Display(DebugNode node, string value)
 {
     if (node.Widget is StringWidget payload)
     {
         payload.SetValue(value);
     }
     else
     {
         node.Widget = new StringWidget(value);
     }
     node.Touch();
 }
Esempio n. 3
0
        public void Display(DebugNode node, Texture texture)
        {
            if (node.Widget is TextureWidget payload)
            {
                payload.SetValue(texture);
            }
            else
            {
                node.Widget = new TextureWidget(texture);
            }

            node.Touch();
        }
Esempio n. 4
0
        public void Display(DebugNode node, Texture texture)
        {
            var payload = node.Widget as TextureWidget;

            if (payload != null)
            {
                payload.SetValue(texture);
            }
            else
            {
                node.Widget = new TextureWidget(texture);
            }

            node.Touch();
        }
Esempio n. 5
0
        public void Display(DebugNode node, string value)
        {
            var payload = node.Widget as StringWidget;

            if (payload != null)
            {
                payload.SetValue(value);
            }
            else
            {
                // New payload
                node.Widget = new StringWidget(value);
            }

            node.Touch();
        }
Esempio n. 6
0
        public void Log(DebugNode node, string message)
        {
            if (node.Widget is Logger payload)
            {
                // Existing payload
                payload.Log(message);
            }
            else
            {
                // New payload
                var p = new Logger();
                p.Log(message);
                node.Widget = p;
            }

            node.Touch();
        }
Esempio n. 7
0
        public void Log(DebugNode node, string message)
        {
            var payload = node.Widget as Logger;

            if (payload != null)
            {
                // Existing payload
                payload.Log(message);
            }
            else
            {
                // New payload
                var p = new Logger();
                p.Log(message);
                node.Widget = p;
            }

            node.Touch();
        }
Esempio n. 8
0
 public void Display(DebugNode node, Vector2 size, Action <Rect> drawAction)
 {
     node.Widget = new CustomUIWidget(size, drawAction);
     node.Touch();
 }
Esempio n. 9
0
 public void Display(DebugNode node, float value)
 {
     Display(node, value.ToString(CultureInfo.InvariantCulture));
 }
Esempio n. 10
0
 public void Display(DebugNode node, float value)
 {
     Display(node, value.ToString());
 }