Commit 433f4cf215da031b83e8a8c89c9ba8315ba4da1f
Merge branch 'master' of http://bj.gitlab.cnlive.com/cnlive-team/newModuleStrike
Showing
1 changed file
with
9 additions
and
2 deletions
core/imageload/src/main/java/com/cnlive/core/ui/view/PreViewImageView.java
| ... | ... | @@ -27,6 +27,7 @@ import com.cnlive.core.imageload.preview.router.PreviewRouters; |
| 27 | 27 | import com.cnlive.core.imageload.preview.widget.CustomTipDialog; |
| 28 | 28 | import com.cnlive.core.imageload.preview.widget.DownloadUtil; |
| 29 | 29 | import com.cnlive.core.imageload.util.DownLoadImageService; |
| 30 | +import com.cnlive.core.imagepreview.listener.OnDragStatusListener; | |
| 30 | 31 | import com.cnlive.core.imagepreview.listener.OnItemLongPressListener; |
| 31 | 32 | import com.cnlive.core.libs.base.frame.view.BaseView; |
| 32 | 33 | import com.cnlive.core.libs.base.interfaces.OnPermissionResponseListener; |
| ... | ... | @@ -84,8 +85,6 @@ public class PreViewImageView extends BaseView { |
| 84 | 85 | if (TextUtils.isEmpty(activity.type)) { |
| 85 | 86 | showError(); |
| 86 | 87 | } |
| 87 | - | |
| 88 | - | |
| 89 | 88 | if (activity.type.equals("1")) { |
| 90 | 89 | preViewImgList = activity.data.getPicInfoList(); |
| 91 | 90 | if (preViewImgList.size() == 1) { |
| ... | ... | @@ -111,6 +110,14 @@ public class PreViewImageView extends BaseView { |
| 111 | 110 | activity.binding.imagePre.overlayStatusBar(false) |
| 112 | 111 | .imageData(activity.picList) |
| 113 | 112 | .playExitAnim(false); |
| 113 | + activity.binding.imagePre.setOnDragStatusListener(new OnDragStatusListener() { | |
| 114 | + @Override | |
| 115 | + public void onDragStatusChanged(int status) { | |
| 116 | + if(status == 8){ | |
| 117 | + activity.finish(); | |
| 118 | + } | |
| 119 | + } | |
| 120 | + }); | |
| 114 | 121 | activity.binding.imagePre.watch(activity.position); |
| 115 | 122 | activity.binding.imagePre.setOnItemLongPressListener(new OnItemLongPressListener() { |
| 116 | 123 | @Override | ... | ... |