Example #1
0
 public void RemoveItem(InputProcedural item)
 {
     item.ValueChanged -= OnValueChanged;
     item.ConnectedNode = null;
     inputs.Remove(item);
     OnInputPositionsChanged();
     OnValueChanged();
 }
Example #2
0
        public void MoveDown(InputProcedural input)
        {
            int index = inputs.IndexOf(input);

            if (index < inputs.Count - 1)
            {
                inputs[index]     = inputs[index + 1];
                inputs[index + 1] = input;
                OnInputPositionsChanged();
                OnValueChanged();
            }
        }
Example #3
0
        public void MoveUp(InputProcedural input)
        {
            int index = inputs.IndexOf(input);

            if (index > 0)
            {
                inputs[index]     = inputs[index - 1];
                inputs[index - 1] = input;
                OnInputPositionsChanged();
                OnValueChanged();
            }
        }
Example #4
0
        public void AddItem(INodeOutput node = null)
        {
            var newInput = new InputProcedural()
            {
                Title = this.Title
            };

            newInput.ConnectedNode = node;
            newInput.ValueChanged += OnValueChanged;
            inputs.Add(newInput);
            OnInputPositionsChanged();
            OnValueChanged();
        }