Hello! I ́ve tried to implement the soundcloud api, to my app:
I create an HTML component with this code:
in page show, I add this code (acording to the api documentation)
(function(){
var widgetIframe = document.getElementById('sc-widget'),
widget = SC.Widget(widgetIframe);
Code: Select all
widget.bind(SC.Widget.Events.READY, function() {
widget.bind(SC.Widget.Events.PLAY, function() {
// get information about currently playing sound
widget.getCurrentSound(function(currentSound) {
console.log('sound ' + currentSound.get('') + 'began to play');
});
});
// get current level of volume
widget.getVolume(function(volume) {
console.log('current volume value is ' + volume);
});
// set new volume level
widget.setVolume(50);
// get the value of the current position
});
}());
It works perfectly in my computer( Firefox):
But if test on device (both app tester and installing .apk) dont reproduce the tracks...the screen is the same, as the screen shot above ...
Hope you can help me to figure out
Regards