Commit 6a1c93fbe828dad21eaf111e11778328fd7a5670
1 parent
71fa175f
Exists in
master
and in
1 other branch
Fixing default keycode for "PF-12".
Showing
2 changed files
with
4 additions
and
3 deletions
Show diff stats
src/dialogs/settings/accelerator.c
... | ... | @@ -431,7 +431,6 @@ static void alternative_edited(GtkCellRendererAccel G_GNUC_UNUSED(*renderer), gc |
431 | 431 | #endif // DEBUG |
432 | 432 | |
433 | 433 | // Check for "single-accel" actions |
434 | - V3270Accelerator *accel = NULL; | |
435 | 434 | GtkTreePath * tree_path = gtk_tree_path_new_from_string(path); |
436 | 435 | GtkTreeIter iter; |
437 | 436 | if(gtk_tree_model_get_iter(GTK_TREE_MODEL(widget->store),&iter,tree_path)) |
... | ... | @@ -439,7 +438,6 @@ static void alternative_edited(GtkCellRendererAccel G_GNUC_UNUSED(*renderer), gc |
439 | 438 | GValue value; |
440 | 439 | memset(&value,0,sizeof(value)); |
441 | 440 | gtk_tree_model_get_value(GTK_TREE_MODEL(widget->store), &iter, ACTION, &value); |
442 | - accel = (V3270Accelerator *) g_value_get_pointer(&value); | |
443 | 441 | g_value_unset(&value); |
444 | 442 | } |
445 | 443 | gtk_tree_path_free(tree_path); | ... | ... |
src/terminal/keyboard/init.c
... | ... | @@ -92,11 +92,13 @@ |
92 | 92 | } else { |
93 | 93 | |
94 | 94 | g_autofree gchar *kn = NULL; |
95 | - if(id < 12) | |
95 | + if(id < 13) | |
96 | 96 | kn = g_strdup_printf("F%u",id); |
97 | 97 | else |
98 | 98 | kn = g_strdup_printf("<shift>F%u",id-12); |
99 | 99 | |
100 | + debug("********* %d - %s",id,kn); | |
101 | + | |
100 | 102 | v3270_accelerator_parse((V3270Accelerator *) accelerator,kn); |
101 | 103 | } |
102 | 104 | |
... | ... | @@ -225,6 +227,7 @@ |
225 | 227 | unsigned short key; |
226 | 228 | // PF1 - PF24 |
227 | 229 | for(key = 1; key < 25; key++) { |
230 | + | |
228 | 231 | accelerators = g_slist_prepend(accelerators,v3270_pfkey_accelerator_new(key,NULL)); |
229 | 232 | |
230 | 233 | if(key == 7) { | ... | ... |