mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 22:11:48 +08:00
do not try to display multi ssh command from history when there are none, fixes #1595
This commit is contained in:
@@ -8,6 +8,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
### Changed
|
||||
- #1460: Updated GeckoFX to v60
|
||||
### Fixed
|
||||
- #1595: Unhandled exception when trying to browse through non existent multi ssh history with keyboard key strokes
|
||||
- #1337: Unhandled exception after closing mRemoteNG
|
||||
|
||||
## [1.77.1] - 2019-09-02
|
||||
|
||||
@@ -99,14 +99,16 @@ namespace mRemoteNG.Tools
|
||||
if (e.KeyCode == Keys.Up || e.KeyCode == Keys.Down)
|
||||
{
|
||||
e.SuppressKeyPress = true;
|
||||
if (e.KeyCode == Keys.Up && previousCommandIndex - 1 >= 0)
|
||||
switch (e.KeyCode)
|
||||
{
|
||||
previousCommandIndex -= 1;
|
||||
}
|
||||
|
||||
if (e.KeyCode == Keys.Down && previousCommandIndex + 1 < previousCommands.Count)
|
||||
{
|
||||
previousCommandIndex += 1;
|
||||
case Keys.Up when previousCommandIndex - 1 >= 0:
|
||||
previousCommandIndex -= 1;
|
||||
break;
|
||||
case Keys.Down when previousCommandIndex + 1 < previousCommands.Count:
|
||||
previousCommandIndex += 1;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
||||
txtMultiSSH.Text = previousCommands[previousCommandIndex].ToString();
|
||||
|
||||
Reference in New Issue
Block a user