Changeset 49906 in vbox for trunk/src/VBox/Main/idl/midl.xsl
- Timestamp:
- Dec 14, 2013 9:01:04 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/idl/midl.xsl
r43103 r49906 21 21 22 22 <xsl:strip-space elements="*"/> 23 24 <!-- Whether to generate proxy code and type library ('yes'), or just the type-library. --> 25 <xsl:param name="g_fGenProxy" select="'no'"/> 23 26 24 27 … … 144 147 * libraries 145 148 --> 146 <xsl:template match="library">[ 149 <xsl:template match="library"> 150 <xsl:if test="$g_fGenProxy = 'yes'"> 151 <!-- Declare everything outside the library and then reference these 152 from inside the library statement. See: 153 http://msdn.microsoft.com/en-us/library/windows/desktop/aa366841(v=vs.85).aspx --> 154 <xsl:text>
</xsl:text> 155 <!-- forward declarations --> 156 <xsl:apply-templates select="if | interface" mode="forward"/> 157 <xsl:text>
</xsl:text> 158 <!-- all enums go first --> 159 <xsl:apply-templates select="enum | if/enum"/> 160 <!-- everything else but result codes and enums --> 161 <xsl:apply-templates select="*[not(self::result or self::enum) and 162 not(self::if[result] or self::if[enum])]"/> 163 </xsl:if> 164 165 [ 147 166 uuid(<xsl:value-of select="@uuid"/>), 148 167 version(<xsl:value-of select="@version"/>), … … 161 180 <xsl:apply-templates select="if | interface" mode="forward"/> 162 181 <xsl:text>
</xsl:text> 163 <!-- all enums go first --> 164 <xsl:apply-templates select="enum | if/enum"/> 165 <!-- everything else but result codes and enums --> 166 <xsl:apply-templates select="*[not(self::result or self::enum) and 167 not(self::if[result] or self::if[enum])]"/> 182 <xsl:choose> 183 <xsl:when test="$g_fGenProxy = 'yes'"> 184 <!-- all enums go first --> 185 <xsl:apply-templates select="enum | if/enum" mode="forward"/> 186 </xsl:when> 187 <xsl:otherwise> 188 <!-- all enums go first --> 189 <xsl:apply-templates select="enum | if/enum"/> 190 <!-- everything else but result codes and enums --> 191 <xsl:apply-templates select="*[not(self::result or self::enum) and 192 not(self::if[result] or self::if[enum])]"/> 193 </xsl:otherwise> 194 </xsl:choose> 168 195 <!-- --> 169 196 <xsl:text>}; /* library </xsl:text> … … 190 217 <xsl:value-of select="@name"/> 191 218 <xsl:text>;
</xsl:text> 219 </xsl:template> 220 221 222 <xsl:template match="enum" mode="forward"> 223 <xsl:text>enum </xsl:text> 224 <xsl:value-of select="@name"/> 225 <xsl:text>;

</xsl:text> 192 226 </xsl:template> 193 227
Note:
See TracChangeset
for help on using the changeset viewer.