fsq repeat last

* test for empty list of previous command
pull/4/head
David Freese 2016-02-08 11:19:20 -06:00
rodzic 813b58ad02
commit dd1165a363
1 zmienionych plików z 4 dodań i 1 usunięć

Wyświetl plik

@ -1451,10 +1451,13 @@ double fsq_xmtdelay() // in seconds
void fsq_repeat_last_command()
{
using ::next; // disambiguate from std::next
if (commands.empty()) return;
fsq_tx_text->clear();
fsq_tx_text->addstr(sz2utf8(commands[next].c_str()));
next++;
if (next == commands.size()) next = 0;
if (next == commands.size()) {
next = 0;
}
}
int get_fsq_tx_char(void)