Skip to content

Commit

Permalink
Added generic extra data to DraweeView
Browse files Browse the repository at this point in the history
Reviewed By: defHLT

Differential Revision: D50426940

fbshipit-source-id: b1018430fc470df2bc1e1738fb5a6dcb79b3e8b1
  • Loading branch information
oprisnik authored and facebook-github-bot committed Oct 23, 2023
1 parent 409a039 commit aab29ae
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions drawee/src/main/java/com/facebook/drawee/view/DraweeView.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ public class DraweeView<DH extends DraweeHierarchy> extends ImageView {

private static boolean sGlobalLegacyVisibilityHandlingEnabled = false;

private @Nullable Object mExtraData = null;

public static void setGlobalLegacyVisibilityHandlingEnabled(
boolean legacyVisibilityHandlingEnabled) {
sGlobalLegacyVisibilityHandlingEnabled = legacyVisibilityHandlingEnabled;
Expand Down Expand Up @@ -105,6 +107,14 @@ private void init(Context context) {
}
}

public void setExtraData(@Nullable Object extraData) {
mExtraData = extraData;
}

public @Nullable Object getExtraData() {
return mExtraData;
}

/** Sets the hierarchy. */
public void setHierarchy(DH hierarchy) {
mDraweeHolder.setHierarchy(hierarchy);
Expand Down

0 comments on commit aab29ae

Please sign in to comment.