We're building some gallery app.
Recently some users complain that they can't see some folders from their sd card (they can't see it on the stock gallery too).
We check with them and see that there is no .nomedia file in the folder.
We also check on our phones and sd cards are read perfectly.
Do you have any idea why is that happen or any way to reproduce it?
Related
Using stock Android 6.0 (Marshmallow), the stock (LG V10) gallery application (version 4.72.6) is including pictures and other files that have a timestamp newer than the .nomedia file timestamp. I have not been able to test this on other devices to see if it is LG specific.
Recreating the .nomedia file will update the timestamp, and hide all older pictures. Also, the folder being index is a hidden one (starts with a '.'), not sure why it is also being indexed in the first place.
There seem to be a lot of topics on this indexing issue, but none associated with the timestamps. It appears this could have been done intentionally, but it is very undesirable since several applications cannot access the microSD card after the Android permissions update.
I have a problem moving my application to the SD Card , I learnt to enable an app to move to the SD card , i need to take care of two important things
min SDK must be greater than or equal to 10
set android:installLocation="auto" in android manifest , I learnt that doing that android :installLocation="auto" will do the job than setting it to External
My problem is that Whenever i have an app whose size is less than 50 Mb this works fine , But if the size of the app exceeds more than that, I receive an error stating that "Not enough size in SD card" , I checked my SD card and I am sure that it had enough space to accomodate the app ! what could be the problem and suggest me some possible solutions which would help me !
Android 4.2 added multi user support for tablets. Now when you request a path to save files on external storage via a method like Environment.getExternalStorageDirectory() or Context.getExternalFilesDir(null) you get a value like: /storage/emulated/#/Android/data/your.package.name/ The # being a number depending on what user you are currently logged in as.
This works fine but I have noticed that DDMS's File Explorer and also the Android File Transfer are not able to see these files.
DDMS's File Explorer cannot see anything past storage/emulated/ except an empty legacy folder. File Transfer can see the /Android/data/ folder but for an app running as debug, its files are not visible (but they do exist).
Is there any way to get DDMS or File Transfer to work with these devices? (Hopefully without having to root the device...)
Thanks
Aha!
Try /mnt/shell/emulated/N, for various values of N like 0. That seems to map properly on my Nexus 10 and my Galaxy Nexus in DDMS. I cannot comment on the File Transfer tool, though.
BTW, the numbers are not sequential for the users. So on my N10, the original user is 0, the second user is 10.
As Jelly Bean 4.2 supports multi-user profiles, the sd-card browsing has been changed a bit.
You must have ADT v 21 or higher to browse emulated sd-card.
/mnt/shell/emulated/0 is for default user. See the image attached for more detail.
Enlarge Image
I need to test a function that needs to picks some images from the gallery of Android JellyBean Emulator.
So I have downloaded from internet using the own browser of the emulator (that is slow as the hell) some images.
The images appears in the downloaded files but not in the Gallery of Emulator.
In the GingerBread emulator when I download an images from the browser these appear automatically in the gallery.
How could I force the emulator to find the images?
In the old emulator the media scanner was enabled, due to large amount of resource needed the new version has the media scanner disabled by default.
If you want to see the images in the gallery,
in the main menu of Jelly Bean Emulator go in:
DevTools->Media Provider and click "Scan SD Card".
In this way you should see the images in the gallery
If doesn't, probably the images saved aren't properly located in SD card,
-use DDMS(you can find it in the Android\android-sdk\tools folder
-Click on device menu and select File Explorer
-Go to mnt\sdcard
-Click the button "Push file into device" to upload images
If I correct, you want some pictures in emulator's gallery. I think you can upload a picture file in DDMS file browser, or using 'adb push' command.
I have an app that displays an an image in an ImageView using the setImageDrawable(Drawable) method. However, with the release of the Droid Incredible the images are coming up as a blank screen. I am using Drawable.createFromPath(Environment.getExternalStorageDirectory() + "\\imagefile") to access the image from the SD card. I don't get any sort of error, just a black screen. I will get a null pointer exception if after trying to load the image I try to access a property of the Drawable. This makes me believe that the Drawable wasn't loaded, but I don't know why or how to make it work.
This code as been working on all other Android devices, so I'm not sure what is different with the Incredible.
Unfortunately I don't have access to an Incredible to test on, so I've got to rely on others to test and send me the log files. Any help you can offer would be greatly appreciated. If anyone knows how to replicate this issue on the emulator, that would be helpful too. I've configured an emulator with firmware 7 and the correct screen resolution, but I was unable to replicate the issue.
The Incredible does not come with an SD card. Instead, it has 8GB internal storage you can work with. See here for more information.
Heh, I just noticed Mark already said this.
I've verified that it's not an issue with the SD card (although that is another issue to be addressed). Using an Incredible with an SD card installed produces the result described above as does saving/loading the image from the internal memory ("/emmc").