mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-03 22:48:25 +08:00
Support fade for remote images in React with nodes.
Summary: Support fade for DrawImageWithPipeline so that images are faded in when they are remotely fetched. Differential Revision: D2804997
This commit is contained in:
@@ -32,6 +32,7 @@ import android.graphics.Canvas;
|
||||
|
||||
@Override
|
||||
public final void draw(FlatViewGroup parent, Canvas canvas) {
|
||||
onPreDraw(parent, canvas);
|
||||
if (shouldClip()) {
|
||||
canvas.save();
|
||||
canvas.clipRect(mClipLeft, mClipTop, mClipRight, mClipBottom);
|
||||
@@ -42,6 +43,9 @@ import android.graphics.Canvas;
|
||||
}
|
||||
}
|
||||
|
||||
protected void onPreDraw(FlatViewGroup parent, Canvas canvas) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Updates boundaries of the AbstractDrawCommand and freezes it.
|
||||
* Will return a frozen copy if the current AbstractDrawCommand cannot be mutated.
|
||||
|
||||
Reference in New Issue
Block a user