Android mobile audio player

panagiotis merakos merakosp at gmail.com
Tue Nov 5 03:06:49 EST 2019


Hello Jacque,

What Android version does your device run? A rough guess is that the
problem is security/permissions related. On Android 9+ there is something
equivalent to iOS ATS that blocks connections that do not comply with some
security standards. You can workaround this by adding a suitable entry to
the Android manifest.

See "Option 2" in this bug report:

https://quality.livecode.com/show_bug.cgi?id=22400

Kind regards,
Panos
--

On Mon, 4 Nov 2019 at 23:40, J. Landman Gay via use-livecode <
use-livecode at lists.runrev.com> wrote:

> I'm unable to get the native player to work on Android, using scripts
> that did work previously. I'm streaming mp3 files from a server, and
> they work fine on desktop so I know the file is being sent. I've also
> tried opening a copy from Dropbox in three different audio players on
> Android and they all play too, so the file format is okay.
>
> The script I'm using, which worked previously:
>
> command createMobileAudioPlayer pURL, pPlayerName
>    -- pURL = remote video or audio file
>    -- pPlayerName = name of player to create
>    mobileControlCreate "player",pPlayerName
>    mobileControlSet pPlayerName, "visible", true
>    mobileControlSet pPlayerName, "rect", getPlayerRect() -- returns a rect
>    mobileControlSet pPlayerName, "showController", true
>    mobileControlSet pPlayerName, "filename", pURL
>    if pURL begins with "http" then
>      showBusyIndicator true -- show spinner until duration is available
>    end if
> end createMobileAudioPlayer
>
> on playerPropertyAvailable tProperty -- sent when enough has content is
> loaded
>    if tProperty is "duration" then
>      showBusyIndicator false -- Remove spinner and start playing
>      setMobileAudioPlayer "listen", "play" -- handles playback
>    end if
> end playerPropertyAvailable
>
> The control does get created, but shows a duration of zero. The
> playerPropertyAvailable message never arrives, so the player doesn't
> start. I've tried starting the player directly from the
> "createMobileAudioPlayer" handler but that also fails.
>
> I'd like to verify that audio is no longer working before I submit a
> report.
>
> --
> Jacqueline Landman Gay         |     jacque at hyperactivesw.com
> HyperActive Software           |     http://www.hyperactivesw.com
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



More information about the use-livecode mailing list