Merge pull request #295 from Chocimier/iss1293

T hotkey select first town when last is active, fixes #1293
This commit is contained in:
DjWarmonger
2017-05-13 18:22:28 +02:00
committed by GitHub
+4 -5
View File
@@ -169,11 +169,10 @@ void CList::selectIndex(int which)
void CList::selectNext()
{
int index = getSelectedIndex();
if (index < 0)
selectIndex(0);
else if (index + 1 < list->size())
selectIndex(index+1);
int index = getSelectedIndex() + 1;
if (index >= list->size())
index = 0;
selectIndex(index);
}
void CList::selectPrev()