summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar waker <wakeroid@gmail.com>2012-11-18 21:38:23 +0100
committerGravatar waker <wakeroid@gmail.com>2012-11-18 21:38:23 +0100
commitfba6212130c703cd43312ef8c7127989b38474d0 (patch)
tree5bbd29d51cefb11f31fcfbbea99493ed43c4faca
parentdae6ed6ac77ae5e98496189f3a7d70d883245156 (diff)
correct hotkeys sort order in config file
-rw-r--r--plugins/gtkui/gtkui.c18
-rw-r--r--plugins/gtkui/hotkeys.c2
2 files changed, 10 insertions, 10 deletions
diff --git a/plugins/gtkui/gtkui.c b/plugins/gtkui/gtkui.c
index fb8d7979..8f4de0b3 100644
--- a/plugins/gtkui/gtkui.c
+++ b/plugins/gtkui/gtkui.c
@@ -1066,15 +1066,15 @@ gtkui_thread (void *ctx) {
snprintf (checkpath, sizeof (checkpath), "%s/config", deadbeef->get_config_dir ());
if (stat (checkpath, &st)) {
printf ("file %s doesn't exist\n", checkpath);
- deadbeef->conf_set_str ("hotkey.key1", "\"Ctrl f\" 0 0 find");
- deadbeef->conf_set_str ("hotkey.key2", "\"Ctrl o\" 0 0 open_files");
- deadbeef->conf_set_str ("hotkey.key3", "\"Ctrl q\" 0 0 quit");
- deadbeef->conf_set_str ("hotkey.key4", "\"Ctrl n\" 0 0 new_playlist");
- deadbeef->conf_set_str ("hotkey.key5", "\"Ctrl a\" 0 0 select_all");
- deadbeef->conf_set_str ("hotkey.key6", "\"Escape\" 0 0 deselect_all");
- deadbeef->conf_set_str ("hotkey.key7", "\"Ctrl m\" 0 0 toggle_stop_after_current");
- deadbeef->conf_set_str ("hotkey.key8", "\"Ctrl j\" 0 0 jump_to_current_track");
- deadbeef->conf_set_str ("hotkey.key9", "\"F1\" 0 0 help");
+ deadbeef->conf_set_str ("hotkey.key01", "\"Ctrl f\" 0 0 find");
+ deadbeef->conf_set_str ("hotkey.key02", "\"Ctrl o\" 0 0 open_files");
+ deadbeef->conf_set_str ("hotkey.key03", "\"Ctrl q\" 0 0 quit");
+ deadbeef->conf_set_str ("hotkey.key04", "\"Ctrl n\" 0 0 new_playlist");
+ deadbeef->conf_set_str ("hotkey.key05", "\"Ctrl a\" 0 0 select_all");
+ deadbeef->conf_set_str ("hotkey.key06", "\"Escape\" 0 0 deselect_all");
+ deadbeef->conf_set_str ("hotkey.key07", "\"Ctrl m\" 0 0 toggle_stop_after_current");
+ deadbeef->conf_set_str ("hotkey.key08", "\"Ctrl j\" 0 0 jump_to_current_track");
+ deadbeef->conf_set_str ("hotkey.key09", "\"F1\" 0 0 help");
deadbeef->conf_set_str ("hotkey.key10", "\"Delete\" 1 0 remove_from_playlist");
deadbeef->conf_set_str ("hotkey.key11", "\"Ctrl w\" 0 0 remove_current_playlist");
deadbeef->conf_set_str ("hotkey.key11", "\"Ctrl w\" 0 0 remove_current_playlist");
diff --git a/plugins/gtkui/hotkeys.c b/plugins/gtkui/hotkeys.c
index 0963c5d9..f13fbee1 100644
--- a/plugins/gtkui/hotkeys.c
+++ b/plugins/gtkui/hotkeys.c
@@ -184,7 +184,7 @@ hotkeys_save (void) {
gtk_tree_model_get_value (GTK_TREE_MODEL (hkstore), &iter, 5, &context);
gtk_tree_model_get_value (GTK_TREE_MODEL (hkstore), &iter, 3, &global);
char key[100];
- snprintf (key, sizeof (key), "hotkey.key%d", i);
+ snprintf (key, sizeof (key), "hotkey.key%02d", i);
char value[1000];
snprintf (value, sizeof (value), "\"%s\" %d %d %s", g_value_get_string (&keycombo), g_value_get_int (&context), g_value_get_boolean (&global), g_value_get_string (&action));
deadbeef->conf_set_str (key, value);