mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-17 01:06:08 +03:00
Merge pull request #1665 from aca/dbg
input: fix bs emitting sequence when it should not
This commit is contained in:
@ -266,10 +266,8 @@ fn legacy(
|
|||||||
if (self.event.utf8.len > 0) {
|
if (self.event.utf8.len > 0) {
|
||||||
switch (self.event.key) {
|
switch (self.event.key) {
|
||||||
else => {},
|
else => {},
|
||||||
.enter,
|
.backspace => return "",
|
||||||
.escape,
|
.enter, .escape => break :pc_style,
|
||||||
.backspace,
|
|
||||||
=> break :pc_style,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1658,7 +1656,7 @@ test "legacy: backspace with utf8 (dead key state)" {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const actual = try enc.legacy(&buf);
|
const actual = try enc.legacy(&buf);
|
||||||
try testing.expectEqualStrings("A", actual);
|
try testing.expectEqualStrings("", actual);
|
||||||
}
|
}
|
||||||
|
|
||||||
test "legacy: enter with utf8 (dead key state)" {
|
test "legacy: enter with utf8 (dead key state)" {
|
||||||
|
Reference in New Issue
Block a user