-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c20bf50
commit f00ea1a
Showing
10 changed files
with
145 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
OpenImageLib/src/main/java/com/flyjingfish/openimagelib/enums/ImageShapeType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
package com.flyjingfish.openimagelib.enums; | ||
|
||
public enum ImageShapeType { | ||
RECTANGLE, OVAL; | ||
RECTANGLE, OVAL | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,5 @@ | |
public enum MediaType { | ||
IMAGE, | ||
VIDEO, | ||
NONE;//如果数据不是以上两种类型传这个 | ||
NONE//如果数据不是以上两种类型传这个 | ||
} |
23 changes: 23 additions & 0 deletions
23
...src/main/java/com/flyjingfish/openimagelib/listener/LayoutManagerFindVisiblePosition.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.flyjingfish.openimagelib.listener; | ||
|
||
import androidx.recyclerview.widget.RecyclerView; | ||
|
||
/** | ||
* 如果你的{@link androidx.recyclerview.widget.RecyclerView}设置了除以下三个<br/> | ||
* {@link androidx.recyclerview.widget.LinearLayoutManager}、<br/> | ||
* {@link androidx.recyclerview.widget.GridLayoutManager}、<br/> | ||
* {@link androidx.recyclerview.widget.StaggeredGridLayoutManager}<br/> | ||
* 之外的{@link androidx.recyclerview.widget.RecyclerView.LayoutManager},<br/> | ||
* 你需要在{@link com.flyjingfish.openimagelib.OpenImage#setClickRecyclerView(RecyclerView, LayoutManagerFindVisiblePosition, SourceImageViewIdGet)}设置这个接口才可以,否则将会抛出异常 | ||
*/ | ||
public interface LayoutManagerFindVisiblePosition { | ||
/** | ||
* @return 返回 RecyclerView 在屏幕上第一个可见 Item 的位置 | ||
*/ | ||
int findFirstVisibleItemPosition(); | ||
|
||
/** | ||
* @return 返回 RecyclerView 在屏幕上最后一个可见 Item 的位置 | ||
*/ | ||
int findLastVisibleItemPosition(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<ImageView xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
android:layout_width="wrap_content" | ||
android:id="@+id/iv_image" | ||
android:layout_height="120dp" | ||
android:adjustViewBounds="true" | ||
android:layout_margin="2dp" | ||
android:scaleType="centerCrop"> | ||
|
||
</ImageView> |