Commits (1)
  • Deucе's avatar
    Go back to ALT-Up/Down for speed adjustment · 6285417f
    Deucе authored
    Now that ALT-Up/Down no longer have an effect on window size, they
    can go back to their previous bindings of changing the emulated
    output speed.
    
    At the same time, remove AltGr support from keysym parsing since it
    should be properly handled by the text input stuff now.
    6285417f
...@@ -724,7 +724,9 @@ static unsigned int sdl_get_char_code(unsigned int keysym, unsigned int mod) ...@@ -724,7 +724,9 @@ static unsigned int sdl_get_char_code(unsigned int keysym, unsigned int mod)
/* /*
* Using the modifiers, look up the expected scan code. * Using the modifiers, look up the expected scan code.
*/ */
if(mod & KMOD_CTRL) if(mod & KMOD_ALT)
expect = sdl_keyval[i].alt;
else if(mod & KMOD_CTRL)
expect=sdl_keyval[i].ctrl; expect=sdl_keyval[i].ctrl;
else if(mod & KMOD_SHIFT) { else if(mod & KMOD_SHIFT) {
if((mod & KMOD_CAPS) && keysym != '\t') if((mod & KMOD_CAPS) && keysym != '\t')
...@@ -739,19 +741,6 @@ static unsigned int sdl_get_char_code(unsigned int keysym, unsigned int mod) ...@@ -739,19 +741,6 @@ static unsigned int sdl_get_char_code(unsigned int keysym, unsigned int mod)
expect=sdl_keyval[i].key; expect=sdl_keyval[i].key;
} }
/*
* Now handle the ALT case so that expect will
* be what we expect to return
*/
if(mod & KMOD_ALT) {
/* Yes, this is a "normal" ALT combo */
if(keysym==expect)
return(sdl_keyval[i].alt);
/* AltGr apparently... give up */
return(0x0001ffff);
}
return(expect); return(expect);
} }
} }
...@@ -865,9 +854,7 @@ void sdl_video_event_thread(void *data) ...@@ -865,9 +854,7 @@ void sdl_video_event_thread(void *data)
block_text = 1; block_text = 1;
if ((ev.key.keysym.mod & KMOD_ALT) && if ((ev.key.keysym.mod & KMOD_ALT) &&
(ev.key.keysym.sym == SDLK_LEFT || (ev.key.keysym.sym == SDLK_LEFT ||
ev.key.keysym.sym == SDLK_RIGHT || ev.key.keysym.sym == SDLK_RIGHT)) {
ev.key.keysym.sym == SDLK_UP ||
ev.key.keysym.sym == SDLK_DOWN)) {
int w, h; int w, h;
// Don't allow ALT-DIR to change size when maximized... // Don't allow ALT-DIR to change size when maximized...
......
...@@ -144,7 +144,7 @@ int syncmenu(struct bbslist *bbs, int *speed) ...@@ -144,7 +144,7 @@ int syncmenu(struct bbslist *bbs, int *speed)
,"Send Login ("ALT_KEY_NAMEP"-L)" ,"Send Login ("ALT_KEY_NAMEP"-L)"
,"Upload ("ALT_KEY_NAMEP"-U)" ,"Upload ("ALT_KEY_NAMEP"-U)"
,"Download ("ALT_KEY_NAMEP"-D)" ,"Download ("ALT_KEY_NAMEP"-D)"
,"Change Output Rate (Ctrl-Up/Ctrl-Down)" ,"Change Output Rate (" ALT_KEY_NAMEP "-Up/" ALT_KEY_NAMEP "-Down)"
,"Change Log Level" ,"Change Log Level"
,"Capture Control ("ALT_KEY_NAMEP"-C)" ,"Capture Control ("ALT_KEY_NAMEP"-C)"
,"ANSI Music Control ("ALT_KEY_NAMEP"-M)" ,"ANSI Music Control ("ALT_KEY_NAMEP"-M)"
......
...@@ -2991,7 +2991,7 @@ BOOL doterm(struct bbslist *bbs) ...@@ -2991,7 +2991,7 @@ BOOL doterm(struct bbslist *bbs)
gotoxy(i,j); gotoxy(i,j);
key = 0; key = 0;
break; break;
case 0x8d00: /* CTRL-Up */ case 0x9800: /* ALT-Up */
if(bbs->conn_type != CONN_TYPE_SERIAL) { if(bbs->conn_type != CONN_TYPE_SERIAL) {
if(speed) if(speed)
speed=rates[get_rate_num(speed)+1]; speed=rates[get_rate_num(speed)+1];
...@@ -3000,7 +3000,7 @@ BOOL doterm(struct bbslist *bbs) ...@@ -3000,7 +3000,7 @@ BOOL doterm(struct bbslist *bbs)
key = 0; key = 0;
} }
break; break;
case 0x9100: /* CTRL-Down */ case 0xa000: /* ALT-Down */
if(bbs->conn_type != CONN_TYPE_SERIAL) { if(bbs->conn_type != CONN_TYPE_SERIAL) {
i=get_rate_num(speed); i=get_rate_num(speed);
if(i==0) if(i==0)
......