Page 1 of 1

Need to shut down Android player -- PLEASE!

Posted: Mon Dec 28, 2015 10:11 am
by DR White
I have been banging my head all day yesterday trying several commands to shut down an media player, that has already been playing a mp3 file on an Android phone, so that when I my stack runs and start a player within LC, their are two players running that sound quit annoying. The commands that I have tried are:

play "stop"
play empty
mobileControlDelete sPlayerId
mobileControlDelete "Player"

Its like, if the the Android player is initiated from the phone itself there is no way that LC can shut it down. Tell me its not true!

Thanks,

David

Re: Need to shut down Android player -- PLEASE!

Posted: Mon Dec 28, 2015 1:16 pm
by bn
Hi David,

have a look at mobileControlDo in the dictionary

from the dictionary:
mobileControlDo
.....
Player Specific Actions
• play - Start playing the content of the player.
• pause - Pause the content at the current position.
• stop - Stop playing the content of the player.
looks like stop should work.

Kind regards
Bernd

Re: Need to shut down Android player -- PLEASE!

Posted: Mon Dec 28, 2015 2:51 pm
by DR White
Bernd,

Thanks for your effort, but "mobileControlDo" did not work.
I think one of the problems is that since the player is started automatically when the browser sees a mp3 file it uses the Android native player and I don't know the player name. Unfortunately, when the browser is closed the player keeps playing.

Re: Need to shut down Android player -- PLEASE!

Posted: Mon Dec 28, 2015 5:24 pm
by jacque
Is the browser a native control your app created or one installed on the device separately? Do you control the content? I'm not clear on what behavior you're seeing. Can you describe the recipe?

Re: Need to shut down Android player -- PLEASE!

Posted: Mon Dec 28, 2015 8:50 pm
by DR White
Jacquue,


The browser is one that was created with LC 7.1. The player that I cannot shutdown, seems to be one that automatically appears when the LC browser senses a mp3 file (I am guessing).

Short version:

My app creates a Android player, launches a browser and goes to a website with mp3 files listed.
The user touches the file they wish hear the Samsung Tab 3 screen goes black and a very small object that has a very small "Play"/"Pause" button appears in the middle of a black screen.
The mp3 file plays without touching the small object in the center of the screen (which is the way I want).
There is a "Done" button at the bottom of the screen, that the the user touches, shuts down the LC created player and everything is fine!
BUT, if the user touches the very small object that has a very small "Play"/"Pause" button in the middle of the black screen, then there are two audios that are played and no way of shutting down the one that was started with the very small "Play"/"Pause" button.

Thanks,

David