Hmm, from what I can see, this is a clever way
to do a callback synced on a message loop, like
a COM call crossing appartment boundaries.
Suppose such callback will cause automatic glsel
of the dummy isigraph. But will it disrupt other
true isigraphs used for painting? See, by the time
they get their turn, it will happen already on
their own event, mouse or paint, so they will also
receive their glsel at that time.
Even if you want to paint the other visible isigraph
from the dummy isigraph event, then you can use
explicit glsel. But it is more proper instead to
invalidate the visible isigraph, wd 'setvalid',
(which is marked win32, but it's Java equivalent
is "Component.repaint()"). So by the time it
receives its own dedicated paint, it will be
properly selected.
Does this make sense?
Or there are any other reasons, why it will break
existing code.
--- bill lam <[EMAIL PROTECTED]> wrote:
> Oleg Kobchenko wrote:
> > Could you provide more details of your scenario,
> > where you would not want that to happen.
> >
> > This could help to revise my understanding about
> > automatic glsel.
> >
>
> Oleg, I understand automatical glsel is very useful for most cases but it also
> break codes that uses isigraph not as a picture control. Chris's grid provides
> an excellent example that all kinds of magic on isigraph.
>
> eg, in winsock the hwnd of an dummy isigraph (msgsink) is passed to sdasync
> that
> will trigger a user event (form_msgsink_mbldown) instead of system socket
> event.
> information sent by WSAAsyncSelect will be decoded from sysdata.
>
> NB. =========================================================
>
> NB. WM_LBUTTONDOWN=16b201
> sdasync2=: 4 : 0"0
> if. IFUNIX do. 'not implemented under Unix - please use sdselect' assert 0
> end.
> flags=. OR/ FD_READ,FD_WRITE,FD_OOB,FD_ACCEPT,FD_CONNECT,FD_CLOSE
> hwnd=. x.
> if. >{.WSAAsyncSelectJ ({.y.);hwnd;16b201;flags do. sdsockerror '' else. 0
> end.
> )
>
> NB. this have nothing to do with painting
> NB. and there are other isigraph on the same form
> form_msgsink_mbldown=: 3 : 0
> ... decode lparam from sysdata
> )
>
> NB. =========================================================
>
> I did not mean your purposal is wrong, but only it will break some codes and
> there will be no workaround as glsel is automatic (Similar to autofocus that
> leads to unpreventable change of focus). As I said, I don't mind auto glsel to
> be implemented so long as it can be disabled.
>
> --
> regards,
> bill
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm