Cordova / Phonegap photo browser

我是研究僧i 提交于 2019-12-11 02:14:51

问题


I would like to create an application for iOS and Android that (among other things) allows the user to browse the device's photos and select some of them. Thus I would like to present the user with a list of directories containing photos and once a directory is opened, a gallery of the images is displayed.

My questions are:

1) Is there a standard way in Cordova to get a list of the "library" directories such as camera photos, facebook photos, viber photos, screenshots etc.?

2) Is there a way with Cordova to get a thumbnail of each image to display in the gallery (or even better take advantage of each OS' thumbnail caching system), since resizing the original images will run the application quickly out of resources?

Notes:

a) I know about the camera plugin, that has a nice native dialog to pick an image, but it only allows the user to pick one image.

b) I know about the image picker plugin, but it doesn't search in folders other than the camera's directory (i.e. no Facebook, Viber etc. directories).

c) I don't like a & b approaches. Instead I would prefer to display a gallery directly in my app rather than showing a dialog for this.

来源:https://stackoverflow.com/questions/28997384/cordova-phonegap-photo-browser

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!