summaryrefslogtreecommitdiff
path: root/gtk2_ardour/keyboard.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gtk2_ardour/keyboard.cc')
-rw-r--r--gtk2_ardour/keyboard.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/gtk2_ardour/keyboard.cc b/gtk2_ardour/keyboard.cc
index 2e24f56abb..d5b9dd8c45 100644
--- a/gtk2_ardour/keyboard.cc
+++ b/gtk2_ardour/keyboard.cc
@@ -23,6 +23,7 @@
#include "pbd/basename.h"
#include "ardour/filesystem_paths.h"
+#include "ardour/revision.h"
#include "ardour_ui.h"
#include "public_editor.h"
@@ -103,6 +104,16 @@ ArdourKeyboard::setup_keybindings ()
string lowercase_program_name = downcase (string(PROGRAM_NAME));
+#ifndef MIXBUS // not for v4.0 just yet
+ /* extract and append minor vesion */
+ std::string rev (revision);
+ std::size_t pos = rev.find_first_of("-");
+ if (pos != string::npos && pos > 0) {
+ lowercase_program_name += "-";
+ lowercase_program_name += rev.substr (0, pos);
+ }
+#endif
+
user_keybindings_path = Glib::build_filename (user_config_directory(), lowercase_program_name + binding_filename_suffix);
if (Glib::file_test (user_keybindings_path, Glib::FILE_TEST_EXISTS)) {