Hello, I'm the Google engineer who works on that area of Android. Indeed, the download system is still under development, and you can expect to see changes there at some point.
The two key aspects that you need to know is that: -the MIME type is what matters. The URI extension is not relevant in this case. -in order for the files to be downloaded and for your app to be launched, your application needs to register as a viewer the MIME type of your files (Intent.VIEW_ACTION). There's a high probability that in the long run the files downloaded from the browser will be saved on the SD card (which the emulator can emulate). However, I am not sure what the exact behavior is in the currently available SDKs. (For what it's worth, at the implementation level, there's indeed going to be some code that involves some content providers and some permissions, but at your level you don't need to worry about that, that's only used by the browser to manage its downloads). JBQ On Wed, Mar 26, 2008 at 5:52 PM, hackbod <[EMAIL PROTECTED]> wrote: > > This stuff is still under development, but I believe right now it is > downloaded into a content provider that anyone can access. In the > future, this will be downloaded to a more sophisticated download > manager, that maintains per-item permissions so only the application > requesting a download can access the files it is downloading, and it > can then allow other applications to access particular uris -- such as > when the user clicks on one of the downloads, granting the launched > activity permission to open that particular uri. > > > > On Mar 26, 3:29 pm, Amos <[EMAIL PROTECTED]> wrote: > > Thanks for your reply, Dianne! > > > > I'll register my Activity like you specified. > > > > But how will I be able to access the downloaded file. Will it be > > downloaded to a temp location and have global read permission set on > > it? How will the file's path be passed to me using the Intent sent by > > the browser? > > > > Many thanks, > > > > Amos > > > > On Mar 26, 7:02 pm, hackbod <[EMAIL PROTECTED]> wrote: > > > > > All of Android's file mappings are based on MIME types. As long as > > > your web server is returning the correct MIME type, you can implement > > > an activity that says it knows how to VIEW that MIME type and it will > > > be launched when the user clicks on such a file after downloading it. > > > > > On Mar 26, 3:34 am,Amos<[EMAIL PROTECTED]> wrote: > > > > > > Hi, > > > > > > I would like to implement the following scenario: > > > > > > When a user browses a web page withBrowserand clicks a link with a > > > > special file extension (which is unique to my application, such as > > > > "www.mysite.com/somefile.xxx"), that file will be downloaded and then > > > > my application launched to view the downloaded file. > > > > > > I'd like thebrowserto handle the file download if possible, and when > > > > it's done start one of my activities and provide the file to it. > > > > > > This is desktop behavior and I'm not sure it conforms to the Android > > > > intent/content provider way of doing things - but this is what I'd > > > > like to happen. > > > > > > Any ideas or pointers? > > > > > > Thanks in advance, > > > > > >Amos > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

