cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (CB-8917) Add api/way to get plugins results even when Cordova activity restarts
Date Fri, 22 Jan 2016 05:50:39 GMT


ASF GitHub Bot commented on CB-8917:

Github user nikhilkh commented on a diff in the pull request:
    --- Diff: www/docs/en/dev/guide/platforms/android/ ---
    @@ -116,10 +196,21 @@ onResume(event) {
         if(event.pendingResult) {
             // Figure out whether or not the plugin call was successful
             if(event.pendingResult.pluginStatus === "OK") {
    -            successCallback(event.result);
    +            successCallback(event.pendingResult.result);
    --- End diff --
    What does this successCallback refer to? Perhaps you want to give a realistic example
with cordova-plugin-camera. I would recommend including the same example in cordova-pluign-camera

> Add api/way to get plugins results even when Cordova activity restarts  
> ------------------------------------------------------------------------
>                 Key: CB-8917
>                 URL:
>             Project: Apache Cordova
>          Issue Type: Improvement
>          Components: Android
>            Reporter: Bnaya
>            Assignee: Richard B Knoll
> In android when you have a plugin that opens new activity the CordovaActivity will be
killed and you won't get the result from the plugin.
> The new activity will get the results but because the plugin objects are dead and the
webview reloaded you can get the data to the js callback.
> The most noticeable example is the camera plugin. (And maybe its the same with even more
> possible solution for this is to add metadata to the device ready event with incoming
data from plugins.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message