public SoundLineConnectionUI(SoundLineConnection connection) { InitializeComponent(); this.connection = connection; name.Content = connection.input; volume.Value = connection.volume; }
private void Line_inputAdded(int index, SoundLineConnection input) { Dispatcher.BeginInvoke((Action)(() => { var ui = new SoundLineConnectionUI(input); InputsList.Children.Insert(index, ui); })); }
private void LineInput_AddButton_Click(object sender, RoutedEventArgs e) { if (selectedLine?.Line != null) { var connection = new SoundLineConnection(Project.current.lines.IndexOf(selectedLine.Line), LineInput_AddSelect.Selected, 1); connection.input.outputs.Add(connection); connection.output.inputs.Add(connection); } }