Changeset 936 for trunk/src/gui


Ignore:
Timestamp:
Aug 4, 2011, 12:42:23 AM (14 years ago)
Author:
Dmitry A. Kuminov
Message:

OS/2: Fixed: Modal widgets could go to behind blocked ones.

This in particular affected parent-less modal widgets (e.g. the
Session Manager dialog in Qt Creator).

File:
1 edited

Legend:

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

    r786 r936  
    143143    QWidgetPrivate *dptr() { return d_func(); }
    144144    QRect frameStrut() const { return d_func()->frameStrut(); }
     145
    145146    bool        pmEvent(QMSG *m, MRESULT *r) { return QWidget::pmEvent(m, r); }
    146147//  void        markFrameStrutDirty() { data->fstrut_dirty = 1; }
     
    11021103                        // FID_SYSMENU) should not cause the focus to be lost.
    11031104                        if (WinQueryWindow(hwnd, QW_OWNER) ==
    1104                                 ((QETWidget*)widget->window())->dptr()->frameWinId())
     1105                                ((QETWidget*)widget->window())->frameWinId())
    11051106                            break;
    11061107                        if (!widget->isWindow())
     
    13111312        }
    13121313
     1314
     1315
     1316
     1317
     1318
     1319
     1320
     1321
     1322
     1323
     1324
     1325
     1326
     1327
     1328
     1329
     1330
     1331
     1332
     1333
     1334
     1335
     1336
     1337
     1338
     1339
     1340
     1341
     1342
     1343
     1344
     1345
     1346
    13131347        case WM_QUERYTRACKINFO: {
    13141348            QWExtra *x = widget->xtra();
     
    14391473    ignoreNextMouseReleaseEvent = false;
    14401474
    1441     // go through all top-level widgets and disable those that should be
    1442     // blocked by the modality (this in particular will disable activation
    1443     // through clicking on the title bar and also state change throuhg titlebar
    1444     // buttons)
     1475    // go through all top-level widgets and disable those that should be
     1476    // b
     1477    //
     1478    // )
    14451479    QWidgetList list = QApplication::topLevelWidgets();
    14461480    foreach(QWidget *w, list) {
    1447         if (QApplicationPrivate::isBlockedByModal(w))
     1481        if (
    14481482            WinEnableWindow(w->d_func()->frameWinId(), FALSE);
     1483
    14491484    }
    14501485}
     
    14531488{
    14541489    if (qt_modal_stack) {
    1455         // go through all affected top-level widgets and re-enable them
    1456         QWidgetList list = QApplication::topLevelWidgets();
    1457         foreach(QWidget *w, list) {
    1458             if (QApplicationPrivate::isBlockedByModal(w))
    1459                 WinEnableWindow(w->d_func()->frameWinId(), TRUE);
    1460         }
    14611490        if (qt_modal_stack->removeAll(widget)) {
    14621491            if (qt_modal_stack->isEmpty()) {
     
    14801509        }
    14811510        ignoreNextMouseReleaseEvent = true;
     1511
     1512
     1513
     1514
     1515
     1516
     1517
     1518
     1519
    14821520    }
    14831521    app_do_modal = qt_modal_stack != 0;
     
    27322770    myCaseEnd()
    27332771
     2772
     2773
     2774
     2775
     2776
     2777
    27342778    myCaseBegin(WM_WINDOWPOSCHANGED)
    27352779        debug << *((PSWP) qmsg.mp1);
     
    27852829    myCaseEnd()
    27862830
    2787     myCaseBegin(WM_ADJUSTWINDOWPOS)
    2788         break;
    2789     myCaseEnd()
    2790 
    27912831    myCaseBegin(WM_VRNDISABLED)
    27922832        break;
     
    27972837
    27982838    myCaseBegin(WM_SHOW)
     2839
     2840
     2841
     2842
     2843
     2844
     2845
    27992846        break;
    28002847    myCaseEnd()
Note: See TracChangeset for help on using the changeset viewer.