mirror of
https://github.com/yudai/gotty.git
synced 2025-09-22 05:50:48 +02:00
Refactor
This commit is contained in:
parent
54403dd678
commit
a6133f34b7
54 changed files with 2140 additions and 1334 deletions
29
webtty/message_types.go
Normal file
29
webtty/message_types.go
Normal file
|
@ -0,0 +1,29 @@
|
|||
package webtty
|
||||
|
||||
var Protocols = []string{"webtty"}
|
||||
|
||||
const (
|
||||
// Unknown message type, maybe sent by a bug
|
||||
UnknownInput = '0'
|
||||
// User input typically from a keyboard
|
||||
Input = '1'
|
||||
// Ping to the server
|
||||
Ping = '2'
|
||||
// Notify that the browser size has been changed
|
||||
ResizeTerminal = '3'
|
||||
)
|
||||
|
||||
const (
|
||||
// Unknown message type, maybe set by a bug
|
||||
UnknownOutput = '0'
|
||||
// Normal output to the terminal
|
||||
Output = '1'
|
||||
// Pong to the browser
|
||||
Pong = '2'
|
||||
// Set window title of the terminal
|
||||
SetWindowTitle = '3'
|
||||
// Set terminal preference
|
||||
SetPreferences = '4'
|
||||
// Make terminal to reconnect
|
||||
SetReconnect = '5'
|
||||
)
|
Loading…
Add table
Add a link
Reference in a new issue