Clean up existing bindings on reset

This commit is contained in:
Robin Gareus 2017-03-13 20:09:10 +01:00
parent 333e3c6019
commit 9cc068756b
2 changed files with 2 additions and 0 deletions

View file

@ -213,6 +213,7 @@ class LIBGTKMM2EXT_API Bindings {
std::vector<Glib::RefPtr<Gtk::Action> >& actions);
/* all bindings currently in existence, as grouped into Bindings */
static void reset_bindings () { bindings.clear (); }
static std::list<Bindings*> bindings;
static Bindings* get_bindings (std::string const& name, ActionMap&);
static void associate_all ();

View file

@ -722,6 +722,7 @@ Keyboard::reset_bindings ()
{
PBD::Unwinder<bool> uw (can_save_keybindings, false);
Bindings::reset_bindings ();
setup_keybindings ();
Bindings::associate_all ();
}