Unable to control animation. @canuckistani has half the right: both the SDK notifications
and HTML5 notifications use the same basic service, nsIAlertsService
. This service does not allow you to control the duration.
Desktop Firefox does not use services at the system level, with the exception of the implementation of Metro (still officially released and does not support add-ons in any case IIRC). Instead, they use an implementation of the XUL alert service, which is just a few XULs with some Javascript and some extra CSS . And some code to open a window .
Depending on any prefix, either a hard-coded 4000 ms timeout via setTimeout
or a 4S CSS animation will be used.
While this is not convenient, in particular, not in the SDK add-in, where you do not receive a chrome package to open your own XUL windows, you can copy / paste implement your own XUL window plug with controls for a while, or even override Firefox by default. I canβt remember this name right now, but I know that there is or was at least one add-on that does just that, overriding the built-in implementation and allowing the user to choose an individual timeout, among other things.
source share