简体   繁体   English

Android画廊选择像Whatsapp

[英]Android gallery pick like Whatsapp

This question has been asked before but I'm afraid answers might be outdated. 之前曾有人问过这个问题,但恐怕答案可能会过时。 How can I use the native gallery app (say API 14 on) to achieve multiple image selection like WhatsApp? 如何使用本机图库应用程序(启用API 14)来实现多种图片选择,例如WhatsApp?

do you mean: 你的意思是:

Intent intent = new Intent();
intent.setType("image/*");
intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
intent.setAction(Intent.ACTION_GET_CONTENT);
startActivityForResult(Intent.createChooser(intent,"Select Picture"), 1);

Note: the EXTRA_ALLOW_MULTIPLE option is only available in Android API 18 and higher. 注意:EXTRA_ALLOW_MULTIPLE选项仅在Android API 18及更高版本中可用。

This link talks about creating custom image picker with multiple select. 此链接讨论有关创建具有多个选择的自定义图像选择器的信息。

没有一个有效,所以我最终使用了Android的一个开放源代码库: Universal Image Loader

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM