Пример #1
0
        private void addButtonsForSource(string name, TestAudioPlayingSource source)
        {
            AddStep($"play track on {name}", source.PlayTrack);
            AddStep($"stop track on {name}", source.StopTrack);
            AddStep($"play sample on {name}", source.PlaySample);

            if (source != globalSource)
            {
                AddStep($"remove mixer {name}", () => source.Expire());
            }
        }
Пример #2
0
        protected override void LoadComplete()
        {
            base.LoadComplete();

            addButtonsForSource("global", globalSource);

            AddStep("add mixer", () =>
            {
                var source = new TestAudioPlayingSource(true);
                mixedSources.Add(source);
                addButtonsForSource($"mixer {mixedSources.Count}", source);
            });
        }