I am calling the intent like this (Flutter Dart):
AndroidIntent intent = AndroidIntent(
action: "android.intent.action.VIEW",
data: link, // public direct download link with no Auth
type: mime, // mimeType
);
await intent.launch();
This automatically opens the device default music player, instead allowing me to select which one I would like to use (as for example Solid Explorer).
If I force to open intent using specific package, Poweramp opens and plays the music just fine:
AndroidIntent intent = AndroidIntent(
action: "android.intent.action.VIEW",
data: link,
type: mime,
package: (mime?.startsWith("audio") ?? false)
? "com.maxmpz.audioplayer"
: null, // here forcing to use Poweramp
);
await intent.
launch();
The direct URL looks like this:
https://cloud.seafile.com/files/adee6094/foo.flac
Its not encrypted, no aurh required. Its probably issue on my side (calling the intent wrong). Would you please spare some time and tell me about it please?