app: add --show-debug-menu command-line option

The debug menu is currently not included in stable versions.

Include the menu unconditionally, but hide it, and its associated
actions, by default in stable versions.  Allow enabling the menu
using a new --show-debug-menu command-line option, in the same vein
as --show-playground.
This commit is contained in:
Ell
2018-03-29 05:20:20 -04:00
parent c3efb1b0de
commit 53c145c0be
11 changed files with 28 additions and 30 deletions

View File

@ -23,7 +23,7 @@
<menuitem action="dialogs-document-history" />
</menu>
<!-- The debug-menu is automatically excluded for stable releases -->
<!-- The debug-menu is hidden by default for stable releases -->
<menu action="debug-menu" name="Debug">
<menuitem action="debug-mem-profile" />
<menuitem action="debug-benchmark-projection" />

View File

@ -38,12 +38,6 @@
<xsl:apply-templates />
</xsl:template>
<xsl:template match="menu[@action='debug-menu']">
<xsl:if test="$unstable-menus='yes'">
<xsl:call-template name="identity" />
</xsl:if>
</xsl:template>
<!-- need to strip the XInclude namespace declaration from the ui element -->
<xsl:template match="ui">
<ui>