[gnome-builder] editor: add missing ids



commit 92aef08f32fabdd1c88b23781f02a3d4302c54e7
Author: Christian Hergert <chergert redhat com>
Date:   Mon Oct 26 11:21:58 2020 -0700

    editor: add missing ids
    
    This is rather annoying, but for how menu merging works we need the id
    within the section item as well as in the <section id="..">. Some work
    may be able to be done in dazzle to improve this longer term. However,
    I think the real goal should be to have menu merging in GTK 4 directly.

 src/plugins/editor/gtk/menus.ui | 12 ++++++++++++
 1 file changed, 12 insertions(+)
---
diff --git a/src/plugins/editor/gtk/menus.ui b/src/plugins/editor/gtk/menus.ui
index c7bfa4710..b3de447e4 100644
--- a/src/plugins/editor/gtk/menus.ui
+++ b/src/plugins/editor/gtk/menus.ui
@@ -2,6 +2,7 @@
 <interface>
   <menu id="ide-primary-workspace-menu">
     <section id="ide-primary-workspace-menu-placeholder1">
+      <attribute name="id">ide-primary-workspace-menu-placeholder1</attribute>
       <item>
         <attribute name="id">ide-primary-workspace-menu-new-editor-workspace</attribute>
         <attribute name="label" translatable="yes">New Editor Workspace…</attribute>
@@ -20,6 +21,7 @@
     </section>
     <section id="ide-editor-workspace-menu-placeholder2"/>
     <section id="ide-editor-workspace-menu-open-section">
+      <attribute name="id">ide-editor-workspace-menu-open-section</attribute>
       <item>
         <attribute name="id">ide-editor-workspace-menu-open</attribute>
         <attribute name="label" translatable="yes">Open File…</attribute>
@@ -28,6 +30,7 @@
       </item>
     </section>
     <section id="ide-editor-workspace-menu-app-section">
+      <attribute name="id">ide-editor-workspace-menu-app-section</attribute>
       <item>
         <attribute name="id">ide-editor-workspace-menu-preferences</attribute>
         <attribute name="label" translatable="yes">Preferences</attribute>
@@ -53,6 +56,7 @@
       </item>
     </section>
     <section id="ide-editor-workspace-menu-quit-section">
+      <attribute name="id">ide-editor-workspace-menu-quit-section</attribute>
       <item>
         <attribute name="id">ide-editor-workspace-menu-quit</attribute>
         <attribute name="label" translatable="yes">_Quit</attribute>
@@ -62,6 +66,7 @@
   </menu>
   <menu id="ide-primary-workspace-surfaces-menu">
     <section id="ide-primary-workspace-surfaces-menu-section">
+      <attribute name="id">ide-primary-workspace-surfaces-menu-section</attribute>
       <item>
         <attribute name="accel">&lt;alt&gt;1</attribute>
         <attribute name="id">ide-primary-workspace-menu-surfaces-menu-editor</attribute>
@@ -75,6 +80,7 @@
   </menu>
   <menu id="ide-editor-workspace-surfaces-menu">
     <section id="ide-editor-workspace-surfaces-menu-section">
+      <attribute name="id">ide-editor-workspace-surfaces-menu-section</attribute>
       <attribute name="label" translatable="yes">Switch Surface</attribute>
       <item>
         <attribute name="accel">&lt;alt&gt;1</attribute>
@@ -90,6 +96,7 @@
   </menu>
   <menu id="new-document-menu">
     <section id="new-document-section">
+      <attribute name="id">new-document-section</attribute>
       <item>
         <attribute name="id">new-file</attribute>
         <attribute name="label" translatable="yes">New File</attribute>
@@ -98,6 +105,7 @@
       </item>
     </section>
     <section id="open-document-section">
+      <attribute name="id">open-document-section</attribute>
       <item>
         <attribute name="id">open-file</attribute>
         <attribute name="label" translatable="yes">Open File…</attribute>
@@ -108,6 +116,7 @@
   </menu>
   <menu id="ide-frame-menu">
     <section id="ide-frame-section">
+      <attribute name="id">ide-frame-section</attribute>
       <attribute name="label" translatable="yes">Frame</attribute>
       <item>
         <attribute name="label" translatable="yes">Move Left</attribute>
@@ -125,6 +134,7 @@
   </menu>
   <menu id="ide-editor-page-document-menu">
     <section id="editor-document-section">
+      <attribute name="id">editor-document-section</attribute>
       <attribute name="label" translatable="yes">Document</attribute>
       <item>
         <attribute name="id">editor-document-open-in-new-frame</attribute>
@@ -157,6 +167,7 @@
       </item>
     </section>
     <section id="editor-document-save-section">
+      <attribute name="id">editor-document-save-section</attribute>
       <attribute name="after">editor-document-preferences-section</attribute>
       <item>
         <attribute name="action">editor-page.save</attribute>
@@ -170,6 +181,7 @@
       </item>
     </section>
     <section id="editor-document-close-section">
+      <attribute name="id">editor-document-close-section</attribute>
       <attribute name="after">editor-document-save-section</attribute>
       <item>
         <attribute name="action">frame.close-page</attribute>


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