Skip to content

Commit

Permalink
// matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
razerdp committed Dec 20, 2016
1 parent d6054d1 commit 70119ad
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions lib/src/main/java/razerdp/github/com/widget/PhotoContents.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package razerdp.github.com.widget;

import android.content.Context;
import android.graphics.Matrix;
import android.graphics.Rect;
import android.support.annotation.NonNull;
import android.util.AttributeSet;
Expand Down Expand Up @@ -490,6 +491,20 @@ public List<Rect> getContentViewsGlobalVisibleRects() {
return viewRects;
}

public List<Matrix> getContentViewsDrawableMatrixList(){
final int childCount = getChildCount();
if (childCount <= 0) return null;
List<Matrix> viewMatrixs = new LinkedList<>();
for (int i = 0; i < childCount; i++) {
View v = getChildAt(i);
if (v instanceof ImageView&&((ImageView) v).getDrawable()!=null) {
Matrix matrix=((ImageView) v).getImageMatrix();
viewMatrixs.add(matrix);
}
}
return viewMatrixs;
}

//------------------------------------------Interface-----------------------------------------------
private OnSetUpChildLayoutParamsListener onSetUpChildLayoutParamsListener;

Expand Down

0 comments on commit 70119ad

Please sign in to comment.