#include "pbd/strsplit.h"
+#include "ardour/filesystem_paths.h"
#include "ardour/profile.h"
#include "actions.h"
scroller.add (view);
scroller.set_policy (Gtk::POLICY_NEVER, Gtk::POLICY_AUTOMATIC);
- add (vpacker);
-
vpacker.set_spacing (6);
+ vpacker.set_border_width (12);
vpacker.pack_start (scroller);
if (!ARDOUR::Profile->get_sae()) {
unbind_button.show ();
}
+
+ reset_button.add (reset_label);
+ reset_label.set_markup (string_compose ("<span size=\"large\" weight=\"bold\">%1</span>", _("Reset Bindings to Defaults")));
+
+ reset_box.pack_start (reset_button, true, false);
+ reset_box.show ();
+ reset_button.show ();
+ reset_label.show ();
+ reset_button.signal_clicked().connect (sigc::mem_fun (*this, &KeyEditor::reset));
+ vpacker.pack_start (reset_box);
- vpacker.set_border_width (12);
+ add (vpacker);
view.show ();
scroller.show ();
}
}
}
+
+void
+KeyEditor::reset ()
+{
+ Keyboard::the_keyboard().reset_bindings ();
+}
KeyEditorColumns columns;
Gtk::Button unbind_button;
Gtk::HButtonBox unbind_box;
+ Gtk::HBox reset_box;
+ Gtk::Button reset_button;
+ Gtk::Label reset_label;
void unbind ();
void action_selected ();
void populate ();
+
+ void reset ();
};
#endif /* __ardour_gtk_key_editor_h__ */