A Library help u to pick photos.
Click to download lastest demo ⬇️ or select Release Version
the last-version is this ⬆️
compile 'com.werb.pickphotoview:pickphotoview:last-version'
some Library already dependency
- Glide
- Recyclerview
- Rxandroid
- Gson
If you don't want to dependency this Library version , you can replace it just like
compile ('com.werb.pickphotoview:pickphotoview:last-version',{
exclude group: 'com.google.code.gson'
})
compile 'com.google.code.gson:gson:XXXX'
<dependency>
<groupId>com.werb.pickphotoview</groupId>
<artifactId>pickphotoview</artifactId>
<version>last-version</version>
<type>pom</type>
</dependency>
Sorry ,You are out !
Make sure you have permissions about CAMERA and WRITE/READ_EXTERNAL_STORAGE before use
PermissionsChecker : A Library help u to check permissions on Android M.
new PickPhotoView.Builder(context)
.setPickPhotoSize(9) //select max size
.setShowCamera(true) //is show camera
.setSpanCount(4) //SpanCount
.start();
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if(resultCode == 0){
return;
}
if(data == null){
return;
}
if (requestCode == PickConfig.PICK_PHOTO_DATA) {
List<String> selectPaths = (List<String>) data.getSerializableExtra(PickConfig.INTENT_IMG_LIST_SELECT);
// do something u want
}
}
- change activity launchmode
- change cursor photo by DATE_MODIFIED desc