[
https://issues.apache.org/jira/browse/CB-4966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13922486#comment-13922486
]
Piotr Zalewa commented on CB-4966:
----------------------------------
English is not my first language as well.
I will try to assume:
1. The link you've posted -
https://developer.mozilla.org/en-US/docs/Web/API/notification is about the
desktop notification system which is displaying alerts and confirmations. As
far as I know it cannot be used for receiving feedback from users. To provide
dialogs (alert, confirm and prompt) Cordova has a Notification API. It is
displaying these dialog windows asynchronously (the rest of the code is still
executed) and provides the results via callback system.
2. You've mentioned master branch. If it is cordova-plugin-dialogs master
branch then I don't see how it would work without src/firefoxos/notification.js
file which development we're discussing here.
3. You've also mentioned permission. Yes. alert, prompt and confirm usage is
not restricted.
4. Not standard. Valid point, but there is no standard and asynchronous dialogs
available in FirefoxOS. Unfortunately you're also right on the issue which
comes from this - changing the skin of FirefoxOS will not be reflected in
dialogs generated by this plugin. Standard alert, prompt and confirm have two
issues which prevent us from using inside Cordova plugin.
4.1 They are not compatible with Cordova API - There is no way to change the
title and button labels.
4.2. They are blocking JS execution. This is major as displaying an alert will
stop other running JS functions. This is an example
http://jsfiddle.net/zalun/DSF5D/
I've been talking about these issues with our apps team at Mozilla. I don't
remember anyone bringing the skin issue, but I still think it's a low cost to
pay when the alternative is a completely incompatible API. The standard API is
still present for developer to use in the app, there is no restriction on that.
On the other side developer has now the power to change the skin of these
dialog windows which obviously might be a pro and a con.
> dialog
> ------
>
> Key: CB-4966
> URL: https://issues.apache.org/jira/browse/CB-4966
> Project: Apache Cordova
> Issue Type: Sub-task
> Components: Plugin Dialogs
> Environment: firefoxos
> Reporter: Piotr Zalewa
>
> I started developing it - only the CSS is left - no idea how to conect it to
> main CSS (is it needed?)
> https://github.com/zalun/cordova-plugin-dialogs
--
This message was sent by Atlassian JIRA
(v6.2#6252)