mirror of
https://github.com/microsoft/terminal.git
synced 2026-02-06 21:29:10 +00:00
I think this is the rest of the cleanup needed for PR
This commit is contained in:
@@ -246,10 +246,11 @@ bool TerminalDispatch::SetCursorKeysMode(const bool applicationMode) noexcept
|
||||
return true;
|
||||
}
|
||||
|
||||
// Method Description
|
||||
// - TODO
|
||||
// Method Description:
|
||||
// - win32-input-mode: Enable sending full input records encoded as a string of
|
||||
// characters to the client application.
|
||||
// Arguments:
|
||||
// - applicationMode - set to true to enable Application Mode Input, false for Numeric Mode Input.
|
||||
// - win32InputMode - set to true to enable win32-input-mode, false to disable.
|
||||
// Return Value:
|
||||
// - True if handled successfully. False otherwise.
|
||||
bool TerminalDispatch::EnableWin32InputMode(const bool win32Mode) noexcept
|
||||
|
||||
@@ -438,7 +438,10 @@ using namespace Microsoft::Console::Render;
|
||||
}
|
||||
|
||||
// Method Description:
|
||||
// - TODO
|
||||
// - Send a sequence to the connected terminal to request win32-input-mode from
|
||||
// them. This will enable the connected terminal to send us full INPUT_RECORDs
|
||||
// as input. If the terminal doesn't understand this sequence, it'll just
|
||||
// ignore it.
|
||||
// Arguments:
|
||||
// - <none>
|
||||
// Return Value:
|
||||
|
||||
@@ -511,7 +511,10 @@ void VtEngine::SetResizeQuirk(const bool resizeQuirk)
|
||||
}
|
||||
|
||||
// Method Description:
|
||||
// - TODO
|
||||
// - Send a sequence to the connected terminal to request win32-input-mode from
|
||||
// them. This will enable the connected terminal to send us full INPUT_RECORDs
|
||||
// as input. If the terminal doesn't understand this sequence, it'll just
|
||||
// ignore it.
|
||||
// Arguments:
|
||||
// - <none>
|
||||
// Return Value:
|
||||
|
||||
@@ -37,11 +37,12 @@ bool InteractDispatch::WriteInput(std::deque<std::unique_ptr<IInputEvent>>& inpu
|
||||
}
|
||||
|
||||
// Method Description:
|
||||
// - Writes a Ctrl-C event to the host. The host will then decide what to do
|
||||
// with it, including potentially sending an interrupt to a client
|
||||
// application.
|
||||
// - Writes a key event to the host in a fashion that will enable the host to
|
||||
// process special keys such as Ctrl-C or Ctrl+Break. The host will then
|
||||
// decide what to do with it, including potentially sending an interrupt to a
|
||||
// client application.
|
||||
// Arguments:
|
||||
// TODO
|
||||
// - event: The key to send to the host.
|
||||
// Return Value:
|
||||
// True if handled successfully. False otherwise.
|
||||
bool InteractDispatch::WriteCtrlKey(const KeyEvent& event)
|
||||
|
||||
@@ -350,7 +350,16 @@ bool InputStateMachineEngine::ActionCsiDispatch(const wchar_t wch,
|
||||
const std::basic_string_view<size_t> parameters)
|
||||
{
|
||||
const auto actionCode = static_cast<CsiActionCodes>(wch);
|
||||
if (_pDispatch->IsVtInputEnabled() && _pfnFlushToInputQueue && actionCode != CsiActionCodes::Win32KeyboardInput)
|
||||
|
||||
// GH#4999 - If the client was in VT input mode, but we received a
|
||||
// win32-input-mode sequence, then _don't_ passthrough the sequence to the
|
||||
// client. It's impossibly unlikely that the client actually wanted
|
||||
// win32-input-mode, and if they did, then we'll just translate the
|
||||
// INPUT_RECORD back to the same sequence we say here later on, when the
|
||||
// client reads it.
|
||||
if (_pDispatch->IsVtInputEnabled() &&
|
||||
_pfnFlushToInputQueue &&
|
||||
actionCode != CsiActionCodes::Win32KeyboardInput)
|
||||
{
|
||||
return _pfnFlushToInputQueue();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user