incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Brooks (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-589) What is the return value of Notification.confirm?
Date Tue, 08 May 2012 20:41:48 GMT

    [ https://issues.apache.org/jira/browse/CB-589?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13270804#comment-13270804
] 

Michael Brooks commented on CB-589:
-----------------------------------

Hey Jesse,

As far as I know, the Notification API is not based on a standard and is our own home-brewed
concoction.

It looks like the four major platforms return index + 1 as the value for button:

* [iOS CDVNotification.m|https://github.com/apache/incubator-cordova-ios/blob/master/CordovaLib/Classes/CDVNotification.m#L89]
* [Android Notification.java|https://github.com/apache/incubator-cordova-android/blob/master/framework/src/org/apache/cordova/Notification.java#L234]
* [BlackBerry ConfirmAction.java|https://github.com/apache/incubator-cordova-blackberry-webworks/blob/master/framework/ext/src/org/apache/cordova/notification/ConfirmAction.java#L76].
* [WP7 Notification.cs|https://github.com/apache/incubator-cordova-wp7/blob/master/framework/Cordova/Commands/Notification.cs#L180]

So, I think it's safe to say that is the common return value. I'll update the documentation
with a note about the expected returned value.

Any idea if it's a string or integer in JavaScript?
                
> What is the return value of Notification.confirm?
> -------------------------------------------------
>
>                 Key: CB-589
>                 URL: https://issues.apache.org/jira/browse/CB-589
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Docs
>    Affects Versions: 1.6.1
>         Environment: http://docs.phonegap.com/en/1.6.1/cordova_notification_notification.md.html#notification.confirm
>            Reporter: Jesse MacFadyen
>            Assignee: Michael Brooks
>             Fix For: 1.8.0
>
>
> The sample code demonstrates that the confirm callback is called with a 'button' param,
but does not specify the type of the return value, or what it means.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message