-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
如何判断选择的是图片还是视频格式呢 #61
Comments
现在用RxImagePicker 里知乎的ui 从返回的t.uri 里判断是否包含 images 或 video,来判断是否是图片还是视频,不知道这种方法会不会有问题 |
可以考虑为知乎和微信主题的返回结果,增加对应的字段以告知媒体资源的类型(视频、图片、音频),该功能预计会在下版本更新 |
该功能2.5.0版本更新,知乎 和 微信 主题增加了返回 资源文件类型 的字段: 代码示例:val mimeType = result.getStringExtra("EXTRA_OPTIONAL_MIME_TYPE", "")
Log.d(TAG, "mime types: $mimeType") 使用方式参考类似代码:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
原库Matisse 可根据选择后的后缀格式进行判断 比如 123.jpg
但是这个库,并没有带格式的后缀了 123
The text was updated successfully, but these errors were encountered: