[gnome-builder/gnome-builder-3-32] buildui: wire up build/rebuild commands
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-3-32] buildui: wire up build/rebuild commands
- Date: Fri, 30 Aug 2019 23:03:15 +0000 (UTC)
commit 4c8096a656600d3b57fb01f33ff3dd99afaa1ce9
Author: Christian Hergert <chergert redhat com>
Date: Fri Aug 30 15:34:22 2019 -0700
buildui: wire up build/rebuild commands
These have been missing for some time by mistake.
src/libide/gui/ide-shortcuts-window.ui | 7 +++++++
src/plugins/buildui/gbp-buildui-workspace-addin.c | 13 +++++++++++++
2 files changed, 20 insertions(+)
---
diff --git a/src/libide/gui/ide-shortcuts-window.ui b/src/libide/gui/ide-shortcuts-window.ui
index a71e02a2f..b1124d6bb 100644
--- a/src/libide/gui/ide-shortcuts-window.ui
+++ b/src/libide/gui/ide-shortcuts-window.ui
@@ -458,6 +458,13 @@
<property name="title" translatable="yes" context="shortcut window">Build</property>
</object>
</child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="accelerator"><ctrl><shift>F7</property>
+ <property name="title" translatable="yes" context="shortcut window">Rebuild</property>
+ </object>
+ </child>
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">true</property>
diff --git a/src/plugins/buildui/gbp-buildui-workspace-addin.c
b/src/plugins/buildui/gbp-buildui-workspace-addin.c
index c37e4e916..6e2e20ba4 100644
--- a/src/plugins/buildui/gbp-buildui-workspace-addin.c
+++ b/src/plugins/buildui/gbp-buildui-workspace-addin.c
@@ -223,6 +223,7 @@ gbp_buildui_workspace_addin_load (IdeWorkspaceAddin *addin,
GbpBuilduiWorkspaceAddin *self = (GbpBuilduiWorkspaceAddin *)addin;
IdeConfigManager *config_manager;
PangoAttrList *small_attrs = NULL;
+ DzlShortcutController *shortcuts;
IdeEditorSidebar *sidebar;
IdeBuildManager *build_manager;
IdeWorkbench *workbench;
@@ -242,6 +243,18 @@ gbp_buildui_workspace_addin_load (IdeWorkspaceAddin *addin,
G_N_ELEMENTS (actions),
self);
+ shortcuts = dzl_shortcut_controller_find (GTK_WIDGET (workspace));
+ dzl_shortcut_controller_add_command_action (shortcuts,
+ "org.gnome.builder.buildui.build",
+ "<Control>F7",
+ DZL_SHORTCUT_PHASE_GLOBAL,
+ "build-manager.build");
+ dzl_shortcut_controller_add_command_action (shortcuts,
+ "org.gnome.builder.buildui.rebuild",
+ "<Control><Shift>F7",
+ DZL_SHORTCUT_PHASE_GLOBAL,
+ "build-manager.rebuild");
+
headerbar = ide_workspace_get_header_bar (workspace);
omnibar = IDE_OMNI_BAR (gtk_header_bar_get_custom_title (GTK_HEADER_BAR (headerbar)));
workbench = ide_widget_get_workbench (GTK_WIDGET (workspace));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]