PickPhotoSample
½éÉÜ£º
Ïñ΢ÐÅÒ»ÑùµÄͼƬѡÔñÆ÷¡£
ÔËÐÐЧ¹û£º
ʹÓÃ˵Ã÷£º
Gradle
compile 'com.werb.pickphotoview:pickphotoview:last-version'
Maven
<dependency>
<groupId>com.werb.pickphotoview</groupId>
<artifactId>pickphotoview</artifactId>
<version>0.0.4-beta8</version>
<type>pom</type>
</dependency>
È·±£¾ßÓÐCAMERA ºÍ WRITE£¯READ_EXTERNAL_STORAGE È«ÏØ
PermissionsChecker : A Library help u to check permissions on Android M.
³õʼ»¯ PickPhotoView
new PickPhotoView.Builder(context)
.setPickPhotoSize(9) //select max size
.setShowCamera(true) //is show camera
.setSpanCount(4) //SpanCount
.start();
onActivityResult
@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
}
}
已下载
0