How to prompt user to answer a question (yes or no)?
Andrew Swan
aswan at mozilla.com
Sat Aug 19 16:59:17 UTC 2017
On Sat, Aug 19, 2017 at 8:52 AM, Manuel Reimer <manuel.reimer at gmx.de> wrote:
> Hello,
>
> currently I'm using "window.confirm". This works "OK" but doesn't look
> that nice and I would like to have a checkbox in the message box to allow
> the user to choose that his choice should be remembered.
>
> Is there a nice, simple way to do this?
>
> I need my code to block as long as it takes for the user to make a choice,
> so *please* no asynchronous stuff like promises.
>
You're swimming upstream with that last comment -- modal dialogs are
problematic for a number of reasons. If you insist on something
synchronous, I think the answer is no, there isn't a better option than
window.confirm.
-Andrew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/dev-addons/attachments/20170819/d33eb38c/attachment.html>
More information about the Dev-addons
mailing list