VirtualBox

Changeset 95964 in vbox


Ignore:
Timestamp:
Aug 1, 2022 2:20:48 PM (3 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
152721
Message:

Additions/VBoxTray: Got rid of DDCLOG() -- use LogXFunc or similar instead. We already have too many custom logging and #ifdefs hells already.

Location:
trunk/src/VBox/Additions/WINNT/VBoxTray
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/VBoxTray/VBoxHelpers.cpp

    r95827 r95964  
    117117                   int iNewPosX, int iNewPosY)
    118118{
    119     DDCLOG(("nRects %d, iPrimary %d, iResized %d, NewWidth %d, NewHeight %d\n", nRects, uPrimary, uResized, iNewWidth, iNewHeight));
     119    Log4Func(("nRects %d, iPrimary %d, iResized %d, NewWidth %d, NewHeight %d\n", nRects, uPrimary, uResized, iNewWidth, iNewHeight));
    120120
    121121    RECTL *paNewRects = (RECTL *)alloca (sizeof (RECTL) * nRects);
     
    140140        /* Find the next adjacent original rect in x positive direction. */
    141141        unsigned iNextRect = hlpNextAdjacentRectXP(paRects, nRects, iRect);
    142         DDCLOG(("next %d -> %d\n", iRect, iNextRect));
     142        Log4Func(("next %d -> %d\n", iRect, iNextRect));
    143143
    144144        if (iNextRect == ~0 || iNextRect == uPrimary)
     
    154154        if (delta != 0)
    155155        {
    156             DDCLOG(("XP intersection right %d left %d, diff %d\n",
    157                      paNewRects[iRect].right, paNewRects[iNextRect].left,
    158                      delta));
     156            Log4Func(("XP intersection right %d left %d, diff %d\n",
     157                      paNewRects[iRect].right, paNewRects[iNextRect].left,
     158                      delta));
    159159
    160160            paNewRects[iNextRect].left += delta;
     
    168168        /* Find the next adjacent original rect in x negative direction. */
    169169        unsigned iNextRect = hlpNextAdjacentRectXN(paRects, nRects, iRect);
    170         DDCLOG(("next %d -> %d\n", iRect, iNextRect));
     170        Log4Func(("next %d -> %d\n", iRect, iNextRect));
    171171
    172172        if (iNextRect == ~0 || iNextRect == uPrimary)
     
    182182        if (delta != 0)
    183183        {
    184             DDCLOG(("XN intersection left %d right %d, diff %d\n",
    185                      paNewRects[iRect].left, paNewRects[iNextRect].right,
    186                      delta));
     184            Log4Func(("XN intersection left %d right %d, diff %d\n",
     185                      paNewRects[iRect].left, paNewRects[iNextRect].right,
     186                      delta));
    187187
    188188            paNewRects[iNextRect].left += delta;
     
    196196        /* Find the next adjacent original rect in y positive direction. */
    197197        unsigned iNextRect = hlpNextAdjacentRectYP(paRects, nRects, iRect);
    198         DDCLOG(("next %d -> %d\n", iRect, iNextRect));
     198        Log4Func(("next %d -> %d\n", iRect, iNextRect));
    199199
    200200        if (iNextRect == ~0 || iNextRect == uPrimary)
     
    210210        if (delta != 0)
    211211        {
    212             DDCLOG(("YP intersection bottom %d top %d, diff %d\n",
    213                      paNewRects[iRect].bottom, paNewRects[iNextRect].top,
    214                      delta));
     212            Log4Func(("YP intersection bottom %d top %d, diff %d\n",
     213                      paNewRects[iRect].bottom, paNewRects[iNextRect].top,
     214                      delta));
    215215
    216216            paNewRects[iNextRect].top += delta;
     
    224224        /* Find the next adjacent original rect in x negative direction. */
    225225        unsigned iNextRect = hlpNextAdjacentRectYN(paRects, nRects, iRect);
    226         DDCLOG(("next %d -> %d\n", iRect, iNextRect));
     226        Log4Func(("next %d -> %d\n", iRect, iNextRect));
    227227
    228228        if (iNextRect == ~0 || iNextRect == uPrimary)
     
    238238        if (delta != 0)
    239239        {
    240             DDCLOG(("YN intersection top %d bottom %d, diff %d\n",
    241                      paNewRects[iRect].top, paNewRects[iNextRect].bottom,
    242                      delta));
     240            Log4Func(("YN intersection top %d bottom %d, diff %d\n",
     241                      paNewRects[iRect].top, paNewRects[iNextRect].bottom,
     242                      delta));
    243243
    244244            paNewRects[iNextRect].top += delta;
     
    256256        paRects[iRect].top    = paNewRects[iRect].top    - iOffsetY;
    257257        paRects[iRect].bottom = paNewRects[iRect].bottom - iOffsetY;
    258         DDCLOG((" [%d]: %d,%d %dx%d -> %d,%d %dx%d%s\n",
    259                 iRect,
    260                 paRects[iRect].left, paRects[iRect].top,
    261                 paRects[iRect].right - paRects[iRect].left,
    262                 paRects[iRect].bottom - paRects[iRect].top,
    263                 paNewRects[iRect].left, paNewRects[iRect].top,
    264                 paNewRects[iRect].right - paNewRects[iRect].left,
    265                 paNewRects[iRect].bottom - paNewRects[iRect].top,
    266                 iRect == uPrimary? " <- primary": ""));
     258        Log4Func((" [%d]: %d,%d %dx%d -> %d,%d %dx%d%s\n",
     259                  iRect,
     260                  paRects[iRect].left, paRects[iRect].top,
     261                  paRects[iRect].right - paRects[iRect].left,
     262                  paRects[iRect].bottom - paRects[iRect].top,
     263                  paNewRects[iRect].left, paNewRects[iRect].top,
     264                  paNewRects[iRect].right - paNewRects[iRect].left,
     265                  paNewRects[iRect].bottom - paNewRects[iRect].top,
     266                  iRect == uPrimary? " <- primary": ""));
    267267    }
    268268    return;
  • trunk/src/VBox/Additions/WINNT/VBoxTray/VBoxHelpers.h

    r95827 r95964  
    2222#endif
    2323
    24 // #define DEBUG_DISPLAY_CHANGE
    25 
    26 /** @todo r=andy WTF? Remove this!! */
    27 #ifdef DEBUG_DISPLAY_CHANGE
    28 #   define DDCLOG(a) Log(a)
    29 #else
    30 #   define DDCLOG(a) do {} while (0)
    31 #endif /* !DEBUG_DISPLAY_CHANGE */
    32 
    3324extern int  hlpReportStatus(VBoxGuestFacilityStatus statusCurrent);
    3425extern void hlpReloadCursor(void);
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