[vte] emulation: Change soft reset not to switch back to normal screen
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte] emulation: Change soft reset not to switch back to normal screen
- Date: Thu, 11 Dec 2014 19:23:51 +0000 (UTC)
commit a72436b76c25ec33cdf11d8731b866052aa0724a
Author: Egmont Koblinger <egmont gmail com>
Date: Thu Dec 11 20:17:25 2014 +0100
emulation: Change soft reset not to switch back to normal screen
This also works around an assertion failure due to incorrect cursor
position, introduced in commit 5a434e6c4457bdfe182a13213396e7a66a08f767.
https://bugzilla.gnome.org/show_bug.cgi?id=741406
src/vte.c | 9 +++------
1 files changed, 3 insertions(+), 6 deletions(-)
---
diff --git a/src/vte.c b/src/vte.c
index 22f54e9..07508c4 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -8025,10 +8025,9 @@ vte_terminal_init(VteTerminal *terminal)
/* Initialize the screens and histories. */
_vte_ring_init (pvt->alternate_screen.row_data, terminal->pvt->row_count);
pvt->screen = &terminal->pvt->alternate_screen;
- _vte_terminal_set_default_attributes(terminal);
-
_vte_ring_init (pvt->normal_screen.row_data, VTE_SCROLLBACK_INIT);
pvt->screen = &terminal->pvt->normal_screen;
+
_vte_terminal_set_default_attributes(terminal);
/* Initialize charset modes. */
@@ -11832,16 +11831,14 @@ vte_terminal_reset(VteTerminal *terminal,
terminal->pvt->palette[i].sources[VTE_COLOR_SOURCE_ESCAPE].is_set = FALSE;
/* Reset the default attributes. Reset the alternate attribute because
* it's not a real attribute, but we need to treat it as one here. */
- pvt->screen = &pvt->alternate_screen;
- _vte_terminal_set_default_attributes(terminal);
- pvt->screen = &pvt->normal_screen;
_vte_terminal_set_default_attributes(terminal);
/* Reset charset modes. */
pvt->character_replacements[0] = VTE_CHARACTER_REPLACEMENT_NONE;
pvt->character_replacements[1] = VTE_CHARACTER_REPLACEMENT_NONE;
pvt->character_replacement = &pvt->character_replacements[0];
- /* Clear the scrollback buffers and reset the cursors. */
+ /* Clear the scrollback buffers and reset the cursors. Switch to normal screen. */
if (clear_history) {
+ pvt->screen = &pvt->normal_screen;
_vte_ring_reset(pvt->normal_screen.row_data);
_vte_ring_reset(pvt->alternate_screen.row_data);
pvt->normal_screen.saved.cursor.row = 0;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]