mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 23:05:04 +01:00
change the way the key editor gets populated; drop binding sets with no actions
This commit is contained in:
parent
694c7254e1
commit
a06a5ecfd6
5 changed files with 15 additions and 39 deletions
|
|
@ -114,7 +114,13 @@ void
|
|||
KeyEditor::add_tab (string const & name, Bindings& bindings)
|
||||
{
|
||||
Tab* t = new Tab (*this, name, &bindings);
|
||||
t->populate ();
|
||||
|
||||
if (t->populate () == 0) {
|
||||
/* no bindings */
|
||||
delete t;
|
||||
return;
|
||||
}
|
||||
|
||||
t->show_all ();
|
||||
notebook.append_page (*t, name);
|
||||
}
|
||||
|
|
@ -135,6 +141,7 @@ KeyEditor::remove_tab (string const &name)
|
|||
}
|
||||
}
|
||||
}
|
||||
cerr << "Removed " << name << endl;
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -305,7 +312,7 @@ KeyEditor::Tab::bind (GdkEventKey* release_event, guint pressed_key)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
uint32_t
|
||||
KeyEditor::Tab::populate ()
|
||||
{
|
||||
vector<string> paths;
|
||||
|
|
@ -395,6 +402,8 @@ KeyEditor::Tab::populate ()
|
|||
}
|
||||
row[columns.action] = *a;
|
||||
}
|
||||
|
||||
return data_model->children().size();
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue