/[svn]/gigedit/trunk/src/gigedit/mainwindow.cpp
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/mainwindow.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3807 by schoenebeck, Fri Aug 14 10:54:44 2020 UTC revision 3808 by schoenebeck, Fri Aug 14 11:24:09 2020 UTC
# Line 3728  void MainWindow::show_midi_rules() Line 3728  void MainWindow::show_midi_rules()
3728    
3729  void MainWindow::show_script_slots() {  void MainWindow::show_script_slots() {
3730      if (!file) return;      if (!file) return;
3731    
3732      // get selected instrument      // get selected instrument
3733      std::vector<Gtk::TreeModel::Path> rows = m_TreeViewInstruments.get_selection()->get_selected_rows();      gig::Instrument* instrument = get_instrument();
     if (rows.empty()) return;  
     Gtk::TreeModel::iterator it = m_refInstrumentsTreeModel->get_iter(rows[0]);  
     if (!it) return;  
     Gtk::TreeModel::Row row = *it;  
     gig::Instrument* instrument = row[m_InstrumentsModel.m_col_instr];  
3734      if (!instrument) return;      if (!instrument) return;
3735    
3736      ScriptSlots* window = new ScriptSlots;      ScriptSlots* window = new ScriptSlots;

Legend:
Removed from v.3807  
changed lines
  Added in v.3808

  ViewVC Help
Powered by ViewVC