mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-27 18:51:41 +02:00
micro-optimization
This commit is contained in:
@@ -15,6 +15,7 @@ import (
|
|||||||
"golang.org/x/sys/unix"
|
"golang.org/x/sys/unix"
|
||||||
|
|
||||||
"kitty/tools/tty"
|
"kitty/tools/tty"
|
||||||
|
"kitty/tools/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
var SIGNULL unix.Signal
|
var SIGNULL unix.Signal
|
||||||
@@ -110,7 +111,7 @@ func (self *Loop) handle_osc(raw []byte) error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (self *Loop) handle_dcs(raw []byte) error {
|
func (self *Loop) handle_dcs(raw []byte) error {
|
||||||
if self.OnRCResponse != nil && bytes.HasPrefix(raw, []byte("@kitty-cmd")) {
|
if self.OnRCResponse != nil && bytes.HasPrefix(raw, utils.UnsafeStringToBytes("@kitty-cmd")) {
|
||||||
return self.OnRCResponse(raw[len("@kitty-cmd"):])
|
return self.OnRCResponse(raw[len("@kitty-cmd"):])
|
||||||
}
|
}
|
||||||
if self.OnEscapeCode != nil {
|
if self.OnEscapeCode != nil {
|
||||||
|
|||||||
Reference in New Issue
Block a user