Changeset 784 for trunk/src/gui/kernel


Ignore:
Timestamp:
Oct 7, 2010, 12:17:37 AM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

gui: Log more WM_* messages in debug mode.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gui/kernel/qapplication_pm.cpp

    r748 r784  
    17471747bool QETWidget::translateMouseEvent(const QMSG &qmsg)
    17481748{
    1749 #if defined(QT_DEBUGMSGFLOW) && 0
    1750     static const char *msgNames[] = { // 11 items
    1751         "WM_MOUSEMOVE",
    1752         "WM_BUTTON1DOWN", "WM_BUTTON1UP", "WM_BUTTON1DBLCLK",
    1753         "WM_BUTTON2DOWN", "WM_BUTTON2UP", "WM_BUTTON2DBLCLK",
    1754         "WM_BUTTON3DOWN", "WM_BUTTON3UP", "WM_BUTTON3DBLCLK",
    1755         "WM_???"
    1756     };
    1757     int msgIdx = qmsg.msg - WM_MOUSEMOVE;
    1758     if (msgIdx < 0 || msgIdx > 9)
    1759         msgIdx = 10;
    1760     qDebug("%s (%04lX): [%08lX/%p:%s] %04hd,%04hd hit=%04hX fl=%04hX",
    1761            msgNames[msgIdx], qmsg.msg, qmsg.hwnd, this, widgetName(this),
    1762            SHORT1FROMMP(qmsg.mp1), SHORT2FROMMP(qmsg.mp1),
    1763            SHORT1FROMMP(qmsg.mp2), SHORT2FROMMP(qmsg.mp2));
    1764 #endif
    1765 
    17661749    if (!isWindow() && testAttribute(Qt::WA_NativeWindow))
    17671750        Q_ASSERT(internalWinId() != NULLHANDLE);
     
    26292612    debug.nospace() << "SWP(" << swp.x << "," << swp.y
    26302613                    << " " << swp.cx << "x" << swp.cy << " "
    2631                     << qDebugFmtHex(swp.hwndInsertBehind)
     2614                    << qDebugFmtHex(swp.hwndInsertBehind)
    26322615                    << fl.constData() << ")";
    26332616    return debug.space();
     
    26402623    #define myCaseEnd() }
    26412624
     2625
     2626
    26422627    switch (qmsg.msg) {
     2628
     2629
     2630
     2631
     2632
     2633
     2634
     2635
     2636
     2637
     2638
     2639
     2640
     2641
     2642
     2643
     2644
     2645
     2646
     2647
     2648
     2649
     2650
     2651
     2652
     2653
     2654
     2655
     2656
     2657
     2658
     2659
     2660
    26432661
    26442662    myCaseBegin(WM_CHAR)
     
    27642782    myCaseEnd()
    27652783
     2784
     2785
     2786
     2787
     2788
     2789
     2790
     2791
     2792
     2793
     2794
     2795
     2796
     2797
     2798
    27662799    default:
    27672800        debug.nospace() << "WM_" << qDebugFmtHex(qmsg.msg) << ":";
     
    27712804    }
    27722805
     2806
     2807
     2808
     2809
     2810
     2811
     2812
     2813
     2814
     2815
     2816
     2817
     2818
     2819
     2820
     2821
     2822
     2823
     2824
     2825
     2826
     2827
     2828
     2829
     2830
     2831
     2832
     2833
     2834
     2835
     2836
     2837
     2838
     2839
    27732840    return debug;
    27742841
Note: See TracChangeset for help on using the changeset viewer.