mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-16 16:56:09 +03:00
Reset status display after a full reset
This commit is contained in:
@ -2186,6 +2186,7 @@ pub fn fullReset(self: *Terminal, alloc: Allocator) void {
|
|||||||
self.eraseDisplay(alloc, .scrollback, false);
|
self.eraseDisplay(alloc, .scrollback, false);
|
||||||
self.eraseDisplay(alloc, .complete, false);
|
self.eraseDisplay(alloc, .complete, false);
|
||||||
self.pwd.clearRetainingCapacity();
|
self.pwd.clearRetainingCapacity();
|
||||||
|
self.status_display = .main;
|
||||||
}
|
}
|
||||||
|
|
||||||
test "Terminal: fullReset with a non-empty pen" {
|
test "Terminal: fullReset with a non-empty pen" {
|
||||||
@ -2215,6 +2216,15 @@ test "Terminal: fullReset origin mode" {
|
|||||||
try testing.expect(!t.modes.get(.origin));
|
try testing.expect(!t.modes.get(.origin));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
test "Terminal: fullReset status display" {
|
||||||
|
var t = try init(testing.allocator, 10, 10);
|
||||||
|
defer t.deinit(testing.allocator);
|
||||||
|
|
||||||
|
t.status_display = .status_line;
|
||||||
|
t.fullReset(testing.allocator);
|
||||||
|
try testing.expect(t.status_display == .main);
|
||||||
|
}
|
||||||
|
|
||||||
test "Terminal: input with no control characters" {
|
test "Terminal: input with no control characters" {
|
||||||
var t = try init(testing.allocator, 80, 80);
|
var t = try init(testing.allocator, 80, 80);
|
||||||
defer t.deinit(testing.allocator);
|
defer t.deinit(testing.allocator);
|
||||||
|
Reference in New Issue
Block a user