- From: Darin Fisher <darin@chromium.org>
- Date: Wed, 26 Aug 2009 21:10:13 -0700
On Wed, Aug 26, 2009 at 12:54 PM, Darin Fisher <darin at chromium.org> wrote: > On Wed, Aug 26, 2009 at 12:49 PM, Jeremy Orlow <jorlow at chromium.org>wrote: > >> On Wed, Aug 26, 2009 at 11:17 AM, Darin Fisher <darin at chromium.org>wrote: >> >>> On Wed, Aug 26, 2009 at 1:27 AM, Jeremy Orlow <jorlow at chromium.org>wrote: >>> >>>> On Wed, Aug 26, 2009 at 12:51 AM, Darin Fisher <darin at chromium.org>wrote: >>>> >>>>> On Sun, Aug 23, 2009 at 11:33 PM, Robert O'Callahan < >>>>> robert at ocallahan.org> wrote: >>>>> >>>>>> That behaviour sounds worse than what Firefox currently does, where an >>>>>> alert disables input to all tabs in the window (which is already pretty >>>>>> bad), because it willl make applications in visually unrelated tabs and >>>>>> windows hang. >>>>>> >>>>> >>>>> You can have script connections that span multiple tabs in multiple >>>>> windows, so in order to preserve the run-to-completion semantics of >>>>> JavaScript, it is important that >>>>> window.{alert,confirm,prompt,showModalDialog} be modal across all windows in >>>>> the browser. This is why those APIs suck rocks, and we should never create >>>>> APIs like them again. >>>>> >>>> >>>> I don't understand your point here. Are you saying that the current >>>> firefox behavior is not correct, that releasing the storage lock on these >>>> events is not correct, or something else? >>>> >>> >>> I meant that the current Firefox behavior is technically incorrect. No >>> one likes app modal dialogs, but how else can you guarantee >>> run-to-completion semantics? How else do you prevent other scripts from >>> modifying your state while you are stuck calling into window.alert(). >>> >> >> I don't know much about this issue, but it seems like something that >> should either be fixed in Firefox (and other browsers?) or changed in the >> spec. I'm interested to hear if others have thoughts on it. >> > > Chrome and Safari both implement app-modal alerts. Firefox and IE > implement window modal, which is clearly buggy, but of course the world > hasn't imploded. I haven't tested Opera. > > Personally, I would like to change Chrome to not put up app modal alerts. > I think it is bad UI, but I'm not sure how to do so without also breaking > the contract that JavaScript execution appear single threaded. > > -Darin > Also, just for completeness, if you consider scoping an alert to a window, then what happens when an alert is generated by another window? If each alert is implemented using a nested event loop, then closing the first alert will not return execution control back to the page that call alert. So, the user will be left with a dead browser window. This is very similar to the problem that exists with app modal alerts where one window is inactive while another is showing an alert. Without something like co-routines, I'm not sure how to solve this. -Darin -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20090826/e3dfb49c/attachment.htm>
Received on Wednesday, 26 August 2009 21:10:13 UTC