@@ -132,8 +132,10 @@ public final class HistoryTextKeyListener extends KeyAdapter {
|
||||
// Lower arrow retrieves next commands
|
||||
if (keyCode == SWT.ARROW_DOWN) {
|
||||
if (currentIndex <= 0) {
|
||||
currentIndex=-1;
|
||||
console.setInput(EMPTY);
|
||||
if (currentIndex == 0) {
|
||||
console.setInput(EMPTY);
|
||||
}
|
||||
currentIndex = -1;
|
||||
} else {
|
||||
final String cmd = commands.get(commands.size() - (--currentIndex) - 1);
|
||||
console.setInput(cmd);
|
||||
|
||||
Reference in New Issue
Block a user