Re: 2 bugs in Win32Lib
- Posted by CoJaBo <cojabo at suscom.net> Sep 13, 2004
- 429 views
Derek Parnell wrote: > > CoJaBo wrote: > > > > Mousetraps in groups still don't work: > > Weird! I could have sworn I tested this, but you're right. A fix > is needed in two places. > > In "clientToClient()" replace ... > > }}} <eucode> > VOID = w32Func( xClientToScreen, { getHandle( id2 ), pt } ) > > -- convert from screen space > VOID = w32Func( xScreenToClient, { getHandle( id1 ), pt } ) > </eucode> {{{ > > with ... > > }}} <eucode> > VOID = w32Func( xClientToScreen, { getHandle( id1 ), pt } ) > > -- convert from screen space > VOID = w32Func( xScreenToClient, { getHandle( id2 ), pt } ) > </eucode> {{{ > > > and in "createMouseTrap()" replace ... > > }}} <eucode> > pRect[1..2] = clientToClient(lRelId, pWindow, pRect[1..2]) > pRect[3..4] = clientToClient(lRelId, pWindow, pRect[3..4]) > </eucode> {{{ > > with ... > > }}} <eucode> > pRect[3..4] -= pRect[1..2] > pRect[1..2] = clientToClient(lRelId, pWindow, {0,0}) > pRect[3..4] = clientToClient(lRelId, pWindow, pRect[3..4]) > </eucode> {{{ > > > > add/removeStyle() don't work properly on windows: > > Now this one you can't blame on me. Microsoft, in their infinite wisdom, > have decided that you can't set the TOPMOST flag via the normal method. > Instead you need to change the Z-Order. Use this ... > > }}} <eucode> > moveZOrder(w, HWND_TOPMOST) > </eucode> {{{ > > instead of this ... > > }}} <eucode> > addStyle(w,{0,WS_EX_TOPMOST}) > </eucode> {{{ > > > Why did MS do that? Who knows!!! > > I guess I could detect somebody trying to do it the normal way > and silently do it correctly for them. It also happens on a few other styles, but since the other computter is down, I can't check it right now. > > -- > Derek Parnell > Melbourne, Australia >