Back to project page PhotoPicker.
The source code is released under:
GNU General Public License
If you think the Android project PhotoPicker listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.thuytrinh.photopicker.controller.loader; //from www . j a v a 2 s . c o m import android.content.Context; import android.content.CursorLoader; import android.provider.MediaStore; import javax.inject.Inject; public class PhotosLoader extends CursorLoader { @Inject public PhotosLoader(Context context) { super(context); setUri(MediaStore.Images.Media.EXTERNAL_CONTENT_URI); setProjection(new String[] { MediaStore.Images.Media._ID, MediaStore.Images.Media.BUCKET_ID, MediaStore.Images.Media.BUCKET_DISPLAY_NAME, MediaStore.Images.Media.DATA }); } public void setAlbumId(long albumId) { String albumIdArg = Long.toString(albumId); setSelection(MediaStore.Images.Media.BUCKET_ID + " = ?"); setSelectionArgs(new String[] {albumIdArg}); } }