32 |
#include <glibmm/dispatcher.h> |
#include <glibmm/dispatcher.h> |
33 |
#include <glibmm/miscutils.h> |
#include <glibmm/miscutils.h> |
34 |
#include <glibmm/stringutils.h> |
#include <glibmm/stringutils.h> |
35 |
|
#include <glibmm/regex.h> |
36 |
#include <gtkmm/aboutdialog.h> |
#include <gtkmm/aboutdialog.h> |
37 |
#include <gtkmm/filechooserdialog.h> |
#include <gtkmm/filechooserdialog.h> |
38 |
#include <gtkmm/messagedialog.h> |
#include <gtkmm/messagedialog.h> |
88 |
{ |
{ |
89 |
loadBuiltInPix(); |
loadBuiltInPix(); |
90 |
|
|
91 |
|
this->file = NULL; |
92 |
|
|
93 |
// set_border_width(5); |
// set_border_width(5); |
94 |
|
|
95 |
if (!Settings::singleton()->autoRestoreWindowDimension) { |
if (!Settings::singleton()->autoRestoreWindowDimension) { |
122 |
|
|
123 |
m_TreeViewNotebook.set_size_request(300); |
m_TreeViewNotebook.set_size_request(300); |
124 |
|
|
125 |
m_HPaned.add1(m_TreeViewNotebook); |
m_searchLabel.set_text(Glib::ustring(" ") + _("Filter:")); |
126 |
|
m_searchField.pack_start(m_searchLabel, Gtk::PACK_SHRINK); |
127 |
|
m_searchField.pack_start(m_searchText); |
128 |
|
m_searchField.set_spacing(5); |
129 |
|
|
130 |
|
m_left_vbox.pack_start(m_TreeViewNotebook); |
131 |
|
m_left_vbox.pack_start(m_searchField, Gtk::PACK_SHRINK); |
132 |
|
|
133 |
|
m_HPaned.add1(m_left_vbox); |
134 |
|
|
135 |
dimreg_hbox.add(dimreg_label); |
dimreg_hbox.add(dimreg_label); |
136 |
dimreg_hbox.add(dimreg_all_regions); |
dimreg_hbox.add(dimreg_all_regions); |
137 |
dimreg_hbox.add(dimreg_all_dimregs); |
dimreg_hbox.add(dimreg_all_dimregs); |
233 |
sigc::mem_fun(*this, &MainWindow::show_scripts_tab) |
sigc::mem_fun(*this, &MainWindow::show_scripts_tab) |
234 |
); |
); |
235 |
actionGroup->add(Gtk::Action::create("AllInstruments", _("_Select"))); |
actionGroup->add(Gtk::Action::create("AllInstruments", _("_Select"))); |
236 |
|
actionGroup->add(Gtk::Action::create("AssignScripts", _("Assign Script"))); |
237 |
|
|
238 |
actionGroup->add(Gtk::Action::create("MenuEdit", _("_Edit"))); |
actionGroup->add(Gtk::Action::create("MenuEdit", _("_Edit"))); |
239 |
|
|
259 |
Gtk::AccelKey(GDK_KEY_x, Gdk::MOD1_MASK), |
Gtk::AccelKey(GDK_KEY_x, Gdk::MOD1_MASK), |
260 |
sigc::mem_fun(*this, &MainWindow::adjust_clipboard_content)); |
sigc::mem_fun(*this, &MainWindow::adjust_clipboard_content)); |
261 |
|
|
262 |
|
actionGroup->add(Gtk::Action::create("SelectPrevInstr", |
263 |
|
_("Select Previous Instrument")), |
264 |
|
Gtk::AccelKey(GDK_KEY_Up, primaryModifierKey), |
265 |
|
sigc::mem_fun(*this, &MainWindow::select_prev_instrument)); |
266 |
|
|
267 |
|
actionGroup->add(Gtk::Action::create("SelectNextInstr", |
268 |
|
_("Select Next Instrument")), |
269 |
|
Gtk::AccelKey(GDK_KEY_Down, primaryModifierKey), |
270 |
|
sigc::mem_fun(*this, &MainWindow::select_next_instrument)); |
271 |
|
|
272 |
actionGroup->add(Gtk::Action::create("SelectPrevRegion", |
actionGroup->add(Gtk::Action::create("SelectPrevRegion", |
273 |
_("Select Previous Region")), |
_("Select Previous Region")), |
274 |
Gtk::AccelKey(GDK_KEY_Left, primaryModifierKey), |
Gtk::AccelKey(GDK_KEY_Left, primaryModifierKey), |
497 |
" <menuitem action='AdjustClipboard'/>" |
" <menuitem action='AdjustClipboard'/>" |
498 |
" <menuitem action='PasteDimRgn'/>" |
" <menuitem action='PasteDimRgn'/>" |
499 |
" <separator/>" |
" <separator/>" |
500 |
|
" <menuitem action='SelectPrevInstr'/>" |
501 |
|
" <menuitem action='SelectNextInstr'/>" |
502 |
|
" <separator/>" |
503 |
" <menuitem action='SelectPrevRegion'/>" |
" <menuitem action='SelectPrevRegion'/>" |
504 |
" <menuitem action='SelectNextRegion'/>" |
" <menuitem action='SelectNextRegion'/>" |
505 |
" <separator/>" |
" <separator/>" |
534 |
" <menuitem action='InstrProperties'/>" |
" <menuitem action='InstrProperties'/>" |
535 |
" <menuitem action='MidiRules'/>" |
" <menuitem action='MidiRules'/>" |
536 |
" <menuitem action='ScriptSlots'/>" |
" <menuitem action='ScriptSlots'/>" |
537 |
|
" <menu action='AssignScripts'/>" |
538 |
" <menuitem action='AddInstrument'/>" |
" <menuitem action='AddInstrument'/>" |
539 |
" <menuitem action='DupInstrument'/>" |
" <menuitem action='DupInstrument'/>" |
540 |
" <menuitem action='CombInstruments'/>" |
" <menuitem action='CombInstruments'/>" |
669 |
instrument_menu = static_cast<Gtk::MenuItem*>( |
instrument_menu = static_cast<Gtk::MenuItem*>( |
670 |
uiManager->get_widget("/MenuBar/MenuInstrument/AllInstruments"))->get_submenu(); |
uiManager->get_widget("/MenuBar/MenuInstrument/AllInstruments"))->get_submenu(); |
671 |
|
|
672 |
|
assign_scripts_menu = static_cast<Gtk::MenuItem*>( |
673 |
|
uiManager->get_widget("/MenuBar/MenuInstrument/AssignScripts"))->get_submenu(); |
674 |
|
|
675 |
Gtk::Widget* menuBar = uiManager->get_widget("/MenuBar"); |
Gtk::Widget* menuBar = uiManager->get_widget("/MenuBar"); |
676 |
m_VBox.pack_start(*menuBar, Gtk::PACK_SHRINK); |
m_VBox.pack_start(*menuBar, Gtk::PACK_SHRINK); |
677 |
m_VBox.pack_start(m_HPaned); |
m_VBox.pack_start(m_HPaned); |
695 |
|
|
696 |
// Create the Tree model: |
// Create the Tree model: |
697 |
m_refTreeModel = Gtk::ListStore::create(m_Columns); |
m_refTreeModel = Gtk::ListStore::create(m_Columns); |
698 |
m_TreeView.set_model(m_refTreeModel); |
m_refTreeModelFilter = Gtk::TreeModelFilter::create(m_refTreeModel); |
699 |
|
m_refTreeModelFilter->set_visible_func( |
700 |
|
sigc::mem_fun(*this, &MainWindow::instrument_row_visible) |
701 |
|
); |
702 |
|
m_TreeView.set_model(m_refTreeModelFilter); |
703 |
|
|
704 |
m_TreeView.get_selection()->set_mode(Gtk::SELECTION_MULTIPLE); |
m_TreeView.get_selection()->set_mode(Gtk::SELECTION_MULTIPLE); |
705 |
m_TreeView.set_tooltip_text(_("Right click here for actions on instruments & MIDI Rules. Drag & drop to change the order of instruments.")); |
m_TreeView.set_tooltip_text(_("Right click here for actions on instruments & MIDI Rules. Drag & drop to change the order of instruments.")); |
706 |
instrument_name_connection = m_refTreeModel->signal_row_changed().connect( |
instrument_name_connection = m_refTreeModel->signal_row_changed().connect( |
876 |
dimreg_stereo.signal_toggled().connect( |
dimreg_stereo.signal_toggled().connect( |
877 |
sigc::mem_fun(*this, &MainWindow::update_dimregs)); |
sigc::mem_fun(*this, &MainWindow::update_dimregs)); |
878 |
|
|
879 |
|
m_searchText.signal_changed().connect( |
880 |
|
sigc::mem_fun(m_refTreeModelFilter.operator->(), &Gtk::TreeModelFilter::refilter) |
881 |
|
); |
882 |
|
|
883 |
file = 0; |
file = 0; |
884 |
file_is_changed = false; |
file_is_changed = false; |
885 |
|
|
888 |
// start with a new gig file by default |
// start with a new gig file by default |
889 |
on_action_file_new(); |
on_action_file_new(); |
890 |
|
|
891 |
|
m_TreeViewNotebook.signal_switch_page().connect( |
892 |
|
sigc::mem_fun(*this, &MainWindow::on_notebook_tab_switched) |
893 |
|
); |
894 |
|
|
895 |
// select 'Instruments' tab by default |
// select 'Instruments' tab by default |
896 |
// (gtk allows this only if the tab childs are visible, thats why it's here) |
// (gtk allows this only if the tab childs are visible, thats why it's here) |
897 |
m_TreeViewNotebook.set_current_page(1); |
m_TreeViewNotebook.set_current_page(1); |
929 |
updateMacroMenu(); |
updateMacroMenu(); |
930 |
} |
} |
931 |
|
|
932 |
|
// setup "Assign Scripts" keyboard accelerators |
933 |
|
{ |
934 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_0", GDK_KEY_F1, Gdk::SHIFT_MASK); |
935 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_1", GDK_KEY_F2, Gdk::SHIFT_MASK); |
936 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_2", GDK_KEY_F3, Gdk::SHIFT_MASK); |
937 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_3", GDK_KEY_F4, Gdk::SHIFT_MASK); |
938 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_4", GDK_KEY_F5, Gdk::SHIFT_MASK); |
939 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_5", GDK_KEY_F6, Gdk::SHIFT_MASK); |
940 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_6", GDK_KEY_F7, Gdk::SHIFT_MASK); |
941 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_7", GDK_KEY_F8, Gdk::SHIFT_MASK); |
942 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_8", GDK_KEY_F9, Gdk::SHIFT_MASK); |
943 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_9", GDK_KEY_F10, Gdk::SHIFT_MASK); |
944 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_10", GDK_KEY_F11, Gdk::SHIFT_MASK); |
945 |
|
Gtk::AccelMap::add_entry("<Scripts>/script_11", GDK_KEY_F12, Gdk::SHIFT_MASK); |
946 |
|
|
947 |
|
Glib::RefPtr<Gtk::AccelGroup> accelGroup = this->get_accel_group(); |
948 |
|
assign_scripts_menu->set_accel_group(accelGroup); |
949 |
|
} |
950 |
|
|
951 |
Glib::signal_idle().connect_once( |
Glib::signal_idle().connect_once( |
952 |
sigc::mem_fun(*this, &MainWindow::bringToFront), |
sigc::mem_fun(*this, &MainWindow::bringToFront), |
953 |
200 |
200 |
1064 |
updateMacroMenu(); |
updateMacroMenu(); |
1065 |
} |
} |
1066 |
|
|
1067 |
|
//NOTE: the actual signal's first argument for argument 'page' is on some gtkmm version GtkNotebookPage* and on some Gtk::Widget*. Since we don't need that argument, it is simply void* here for now. |
1068 |
|
void MainWindow::on_notebook_tab_switched(void* page, guint page_num) { |
1069 |
|
bool isInstrumentsPage = (page_num == 1); |
1070 |
|
// so far we only support filtering for the instruments list, so hide the |
1071 |
|
// filter text entry field if another tab is selected |
1072 |
|
m_searchField.set_visible(isInstrumentsPage); |
1073 |
|
} |
1074 |
|
|
1075 |
bool MainWindow::on_delete_event(GdkEventAny* event) |
bool MainWindow::on_delete_event(GdkEventAny* event) |
1076 |
{ |
{ |
1077 |
return !file_is_shared && file_is_changed && !close_confirmation_dialog(); |
return !file_is_shared && file_is_changed && !close_confirmation_dialog(); |
1172 |
} |
} |
1173 |
} |
} |
1174 |
|
|
1175 |
|
updateScriptListOfMenu(); |
1176 |
|
|
1177 |
m_RegionChooser.set_instrument(get_instrument()); |
m_RegionChooser.set_instrument(get_instrument()); |
1178 |
|
|
1179 |
if (Settings::singleton()->syncSamplerInstrumentSelection) { |
if (Settings::singleton()->syncSamplerInstrumentSelection) { |
2075 |
eGainPlus6(_("Gain +6dB"), eAttenuation, -6), |
eGainPlus6(_("Gain +6dB"), eAttenuation, -6), |
2076 |
eEffectSend(_("Effect send"), 0, 65535), |
eEffectSend(_("Effect send"), 0, 65535), |
2077 |
eFineTune(_("Fine tune"), -8400, 8400), |
eFineTune(_("Fine tune"), -8400, 8400), |
2078 |
ePitchbendRange(_("Pitchbend range"), 0, 12), |
ePitchbendRange(_("Pitchbend range"), 0, 48), |
2079 |
ePianoReleaseMode(_("Piano release mode")), |
ePianoReleaseMode(_("Piano release mode")), |
2080 |
eDimensionKeyRangeLow(_("Keyswitching range low")), |
eDimensionKeyRangeLow(_("Keyswitching range low")), |
2081 |
eDimensionKeyRangeHigh(_("Keyswitching range high")) |
eDimensionKeyRangeHigh(_("Keyswitching range high")) |
2366 |
if (!pInstrument) return; |
if (!pInstrument) return; |
2367 |
const int iScriptSlots = pInstrument->ScriptSlotCount(); |
const int iScriptSlots = pInstrument->ScriptSlotCount(); |
2368 |
|
|
2369 |
Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
//NOTE: This is a big mess! Sometimes GTK requires m_TreeView.get_model(), here we need m_refTreeModelFilter->get_model(), otherwise accessing children below causes an error! |
2370 |
|
//Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
2371 |
|
Glib::RefPtr<Gtk::TreeModel> model = m_refTreeModelFilter->get_model(); |
2372 |
|
|
2373 |
for (int i = 0; i < model->children().size(); ++i) { |
for (int i = 0; i < model->children().size(); ++i) { |
2374 |
Gtk::TreeModel::Row row = model->children()[i]; |
Gtk::TreeModel::Row row = model->children()[i]; |
2375 |
if (row[m_Columns.m_col_instr] != pInstrument) continue; |
if (row[m_Columns.m_col_instr] != pInstrument) continue; |
2376 |
row[m_Columns.m_col_scripts] = iScriptSlots ? ToString(iScriptSlots) : ""; |
row[m_Columns.m_col_scripts] = iScriptSlots ? ToString(iScriptSlots) : ""; |
2377 |
break; |
break; |
2378 |
} |
} |
2379 |
|
|
2380 |
|
// causes the sampler to reload the instrument with the new script |
2381 |
|
on_sel_change(); |
2382 |
|
} |
2383 |
|
|
2384 |
|
void MainWindow::assignScript(gig::Script* pScript) { |
2385 |
|
if (!pScript) { |
2386 |
|
printf("assignScript() : !script\n"); |
2387 |
|
return; |
2388 |
|
} |
2389 |
|
printf("assignScript('%s')\n", pScript->Name.c_str()); |
2390 |
|
|
2391 |
|
gig::Instrument* pInstrument = get_instrument(); |
2392 |
|
if (!pInstrument) { |
2393 |
|
printf("!instrument\n"); |
2394 |
|
return; |
2395 |
|
} |
2396 |
|
|
2397 |
|
pInstrument->AddScriptSlot(pScript); |
2398 |
|
|
2399 |
|
onScriptSlotsModified(pInstrument); |
2400 |
} |
} |
2401 |
|
|
2402 |
void MainWindow::on_action_refresh_all() { |
void MainWindow::on_action_refresh_all() { |
2501 |
void MainWindow::select_instrument(gig::Instrument* instrument) { |
void MainWindow::select_instrument(gig::Instrument* instrument) { |
2502 |
if (!instrument) return; |
if (!instrument) return; |
2503 |
|
|
2504 |
|
//NOTE: This is a big mess! Sometimes GTK requires m_refTreeModelFilter->get_model(), here we need m_TreeView.get_model(), otherwise treeview selection below causes an error! |
2505 |
Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
2506 |
|
//Glib::RefPtr<Gtk::TreeModel> model = m_refTreeModelFilter->get_model(); |
2507 |
|
|
2508 |
for (int i = 0; i < model->children().size(); ++i) { |
for (int i = 0; i < model->children().size(); ++i) { |
2509 |
Gtk::TreeModel::Row row = model->children()[i]; |
Gtk::TreeModel::Row row = model->children()[i]; |
2510 |
if (row[m_Columns.m_col_instr] == instrument) { |
if (row[m_Columns.m_col_instr] == instrument) { |
2526 |
gig::Region* pRegion = (gig::Region*) dimRgn->GetParent(); |
gig::Region* pRegion = (gig::Region*) dimRgn->GetParent(); |
2527 |
gig::Instrument* pInstrument = (gig::Instrument*) pRegion->GetParent(); |
gig::Instrument* pInstrument = (gig::Instrument*) pRegion->GetParent(); |
2528 |
|
|
2529 |
|
//NOTE: This is a big mess! Sometimes GTK requires m_refTreeModelFilter->get_model(), here we need m_TreeView.get_model(), otherwise treeview selection below causes an error! |
2530 |
Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
Glib::RefPtr<Gtk::TreeModel> model = m_TreeView.get_model(); |
2531 |
|
//Glib::RefPtr<Gtk::TreeModel> model = m_refTreeModelFilter->get_model(); |
2532 |
|
|
2533 |
for (int i = 0; i < model->children().size(); ++i) { |
for (int i = 0; i < model->children().size(); ++i) { |
2534 |
Gtk::TreeModel::Row row = model->children()[i]; |
Gtk::TreeModel::Row row = model->children()[i]; |
2535 |
if (row[m_Columns.m_col_instr] == pInstrument) { |
if (row[m_Columns.m_col_instr] == pInstrument) { |
2677 |
} |
} |
2678 |
} |
} |
2679 |
|
|
2680 |
|
void MainWindow::updateScriptListOfMenu() { |
2681 |
|
// remove all entries from "Assign Script" menu |
2682 |
|
{ |
2683 |
|
const std::vector<Gtk::Widget*> children = assign_scripts_menu->get_children(); |
2684 |
|
for (int i = 0; i < children.size(); ++i) { |
2685 |
|
Gtk::Widget* child = children[i]; |
2686 |
|
assign_scripts_menu->remove(*child); |
2687 |
|
delete child; |
2688 |
|
} |
2689 |
|
} |
2690 |
|
|
2691 |
|
int iTotalScripts = 0; |
2692 |
|
|
2693 |
|
if (!file) goto noScripts; |
2694 |
|
|
2695 |
|
// add all configured macros as menu items to the "Macro" menu |
2696 |
|
for (int iGroup = 0; file->GetScriptGroup(iGroup); ++iGroup) { |
2697 |
|
gig::ScriptGroup* pGroup = file->GetScriptGroup(iGroup); |
2698 |
|
for (int iScript = 0; pGroup->GetScript(iScript); ++iScript, ++iTotalScripts) { |
2699 |
|
gig::Script* pScript = pGroup->GetScript(iScript); |
2700 |
|
std::string name = pScript->Name; |
2701 |
|
|
2702 |
|
Gtk::MenuItem* item = new Gtk::MenuItem(name); |
2703 |
|
item->signal_activate().connect( |
2704 |
|
sigc::bind( |
2705 |
|
sigc::mem_fun(*this, &MainWindow::assignScript), pScript |
2706 |
|
) |
2707 |
|
); |
2708 |
|
assign_scripts_menu->append(*item); |
2709 |
|
item->set_accel_path("<Scripts>/script_" + ToString(iTotalScripts)); |
2710 |
|
//item->set_tooltip_text(comment); |
2711 |
|
} |
2712 |
|
} |
2713 |
|
|
2714 |
|
noScripts: |
2715 |
|
|
2716 |
|
// if there are no macros configured at all, then show a dummy entry instead |
2717 |
|
if (!iTotalScripts) { |
2718 |
|
Gtk::MenuItem* item = new Gtk::MenuItem(_("No Scripts")); |
2719 |
|
item->set_sensitive(false); |
2720 |
|
assign_scripts_menu->append(*item); |
2721 |
|
} |
2722 |
|
|
2723 |
|
assign_scripts_menu->show_all_children(); |
2724 |
|
} |
2725 |
|
|
2726 |
Gtk::RadioMenuItem* MainWindow::add_instrument_to_menu( |
Gtk::RadioMenuItem* MainWindow::add_instrument_to_menu( |
2727 |
const Glib::ustring& name, int position) { |
const Glib::ustring& name, int position) { |
2728 |
|
|
2769 |
instrument_name_connection.unblock(); |
instrument_name_connection.unblock(); |
2770 |
|
|
2771 |
add_instrument_to_menu(name); |
add_instrument_to_menu(name); |
2772 |
|
select_instrument(instrument); |
|
m_TreeView.get_selection()->select(iterInstr); |
|
|
|
|
2773 |
file_changed(); |
file_changed(); |
2774 |
} |
} |
2775 |
|
|
3739 |
} |
} |
3740 |
} |
} |
3741 |
|
|
3742 |
|
bool MainWindow::instrument_row_visible(const Gtk::TreeModel::const_iterator& iter) { |
3743 |
|
if (!iter) |
3744 |
|
return true; |
3745 |
|
|
3746 |
|
Glib::ustring pattern = m_searchText.get_text().lowercase(); |
3747 |
|
trim(pattern); |
3748 |
|
if (pattern.empty()) return true; |
3749 |
|
|
3750 |
|
Gtk::TreeModel::Row row = *iter; |
3751 |
|
Glib::ustring name = row[m_Columns.m_col_name]; |
3752 |
|
name = name.lowercase(); |
3753 |
|
|
3754 |
|
std::vector<Glib::ustring> tokens = Glib::Regex::split_simple(" ", pattern); |
3755 |
|
for (int t = 0; t < tokens.size(); ++t) |
3756 |
|
if (name.find(tokens[t]) == Glib::ustring::npos) |
3757 |
|
return false; |
3758 |
|
|
3759 |
|
return true; |
3760 |
|
} |
3761 |
|
|
3762 |
void MainWindow::on_action_combine_instruments() { |
void MainWindow::on_action_combine_instruments() { |
3763 |
CombineInstrumentsDialog* d = new CombineInstrumentsDialog(*this, file); |
CombineInstrumentsDialog* d = new CombineInstrumentsDialog(*this, file); |
3764 |
|
|
4041 |
m_TreeViewNotebook.set_current_page(2); |
m_TreeViewNotebook.set_current_page(2); |
4042 |
} |
} |
4043 |
|
|
4044 |
|
void MainWindow::select_instrument_by_dir(int dir) { |
4045 |
|
if (!file) return; |
4046 |
|
gig::Instrument* pInstrument = get_instrument(); |
4047 |
|
if (!pInstrument) { |
4048 |
|
select_instrument( file->GetInstrument(0) ); |
4049 |
|
return; |
4050 |
|
} |
4051 |
|
for (int i = 0; file->GetInstrument(i); ++i) { |
4052 |
|
if (file->GetInstrument(i) == pInstrument) { |
4053 |
|
select_instrument( file->GetInstrument(i + dir) ); |
4054 |
|
return; |
4055 |
|
} |
4056 |
|
} |
4057 |
|
} |
4058 |
|
|
4059 |
|
void MainWindow::select_prev_instrument() { |
4060 |
|
select_instrument_by_dir(-1); |
4061 |
|
} |
4062 |
|
|
4063 |
|
void MainWindow::select_next_instrument() { |
4064 |
|
select_instrument_by_dir(1); |
4065 |
|
} |
4066 |
|
|
4067 |
void MainWindow::select_prev_region() { |
void MainWindow::select_prev_region() { |
4068 |
m_RegionChooser.select_prev_region(); |
m_RegionChooser.select_prev_region(); |
4069 |
} |
} |