Thanks Stefan for reviewing these changes. Agreed on all of your points. I've adopted them and checked this in now since I didn't get any other feedback. >> PS.: I agree with the proposed change to after-make-frame-functions >> (not >> selecting the frame immediately), but this doesn't relate to the >> bug at >> hand. Also, I don't know why the modeline isn't updated. > > Agreed, this is a separate problem. OK, are you keeping track of it, should we file another bug report to do so? >> frame.c: >> Fraise_frame: do not make invisible frames visible (Stefan Monnier). > > This is not OK for 23.1. It might be good to try it for 23.2. > Also I think your other changes should make it unnecessary for the > problem we're trying to fix. As above. >> keyDown: do not swallow events that aren't re-sent if frame isn't >> key window. > > If you say so. What does Adrian say?? I'm just fixing the workaround, even though I don't fully understand the bug that leads to the problem. >> drawRect: do not set visibility/iconified flags because drawRect >> may be >> called by NSView even if the frame is hidden. > > Do you happen to know why/when NSView might be called even for a frame > that's not visible? Unfortunately not, but invisibility does not guarantee absence of drawRect messages unless this is promised somewhere in the NS API. I do think that my patch here is right, though, as other ports set visibility in more obvious places. Perhaps we should make sure that we don't get a lot of drawRect calls for totally obscured frames, which would possibly be a performance- eater.