Opened 8 years ago

Last modified 6 weeks ago

#243 new enhancement

Restore native widget mask support

Reported by: dmik Owned by:
Priority: major Milestone:
Component: General Version: 4.6.3
Severity: low Keywords:


Support for native widget masks was disabled with the QT_PM_NATIVEWIDGETMASK macro in r1034. See for more details.

When we meet an application that requires this, we will have to find a solution.

Change History (4)

comment:1 Changed 8 years ago by dmik

The main problem is that by doing a custom qt_WinSetWindowPos() we loose WM_VRNENABLED/WM_VRNDISABLED notifications which is vital for some applications (like VLC).

Myung-Hun suggested to try the following as a solution:

WinLockWindowUpdate( HWND_DESKTOP, hwnd );
WinSetWindowPos( hwnd, hwndInsertBehind, x, y, cx, cy, fl );
WinSetWindowPos( hwnd, hwndInsertBehind, x, y, cx, cy, fl | SWP_NOREDRAW );

comment:2 Changed 8 years ago by dmik

Actually, interesting idea. Most likely WinLockWindowUpdate?() takes into account the flags set with WinSetVisibleRegionNotify?() so that it should send WM_VRNENABLED to hwnd and all children interested in this message (and the second call should send them WM_VRNDISABLED).

However, I think that calling WinSetWindowPos?() with no SWP_NOREDRAW even while locked, will still create update/invalid regions in a way we don't want (this is what qt_WinSetWindowPos() is supposed to fix in the first place), so this call is wrong.

This needs testing.

comment:3 Changed 8 years ago by dmik

JFTR. Working on this task implies implementing QWidgetPrivate::setMask_sys() which is a no-op now. It's easy though (look at the relevant Qt3 function).

comment:4 Changed 6 weeks ago by diver

  • Milestone Qt Enhanced deleted

Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.