[gnome-builder] terminal: only setup initial PTY once in realize
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] terminal: only setup initial PTY once in realize
- Date: Tue, 30 Apr 2019 21:20:39 +0000 (UTC)
commit a64ec37a90334e94899169b93720aae81be7717c
Author: Christian Hergert <chergert redhat com>
Date: Tue Apr 30 14:20:25 2019 -0700
terminal: only setup initial PTY once in realize
src/libide/terminal/ide-terminal-page-private.h | 1 +
src/libide/terminal/ide-terminal-page.c | 5 +++++
2 files changed, 6 insertions(+)
---
diff --git a/src/libide/terminal/ide-terminal-page-private.h b/src/libide/terminal/ide-terminal-page-private.h
index 9e36b5007..1176f87a0 100644
--- a/src/libide/terminal/ide-terminal-page-private.h
+++ b/src/libide/terminal/ide-terminal-page-private.h
@@ -44,6 +44,7 @@ struct _IdeTerminalPage
gint64 last_respawn;
+ guint did_defered_setup_in_realize : 1;
guint manage_spawn : 1;
guint respawn_on_exit : 1;
guint needs_attention : 1;
diff --git a/src/libide/terminal/ide-terminal-page.c b/src/libide/terminal/ide-terminal-page.c
index 09de8d3af..0b17082ee 100644
--- a/src/libide/terminal/ide-terminal-page.c
+++ b/src/libide/terminal/ide-terminal-page.c
@@ -131,6 +131,11 @@ gbp_terminal_realize (GtkWidget *widget)
GTK_WIDGET_CLASS (ide_terminal_page_parent_class)->realize (widget);
+ if (self->did_defered_setup_in_realize)
+ return;
+
+ self->did_defered_setup_in_realize = TRUE;
+
self->last_respawn = g_get_monotonic_time ();
if (self->pty == NULL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]