diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-01-25 18:17:08 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-01-25 18:18:52 +0100 |
commit | d70aa23c2d3af951c8846b4aea83c87c06a37a35 (patch) | |
tree | 4669966eef4aef87b3da1d818884cd0d7f04c4f9 /officecfg/registry | |
parent | 866df124ee89a9d7b1f2b7803892f02c1010a9be (diff) |
Add configuration wrappers for groups, too (to add listeners etc.).
Diffstat (limited to 'officecfg/registry')
-rw-r--r-- | officecfg/registry/cppheader.xsl | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/officecfg/registry/cppheader.xsl b/officecfg/registry/cppheader.xsl index df891c29e6e2..2522aca68d5d 100644 --- a/officecfg/registry/cppheader.xsl +++ b/officecfg/registry/cppheader.xsl @@ -141,9 +141,18 @@ <xsl:template match="group"> <xsl:param name="path"/> <xsl:if test=".//prop or .//set"> - <xsl:text>namespace </xsl:text> - <xsl:value-of select="translate(@oor:name, '-.', '__')"/> - <xsl:text> {
</xsl:text> + <xsl:variable name="name" select="translate(@oor:name, '-.', '__')"/> + <xsl:text>struct </xsl:text> + <xsl:value-of select="$name"/> + <xsl:text>: public unotools::ConfigurationGroup< </xsl:text> + <xsl:value-of select="$name"/> + <xsl:text>> {
</xsl:text> + <xsl:text> static rtl::OUString path() { return rtl::OUString(<!-- + -->RTL_CONSTASCII_USTRINGPARAM("</xsl:text> + <xsl:value-of select="$path"/> + <xsl:text>/</xsl:text> + <xsl:value-of select="@oor:name"/> + <xsl:text>")); }
</xsl:text> <xsl:text>
</xsl:text> <xsl:apply-templates select="group|set|prop"> <xsl:with-param name="path"> @@ -152,7 +161,14 @@ <xsl:value-of select="@oor:name"/> </xsl:with-param> </xsl:apply-templates> - <xsl:text>}
</xsl:text> + <xsl:text>private:
</xsl:text> + <xsl:text> </xsl:text> + <xsl:value-of select="$name"/> + <xsl:text>(); // not defined
</xsl:text> + <xsl:text> ~</xsl:text> + <xsl:value-of select="$name"/> + <xsl:text>(); // not defined
</xsl:text> + <xsl:text>};
</xsl:text> <xsl:text>
</xsl:text> </xsl:if> </xsl:template> |