pwlin / cordova-plugin-file-opener2

A File Opener Plugin for Cordova
MIT License
314 stars 583 forks source link

Files not opened by external app in Android emulator #300

Open jasonsultana opened 4 years ago

jasonsultana commented 4 years ago

This may not be a bug, but I just wanted to confirm the expected behaviour. Running an Android emulator, opening a file using this plugin launches an external application. Thus, if I press the physical button to show all running apps, there are two (the phonegap app and the gallery/photos/etc external app showing the file).

On a physical device however, the file-viewing app appears as within the same application as the phonegap app, which means that when pressing the back button to close the file viewer, the phonegap app goes back to the index page.

What's the expected behaviour here and is there any explanation as to why the emulator / device behaviour differs in this way?

pwlin commented 4 years ago

My personal opinion is that the external opener application should open itself "separately" and can not mess up the back button from the opening app. But other people might have other opinions, I have no idea what the expected behavior here should be.

The behavior might also depend on the external opener application itself. It might be that some external applications "embed" themselves. Again, I have no idea if that is the case but it might be.

Which Android version/external application you were testing on emulator/physical device?