Skip to content
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

个别手机选择某些图片后,无法获取文件名 #2225

Closed
bxjxxyy opened this issue Dec 23, 2021 · 3 comments
Closed

个别手机选择某些图片后,无法获取文件名 #2225

bxjxxyy opened this issue Dec 23, 2021 · 3 comments

Comments

@bxjxxyy
Copy link

bxjxxyy commented Dec 23, 2021

例如:努比亚Z17,安卓9。手机截屏的图片选择后无法得到文件名,下载的图片/保存的图片可以正常得到文件名。
在选择图片后,onActivityResult中得到的LocalMedia对象中的fileName为null。
我跟踪了一下,大概是在下面这个地方data.getString(fileNameColumn)如果是截屏图片就会得到null。具体是什么导致的还不明白。
`
int fileNameColumn = data.getColumnIndexOrThrow(PROJECTION_PAGE[8]);
String fileName = data.getString(fileNameColumn);

`

@wojiaosuxiaobai
Copy link

兄弟问题解决了吗,我这也有同样的问题

@bxjxxyy
Copy link
Author

bxjxxyy commented Feb 9, 2022

没解决,原因不明。
通过其他方式实现了我的需求。能获取filepath,filepath是完整路径包含文件名的,自己截取

@LuckSiege LuckSiege reopened this Jun 4, 2022
@LuckSiege
Copy link
Owner

v3.10.0版本已修复

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants