906edf7002
- Implements the default application behavior and handoff mechanisms between console and terminal. The inbox portion is done already. This adds the ability for our OpenConsole.exe to accept the incoming server connection from the Windows OS, stand up a PTY session, start the Windows Terminal as a listener for an incoming connection, and then send it the incoming PTY connection for it to launch a tab. - The tab is launched with default settings at the moment. - You must configure the default application using the `conhost.exe` propsheet or with the registry keys. Finishing the setting inside Windows Terminal will be a todo after this is complete. The OS Settings panel work to surface this setting is a dependency delivered by another team and you will not see it here. ## Validation Steps Performed - [x] Manual adjust of registry keys to the delegation conhost/terminal behavior - [x] Adjustment of the delegation options with the propsheet - [x] Launching things from the run box manually and watching them show in Terminal - [x] Launching things from shortcuts and watching them show in the Terminal Documentation on how it works will be a TODO post completion in #9462 References #7414 - Default Terminal spec Closes #492
33 lines
809 B
Plaintext
33 lines
809 B
Plaintext
// Copyright (c) Microsoft Corporation.
|
|
// Licensed under the MIT license.
|
|
|
|
namespace Microsoft.Terminal.TerminalConnection
|
|
{
|
|
enum ConnectionState
|
|
{
|
|
NotConnected = 0,
|
|
Connecting,
|
|
Connected,
|
|
Closing,
|
|
Closed,
|
|
Failed
|
|
};
|
|
|
|
delegate void TerminalOutputHandler(String output);
|
|
|
|
interface ITerminalConnection
|
|
{
|
|
void Start();
|
|
void WriteInput(String data);
|
|
void Resize(UInt32 rows, UInt32 columns);
|
|
void Close();
|
|
|
|
event TerminalOutputHandler TerminalOutput;
|
|
|
|
event Windows.Foundation.TypedEventHandler<ITerminalConnection, Object> StateChanged;
|
|
ConnectionState State { get; };
|
|
};
|
|
|
|
delegate void NewConnectionHandler(ITerminalConnection connection);
|
|
}
|