Ignore:
Timestamp:
Nov 13, 2006, 12:05:13 AM (19 years ago)
Author:
dmik
Message:

kernel: Attempted to fix some spontaneous Qt application traps during window management (seen in Psi a couple of times after showing big tool tips, see ticket:34 for more info):

  • Deleted modal widgets could be left referenced by widgets they were blocking (through the QWL_QTMODAL window word).
  • Custom window data was not initialized to zero after window creation.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel/qwidget_pm.cpp

    r135 r153  
    941941*/
    942942
     943        // strictly speaking, PM is not obliged to initialize window data
     944        // with zeroes (although seems to), so do it ourselves
     945        for ( LONG i = 0; i <= QT_EXTRAWINDATASIZE - 4; i += 4 )
     946            WinSetWindowULong( id, i, 0 );
     947
    943948        // When the FS_SHELLPOSITION flag is specified during WC_FRAME window
    944949        // creation its size and position remains zero until it is shown
     
    10831088    QWidget *blockedBy = 0;
    10841089    if ( isTopLevel() )
    1085         blockedBy = (QWidget*) WinQueryWindowULong( winId(), QWL_QTMODAL );
     1090        blockedBy = (QWidget*) WinQueryWindowPtr( winId(), QWL_QTMODAL );
    10861091    if ( !blockedBy && parentWidget() )
    1087         blockedBy = (QWidget*) WinQueryWindowULong(
     1092        blockedBy = (QWidget*) WinQueryWindowPtr(
    10881093            parentWidget()->topLevelWidget()->winId(), QWL_QTMODAL );
    10891094    if ( blockedBy ) {
     
    11511156    blockedBy = 0;
    11521157    if ( parentWidget() )
    1153         blockedBy = (QWidget*) WinQueryWindowULong(
     1158        blockedBy = (QWidget*) WinQueryWindowPtr(
    11541159            parentWidget()->topLevelWidget()->winId(), QWL_QTMODAL );
    11551160    if ( blockedBy ) {
Note: See TracChangeset for help on using the changeset viewer.