Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-5955

Media.onStatus method do not catch some message that are correctly send by the AudioPlayer.java

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • 3.0.0, 3.1.0, 3.2.0, 3.3.0
    • None
    • cordova-js
    • None
    • Kindle Fire , Android 2.3

    Description

      Hi,

      I have a really weird issue with my Kindle Fire (Android 2.3) , i'll try to explain it the best i can (i don't fully understand the problem and it may be not a problem on your side). First, i'm not able to do a sample app to reproduce this bug. (it happens sometimes on my device, but when i do a test app, i never get it)

      I have a piece of code that need to get the MediaSuccess (or Error) callback after playing an audio file, and sometimes, it's juste isn't called.

      I've dug into the Media Plugin, and i've find out that int the AudioPlayer.java , the setState method is working just fine, and send this message to the javascript part with the correct status. ( 4 == MEDIA_STOPPED )

      cordova.require('org.apache.cordova.media.Media').onStatus('c5f1ec7b-9cdf-0a49-3f62-0def8bd2d9b2', 1, 4);

      But, when i put a console.log in the Media.onStatus callback in the Media.js file, i don't get anything, it seems that the message isn't caught.

      So my question is : Do you see how that could be possible ?

      Thanks, i can give you more information if needed.

      Best regards,

      Thibault

      Attachments

        Activity

          People

            Unassigned Unassigned
            tdurand Thibault Durand
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: