VirtualBox

Ignore:
Timestamp:
Nov 7, 2008 12:59:48 PM (16 years ago)
Author:
vboxsync
Message:

FE/Qt: Fixed support for safe arrays of enums (affected XPCOM platforms).

Location:
trunk/src/VBox/Frontends/VirtualBox/include
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/include/COMDefs.h

    r13956 r13959  
    291291
    292292    template <typename QE, typename CE>
    293     static void ToSafeArray (const QVector <QE> &aVec,
     293    static void ToSafeArray (const QValueVector <QE> &aVec,
    294294                             com::SafeIfaceArray <CE> &aArr)
    295295    {
     
    301301    template <typename CE, typename QE>
    302302    static void FromSafeArray (const com::SafeIfaceArray <CE> &aArr,
    303                                QVector <QE> &aVec)
     303                               QValueVector <QE> &aVec)
    304304    {
    305305        aVec.resize (static_cast <int> (aArr.size()));
  • trunk/src/VBox/Frontends/VirtualBox/include/COMWrappers.xsl

    r13580 r13959  
    17791779  )"/>
    17801780
     1781  <xsl:variable name="is_enum" select="(
     1782    (ancestor::library/enum[@name=current()/@type]) or
     1783    (ancestor::library/if[@target=$self_target]/enum[@name=current()/@type])
     1784  )"/>
     1785
    17811786  <xsl:choose>
    17821787    <xsl:when test="$when='pre-call'">
     
    17931798              <xsl:value-of select="@type"/>
    17941799              <xsl:text>&gt; </xsl:text>
     1800            </xsl:when>
     1801            <!-- enums need the _T prefix -->
     1802            <xsl:when test="$is_enum">
     1803              <xsl:text>    com::SafeArray &lt;</xsl:text>
     1804              <xsl:value-of select="@type"/>
     1805              <xsl:text>_T&gt; </xsl:text>
    17951806            </xsl:when>
    17961807            <!-- GUID is special too -->
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette