mirror of
https://github.com/FunKey-Project/RetroFE.git
synced 2025-12-13 10:18:53 +01:00
ScrollingList.cpp edited online with Bitbucket
This commit is contained in:
parent
3e39b122d7
commit
836e18abd3
@ -36,6 +36,7 @@
|
|||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include <SDL2/SDL_image.h>
|
#include <SDL2/SDL_image.h>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
#include <cctype>
|
||||||
|
|
||||||
|
|
||||||
//todo: remove coupling from configuration data (if possible)
|
//todo: remove coupling from configuration data (if possible)
|
||||||
@ -406,7 +407,14 @@ void ScrollingList::LetterUp()
|
|||||||
++i;
|
++i;
|
||||||
|
|
||||||
// check if we are changing characters from a-z, or changing from alpha character to non-alpha character
|
// check if we are changing characters from a-z, or changing from alpha character to non-alpha character
|
||||||
done = (isalpha(startname[0]) ^ isalpha(endname[0])) || (isalpha(startname[0]) && isalpha(endname[0]) && startname[0] != endname[0]));
|
if(isalpha(startname[0]) ^ isalpha(endname[0]))
|
||||||
|
{
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
|
else if(isalpha(startname[0]) && isalpha(endname[0]) && startname[0] != endname[0])
|
||||||
|
{
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
|
|
||||||
if(done)
|
if(done)
|
||||||
{
|
{
|
||||||
@ -439,7 +447,14 @@ void ScrollingList::LetterDown()
|
|||||||
++i;
|
++i;
|
||||||
|
|
||||||
// check if we are changing characters from a-z, or changing from alpha character to non-alpha character
|
// check if we are changing characters from a-z, or changing from alpha character to non-alpha character
|
||||||
done = (isalpha(startname[0]) ^ isalpha(endname[0])) || (isalpha(startname[0]) && isalpha(endname[0]) && startname[0] != endname[0]));
|
if(isalpha(startname[0]) ^ isalpha(endname[0]))
|
||||||
|
{
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
|
else if(isalpha(startname[0]) && isalpha(endname[0]) && startname[0] != endname[0])
|
||||||
|
{
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user