Make the config menu use repeat functionality. Also: more speed :)

This commit is contained in:
Stefan `Sec` Zehl 2011-08-02 23:39:37 +02:00
parent e25e591287
commit 9cf0b573c3
2 changed files with 5 additions and 4 deletions

View File

@ -75,7 +75,7 @@ void changer(void){
}
lcdRefresh();
switch (getInputWait()) {
switch (getInputWaitRepeat()) {
case BTN_UP:
menuselection--;
if (menuselection < current_offset) {
@ -121,7 +121,6 @@ void changer(void){
saveConfig();
return;
}
getInputWaitRelease();
}
/* NOTREACHED */
}

View File

@ -73,10 +73,12 @@ uint8_t getInputWaitRepeat(void) {
dtime=600;
else if(repeatctr<5)
dtime=250;
else if(repeatctr<30)
else if(repeatctr<25)
dtime=150;
else
else if(repeatctr<50)
dtime=80;
else
dtime=20;
repeatctr++;
int end=_timectr+(dtime/SYSTICKSPEED);
while(_timectr<end && key==getInputRaw())