Beispiel #1
0
 public OrnamentsForm(XmlReader r, PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
 {
     _isLoading = true;
     InitializeOrnamentSettingsForm(r, paletteForm, acForm, fsf);
     _fsf.SetSettingsAreSaved(this, M.HasError(_allTextBoxes), ConfirmButton, RevertToSavedButton);
     _isLoading = false;
 }
Beispiel #2
0
 public OrnamentsForm(XmlReader r, PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
 {
     _isLoading = true;
     InitializeOrnamentSettingsForm(r, paletteForm, acForm, fsf);
     _fsf.SetSettingsAreSaved(this, M.HasError(_allTextBoxes), ConfirmButton, RevertToSavedButton);
     _isLoading = false;
 }
Beispiel #3
0
        /// <summary>
        /// Creates a new, empty PalettesForm with help texts adjusted for the given domain.
        /// </summary>
        /// <param name="assistantComposer"></param>
        /// <param name="krystal"></param>
        public PaletteForm(IPaletteFormsHostForm hostForm, string name, int domain, FormStateFunctions fsf)
        {
            InitializeComponent();
            _hostForm = hostForm;
            Text = name;
            _savedName = name;
            _domain = domain;
            _fsf = fsf;
            _isLoading = true;
            ConnectBasicChordControl();
            if(M.Preferences.CurrentMultimediaMidiOutputDevice != null)
            {
                ConnectPaletteButtonsControl(domain, _hostForm.LocalScoreAudioPath);
            }

            _allTextBoxes = GetAllTextBoxes();

            TouchAllTextBoxes();

            SetDialogForDomain(domain);

            ShowOrnamentSettingsButton.Enabled = false;
            DeleteOrnamentSettingsButton.Enabled = false;

            _fsf.SetFormState(this, SavedState.unconfirmed);
            _isLoading = false;
            ConfirmButton.Enabled = false;
            RevertToSavedButton.Enabled = false;
            RevertToSavedButton.Hide();
        }
Beispiel #4
0
        /// <summary>
        /// Creates a new, empty PalettesForm with help texts adjusted for the given domain.
        /// </summary>
        /// <param name="assistantComposer"></param>
        /// <param name="krystal"></param>
        public PaletteForm(IPaletteFormsHostForm hostForm, string name, int domain, FormStateFunctions fsf)
        {
            InitializeComponent();
            _hostForm  = hostForm;
            Text       = name;
            _savedName = name;
            _domain    = domain;
            _fsf       = fsf;
            _isLoading = true;
            ConnectBasicChordControl();
            if (M.Preferences.CurrentMultimediaMidiOutputDevice != null)
            {
                ConnectPaletteButtonsControl(domain, _hostForm.LocalScoreAudioPath);
            }

            _allTextBoxes = GetAllTextBoxes();

            TouchAllTextBoxes();

            SetDialogForDomain(domain);

            ShowOrnamentSettingsButton.Enabled   = false;
            DeleteOrnamentSettingsButton.Enabled = false;

            _fsf.SetFormState(this, SavedState.unconfirmed);
            _isLoading                  = false;
            ConfirmButton.Enabled       = false;
            RevertToSavedButton.Enabled = false;
            RevertToSavedButton.Hide();
        }
Beispiel #5
0
        public OrnamentsForm(PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
        {
            InitializeOrnamentSettingsForm(null, paletteForm, acForm, fsf);

            _fsf.SetFormState(this, SavedState.unconfirmed);
            ConfirmButton.Enabled = false;
            RevertToSavedButton.Enabled = false;
            RevertToSavedButton.Hide();
        }
Beispiel #6
0
        public OrnamentsForm(PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
        {
            InitializeOrnamentSettingsForm(null, paletteForm, acForm, fsf);

            _fsf.SetFormState(this, SavedState.unconfirmed);
            ConfirmButton.Enabled       = false;
            RevertToSavedButton.Enabled = false;
            RevertToSavedButton.Hide();
        }
Beispiel #7
0
        public PaletteForm(XmlReader r, IPaletteFormsHostForm hostForm, string name, int domain, bool isPercussionPalette, FormStateFunctions fsf)
            : this(hostForm, name, domain, fsf)
        {
            _isLoading = true;
            ReadPalette(r);
            this.PercussionCheckBox.Checked = isPercussionPalette;
            this.ModulationWheelEnvelopesLabel.Focus();

            if(this._ornamentsForm != null)
            {
                ShowOrnamentSettingsButton.Enabled = true;
                DeleteOrnamentSettingsButton.Enabled = true;
            }

            _fsf.SetSettingsAreSaved(this, M.HasError(_allTextBoxes), ConfirmButton, RevertToSavedButton);
            _isLoading = false;
        }
Beispiel #8
0
        public PaletteForm(XmlReader r, IPaletteFormsHostForm hostForm, string name, int domain, bool isPercussionPalette, FormStateFunctions fsf)
            : this(hostForm, name, domain, fsf)
        {
            _isLoading = true;
            ReadPalette(r);
            this.PercussionCheckBox.Checked = isPercussionPalette;
            this.ModulationWheelEnvelopesLabel.Focus();

            if (this._ornamentsForm != null)
            {
                ShowOrnamentSettingsButton.Enabled   = true;
                DeleteOrnamentSettingsButton.Enabled = true;
            }

            _fsf.SetSettingsAreSaved(this, M.HasError(_allTextBoxes), ConfirmButton, RevertToSavedButton);
            _isLoading = false;
        }
Beispiel #9
0
        private void InitializeOrnamentSettingsForm(XmlReader r, PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
        {
            InitializeComponent();
            _paletteForm           = paletteForm;
            _fsf                   = fsf;
            _assistantComposerForm = acForm;
            ConnectBasicChordControl();

            Text = paletteForm.SavedName + " : ornaments";
            if (r != null)
            {
                _numberOfBasicChordDefs = ReadOrnamentSettingsForm(r);
            }

            _allNonOrnamentTextBoxes = GetNonOrnamentTextBoxes();
            _12OrnamentTextBoxes     = Get12OrnamentTextBoxes();
            _allTextBoxes            = new List <TextBox>();
            _allTextBoxes.AddRange(_allNonOrnamentTextBoxes);
            _allTextBoxes.AddRange(_12OrnamentTextBoxes);

            NumBasicChordDefsTextBox_Leave(NumBasicChordDefsTextBox, null);
            TouchAllTextBoxes();
        }
Beispiel #10
0
        private void InitializeOrnamentSettingsForm(XmlReader r, PaletteForm paletteForm, IPaletteFormsHostForm acForm, FormStateFunctions fsf)
        {
            InitializeComponent();
            _paletteForm = paletteForm;
            _fsf = fsf;
            _assistantComposerForm = acForm;
            ConnectBasicChordControl();

            Text = paletteForm.SavedName + " : ornaments";
            if(r != null)
            {
                _numberOfBasicChordDefs = ReadOrnamentSettingsForm(r);
            }

            _allNonOrnamentTextBoxes = GetNonOrnamentTextBoxes();
            _12OrnamentTextBoxes = Get12OrnamentTextBoxes();
            _allTextBoxes = new List<TextBox>();
            _allTextBoxes.AddRange(_allNonOrnamentTextBoxes);
            _allTextBoxes.AddRange(_12OrnamentTextBoxes);

            NumBasicChordDefsTextBox_Leave(NumBasicChordDefsTextBox, null);
            TouchAllTextBoxes();
        }