VirtualBox

Changeset 41187 in vbox for trunk/src/VBox/Main/include


Ignore:
Timestamp:
May 7, 2012 3:12:10 PM (13 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
77813
Message:

Main: cleanup - VirtualBoxSupportTranslation is long dead

Location:
trunk/src/VBox/Main/include
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/include/FramebufferImpl.h

    r41184 r41187  
    77
    88/*
    9  * Copyright (C) 2009 Oracle Corporation
     9 * Copyright (C) 2009-2012 Oracle Corporation
    1010 *
    1111 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    2626class ATL_NO_VTABLE Framebuffer :
    2727    public VirtualBoxBase,
    28     public VirtualBoxSupportTranslation<Framebuffer>,
    2928    VBOX_SCRIPTABLE_IMPL(IFramebuffer)
    3029{
  • trunk/src/VBox/Main/include/VirtualBoxBase.h

    r41184 r41187  
    6060////////////////////////////////////////////////////////////////////////////////
    6161
    62 #if !defined (VBOX_WITH_XPCOM)
     62#if !defined(VBOX_WITH_XPCOM)
    6363
    6464#include <atlcom.h>
     
    136136};
    137137
    138 #endif /* !defined (VBOX_WITH_XPCOM) */
     138#endif /* !defined(VBOX_WITH_XPCOM) */
    139139
    140140////////////////////////////////////////////////////////////////////////////////
     
    156156 *  @param   expr    Expression which should be true.
    157157 */
    158 #if defined (DEBUG)
     158#if defined(DEBUG)
    159159#define ComAssert(expr)    Assert(expr)
    160160#else
     
    179179 *
    180180 */
    181 #if defined (DEBUG)
     181#if defined(DEBUG)
    182182#define ComAssertFailed()    AssertFailed()
    183183#else
     
    199199 *  @param   a       printf argument list (in parenthesis).
    200200 */
    201 #if defined (DEBUG)
     201#if defined(DEBUG)
    202202#define ComAssertMsg(expr, a)  AssertMsg(expr, a)
    203203#else
     
    219219 * @param   vrc     VBox status code.
    220220 */
    221 #if defined (DEBUG)
     221#if defined(DEBUG)
    222222#define ComAssertRC(vrc)    AssertRC(vrc)
    223223#else
     
    234234 *  @param   msg    printf argument list (in parenthesis).
    235235 */
    236 #if defined (DEBUG)
     236#if defined(DEBUG)
    237237#define ComAssertMsgRC(vrc, msg)    AssertMsgRC(vrc, msg)
    238238#else
     
    248248 *  @param rc   COM result code
    249249 */
    250 #if defined (DEBUG)
     250#if defined(DEBUG)
    251251#define ComAssertComRC(rc)  AssertComRC(rc)
    252252#else
     
    272272/** Special version of ComAssert that returns ret */
    273273#define ComAssertFailedRet(ret)                \
    274     if (1) { ComAssertFailed(); { return (ret); } } else do {} while (0)
     274    do { ComAssertFailed(); return (ret); } while (0)
    275275
    276276
     
    280280/** Special version of ComAssertMsg that evaluates eval and breaks if expr fails */
    281281#define ComAssertMsgBreak(expr, a, eval)          \
    282     if (1)  { ComAssertMsg(expr, a); if (!(expr)) { eval; break; } } else do {} while (0)
     282    if (1) { ComAssertMsg(expr, a); if (!(expr)) { eval; break; } } else do {} while (0)
    283283/** Special version of ComAssertRC that evaluates eval and breaks if vrc does not succeed */
    284284#define ComAssertRCBreak(vrc, eval)               \
    285     if (1)  { ComAssertRC(vrc); if (!RT_SUCCESS(vrc)) { eval; break; } } else do {} while (0)
     285    if (1) { ComAssertRC(vrc); if (!RT_SUCCESS(vrc)) { eval; break; } } else do {} while (0)
    286286/** Special version of ComAssertFailed that evaluates eval and breaks */
    287287#define ComAssertFailedBreak(eval)                \
    288     if (1)  { ComAssertFailed(); { eval; break; } } else do {} while (0)
     288    if (1) { ComAssertFailed(); { eval; break; } } else do {} while (0)
    289289/** Special version of ComAssertMsgFailed that evaluates eval and breaks */
    290290#define ComAssertMsgFailedBreak(msg, eval)        \
    291     if (1)  { ComAssertMsgFailed (msg); { eval; break; } } else do {} while (0)
     291    if (1) { ComAssertMsgFailed (msg); { eval; break; } } else do {} while (0)
    292292/** Special version of ComAssertComRC that evaluates eval and breaks if rc does not succeed */
    293293#define ComAssertComRCBreak(rc, eval)             \
    294     if (1)  { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { eval; break; } } else do {} while (0)
     294    if (1) { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { eval; break; } } else do {} while (0)
    295295/** Special version of ComAssertComRC that just breaks if rc does not succeed */
    296296#define ComAssertComRCBreakRC(rc)                 \
    297     if (1)  { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { break; } } else do {} while (0)
     297    if (1) { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { break; } } else do {} while (0)
    298298
    299299
    300300/** Special version of ComAssert that evaluates eval and throws it if expr fails */
    301301#define ComAssertThrow(expr, eval)                \
    302     if (1) { ComAssert(expr); if (!(expr)) { throw (eval); } } else do {} while (0)
     302    do { ComAssert(expr); if (!(expr)) { throw (eval); } } while (0)
    303303/** Special version of ComAssertRC that evaluates eval and throws it if vrc does not succeed */
    304304#define ComAssertRCThrow(vrc, eval)               \
    305     if (1)  { ComAssertRC(vrc); if (!RT_SUCCESS(vrc)) { throw (eval); } } else do {} while (0)
     305    do { ComAssertRC(vrc); if (!RT_SUCCESS(vrc)) { throw (eval); } } while (0)
    306306/** Special version of ComAssertComRC that evaluates eval and throws it if rc does not succeed */
    307307#define ComAssertComRCThrow(rc, eval)             \
    308     if (1)  { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { throw (eval); } } else do {} while (0)
     308    do { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { throw (eval); } } while (0)
    309309/** Special version of ComAssertComRC that just throws rc if rc does not succeed */
    310310#define ComAssertComRCThrowRC(rc)                 \
    311     if (1)  { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { throw rc; } } else do {} while (0)
     311    do { ComAssertComRC(rc); if (!SUCCEEDED(rc)) { throw rc; } } while (0)
    312312/** Special version of ComAssert that throws eval */
    313313#define ComAssertFailedThrow(eval)                \
    314     if (1) { ComAssertFailed(); { throw (eval); } } else do {} while (0)
     314    do { ComAssertFailed(); { throw (eval); } } while (0)
    315315
    316316////////////////////////////////////////////////////////////////////////////////
     
    413413    do { \
    414414        if (RT_UNLIKELY(!(expr))) \
    415             return setError(E_INVALIDARG, tr ("Argument %s %s"), \
     415            return setError(E_INVALIDARG, tr("Argument %s %s"), \
    416416                            #arg, Utf8StrFmt msg .c_str()); \
    417417    } while (0)
     
    427427            return setError(E_POINTER, \
    428428                tr("Output argument %s points to invalid memory location (%p)"), \
    429                 #arg, (void *) (arg)); \
     429                #arg, (void *)(arg)); \
    430430    } while (0)
    431431
     
    712712    /**
    713713     * Adds a limited caller. This method is equivalent to doing
    714      * <tt>addCaller (aState, true)</tt>, but it is preferred because provides
     714     * <tt>addCaller(aState, true)</tt>, but it is preferred because provides
    715715     * better self-descriptiveness. See #addCaller() for more info.
    716716     */
     
    829829 * situations. This macro needs to be present inside (better at the very
    830830 * beginning) of the declaration of the class that inherits from
    831  * VirtualBoxSupportTranslation template, to make lupdate happy.
     831 * VirtualBoxTranslatable, to make lupdate happy.
    832832 */
    833833#define Q_OBJECT
     
    849849public:
    850850
    851     Shareable() : mData (NULL), mIsShared(FALSE) {}
     851    Shareable() : mData(NULL), mIsShared(FALSE) {}
    852852    ~Shareable() { free(); }
    853853
     
    943943public:
    944944
    945     Backupable() : Shareable<D> (), mBackupData(NULL) {}
     945    Backupable() : Shareable<D>(), mBackupData(NULL) {}
    946946
    947947    void free()
Note: See TracChangeset for help on using the changeset viewer.

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