Copy link to clipboard
Copied
Hey guys, i need help.
I registered some file-extensions for my AIR-Android-App, so when a file is selected, my app receives an Invoke-Event in Flash/AS3 with the path to that file.This works fine for files/downloads/links.
However, some Applications provide a a content-uri instead of a direct file-path (e.g. eMail-attachments before they are downloaded, hell, even local download folders on newer Android OS).
e.g.:
content://gmail-ls/houseatreides@gmail.com/messages/6/attachments/0.1/BEST/false
QUESTION:
How can i turn this into something i can load in AIR/AS3.
Or how can i order the other application or a service to catch the file for me?
If its not possible in AIR, does anyone know of an ANE that gets the job done ?
I found a post how to do it native in Java.
Confirmation that it is (currently) not possible in AIR is also welcome. Thank you.
verdave
Copy link to clipboard
Copied
Hey guys,
Well, I could not find any ANE for that (start contentProvider / contentResolver).
Before i start reading Native-Extension-Tutorials tomorrow:
If you think there are any reasons why this is essentially not possible at all (for whatever reason, restrictions, security, streaming etc), let me know.
thx,
V.
Copy link to clipboard
Copied
Did you ever figure this out? I would also be interested in getting this to work.
Copy link to clipboard
Copied
Unfortunately there are higher priorities in the todo list. For now, we just scan if the invoke-argument starts with a content-scheme and tell the user to download it before opening. If he is sure he already downloaded the file (and still has the content-scheme) we show a file-selection with the most recent downloads.
Not the most elegant way, but it works.
The whole intent stuff is flawed - not inherently - the basic concept is very good.
But the developers of other apps (e.g. Mail-Client) tend to dispatch so many different intents/mimetypes/files/content for the same task/media that its impossible to register for the correct intent/filetype.
I finally installed a nice little App called "IntentIntercept" on Android. Great for analysing whose app sends which intent. It turned out different mail-clients convert mimetypes while sending and then dispatch the wrong intent... Gmail works more reliable than the native mail apps, but its clusterf# because there no standard and your own apps reliability depends on other apps working correctly.
Copy link to clipboard
Copied
I had a custom ane developed for text files that allows you to take the content uri and capture the text file in a string. What mimetype were you trying to get?
Copy link to clipboard
Copied
mola2alex schrieb:
I had a custom ane developed for text files that allows you to take the content uri and capture the text file in a string. What mimetype were you trying to get?
Would you please share the ANE with me? You would make my day!
This is my email, please contact me: blog@wolke7.net
Find more inspiration, events, and resources on the new Adobe Community
Explore Now