mirror of
https://github.com/fasteddy516/SimplySerial.git
synced 2024-11-24 10:04:35 +00:00
don't wait for keypress after ctrl-x
This commit is contained in:
parent
db08444c54
commit
b9841375c9
@ -84,8 +84,8 @@ namespace SimplySerial
|
|||||||
// exit the program if CTRL-X was pressed
|
// exit the program if CTRL-X was pressed
|
||||||
if ((keyInfo.Key == ConsoleKey.X) && (keyInfo.Modifiers == ConsoleModifiers.Control))
|
if ((keyInfo.Key == ConsoleKey.X) && (keyInfo.Modifiers == ConsoleModifiers.Control))
|
||||||
{
|
{
|
||||||
serialPort.Close();
|
Output("\nSession terminated by user via CTRL-X.");
|
||||||
ExitProgram("\nSession terminated by user via CTRL-X.", exitCode: 0);
|
ExitProgram(silent: true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// properly process the backspace character
|
// properly process the backspace character
|
||||||
@ -168,7 +168,7 @@ namespace SimplySerial
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Console.WriteLine("No COM ports detected.\n");
|
Console.WriteLine("\nNo COM ports detected.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
ExitProgram(silent: true);
|
ExitProgram(silent: true);
|
||||||
|
Loading…
Reference in New Issue
Block a user