[gnome-builder] terminal: add a new-terminal button but do not wire things up



commit ed9a4211a34bfbcdb5bb5f1bc5fee1b82311fc45
Author: Christian Hergert <chergert redhat com>
Date:   Wed May 1 11:51:50 2019 -0700

    terminal: add a new-terminal button but do not wire things up
    
    This adds the button to the workspace, but does not wire things up yet.

 src/libide/terminal/ide-terminal-workspace.c  | 5 +++++
 src/libide/terminal/ide-terminal-workspace.ui | 4 ++++
 2 files changed, 9 insertions(+)
---
diff --git a/src/libide/terminal/ide-terminal-workspace.c b/src/libide/terminal/ide-terminal-workspace.c
index cd50a64be..492028cf0 100644
--- a/src/libide/terminal/ide-terminal-workspace.c
+++ b/src/libide/terminal/ide-terminal-workspace.c
@@ -22,6 +22,7 @@
 
 #include "config.h"
 
+#include "ide-terminal-popover.h"
 #include "ide-terminal-workspace.h"
 
 struct _IdeTerminalWorkspace
@@ -31,6 +32,7 @@ struct _IdeTerminalWorkspace
   IdeHeaderBar       *header_bar;
   DzlShortcutTooltip *new_shortcut;
   DzlShortcutTooltip *search_shortcut;
+  IdeTerminalPopover *terminal_popover;
 };
 
 G_DEFINE_TYPE (IdeTerminalWorkspace, ide_terminal_workspace, IDE_TYPE_WORKSPACE)
@@ -78,6 +80,9 @@ ide_terminal_workspace_class_init (IdeTerminalWorkspaceClass *klass)
   gtk_widget_class_bind_template_child (widget_class, IdeTerminalWorkspace, header_bar);
   gtk_widget_class_bind_template_child (widget_class, IdeTerminalWorkspace, new_shortcut);
   gtk_widget_class_bind_template_child (widget_class, IdeTerminalWorkspace, search_shortcut);
+  gtk_widget_class_bind_template_child (widget_class, IdeTerminalWorkspace, terminal_popover);
+
+  g_type_ensure (IDE_TYPE_TERMINAL_POPOVER);
 }
 
 static void
diff --git a/src/libide/terminal/ide-terminal-workspace.ui b/src/libide/terminal/ide-terminal-workspace.ui
index ca3bfeaa7..7d8bfb2e1 100644
--- a/src/libide/terminal/ide-terminal-workspace.ui
+++ b/src/libide/terminal/ide-terminal-workspace.ui
@@ -35,6 +35,7 @@
                 <property name="focus-on-click">false</property>
                 <property name="show-arrow">false</property>
                 <property name="icon-name">pan-down-symbolic</property>
+                <property name="popover">terminal_popover</property>
                 <property name="visible">true</property>
                 <style>
                   <class name="image-button"/>
@@ -82,4 +83,7 @@
     <property name="command-id">org.gnome.builder.workspace.global-search</property>
     <property name="widget">search_button</property>
   </object>
+  <object class="IdeTerminalPopover" id="terminal_popover">
+    <property name="visible">true</property>
+  </object>
 </interface>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]