3757 |
|
|
3758 |
// causes the sampler to reload the instrument with the new script |
// causes the sampler to reload the instrument with the new script |
3759 |
on_sel_change(); |
on_sel_change(); |
3760 |
|
|
3761 |
|
// force script 'patch' variables editor ("Script" tab) to be refreshed |
3762 |
|
dimreg_edit.scriptVars.setInstrument(pInstrument, true/*force update*/); |
3763 |
} |
} |
3764 |
|
|
3765 |
void MainWindow::assignScript(gig::Script* pScript) { |
void MainWindow::assignScript(gig::Script* pScript) { |
4570 |
editor->signal_script_to_be_changed.connect( |
editor->signal_script_to_be_changed.connect( |
4571 |
signal_script_to_be_changed.make_slot() |
signal_script_to_be_changed.make_slot() |
4572 |
); |
); |
4573 |
editor->signal_script_changed.connect( |
editor->signal_script_changed.connect([this](gig::Script* script) { |
4574 |
signal_script_changed.make_slot() |
// signal to sampler (which will reload the script due to this) |
4575 |
); |
signal_script_changed.emit(script); |
4576 |
|
// force script 'patch' variables editor ("Script" tab) to be refreshed |
4577 |
|
gig::Instrument* instr = get_instrument(); |
4578 |
|
dimreg_edit.scriptVars.setInstrument(instr, true/*force update*/); |
4579 |
|
}); |
4580 |
editor->setScript(script); |
editor->setScript(script); |
4581 |
//editor->reparent(*this); |
//editor->reparent(*this); |
4582 |
editor->show(); |
editor->show(); |
5340 |
if (!iter) return; |
if (!iter) return; |
5341 |
Gtk::TreeModel::Row row = *iter; |
Gtk::TreeModel::Row row = *iter; |
5342 |
gig::Script* script = row[m_ScriptsModel.m_col_script]; |
gig::Script* script = row[m_ScriptsModel.m_col_script]; |
5343 |
if (!script) return; |
editScript(script); |
|
|
|
|
ScriptEditor* editor = new ScriptEditor; |
|
|
editor->signal_script_to_be_changed.connect( |
|
|
signal_script_to_be_changed.make_slot() |
|
|
); |
|
|
editor->signal_script_changed.connect( |
|
|
signal_script_changed.make_slot() |
|
|
); |
|
|
editor->setScript(script); |
|
|
//editor->reparent(*this); |
|
|
editor->show(); |
|
5344 |
} |
} |
5345 |
|
|
5346 |
void MainWindow::instrument_name_changed(const Gtk::TreeModel::Path& path, |
void MainWindow::instrument_name_changed(const Gtk::TreeModel::Path& path, |