Exemplo n.º 1
0
        //- callbacks -----------------------------------------------------------------

        public void updatePatchList(VSTRig rig)
        {
            cbxPatchList.Items.Clear();
            cbxPatchList.Text = "";
            foreach (Patch patch in rig.patches)
            {
                cbxPatchList.Items.Add(patch.name);
            }
            bool enabled = (cbxPatchList.Items.Count > 0);

            cbxPatchList.Enabled       = enabled;
            btnPrevPatch.Enabled       = enabled;
            btnNextPatch.Enabled       = enabled;
            cbxPatchList.SelectedIndex = (enabled && rig.currentPatch != null) ? cbxPatchList.FindString(rig.currentPatch.name) : -1;
            if (rig.currentPatch == rig.newPatch)
            {
                cbxPatchList.Text = rig.newPatch.name;
            }
        }
Exemplo n.º 2
0
        int vstnum;         //for debugging

        public ControlPanel(AudimatWindow _auditwin)
        {
            auditwin = _auditwin;

            //init backend
            vashti      = new Vashti();
            host        = new VSTHost(vashti);
            midiDevices = new MidiSystem();

            InitializeComponent();

            //child windows
            patchNameWnd = null;

            //model
            currentRig     = null;
            curRigFilename = null;
            curRigPath     = Application.StartupPath;
            curPluginPath  = Application.StartupPath;

            vstnum = 0;

            isRunning = false;
        }