27 lines
870 B
Java
27 lines
870 B
Java
package androidx.core.graphics;
|
|
|
|
import android.graphics.Canvas;
|
|
import android.graphics.Picture;
|
|
import d0.z.d.l;
|
|
import d0.z.d.m;
|
|
import kotlin.Unit;
|
|
import kotlin.jvm.functions.Function1;
|
|
/* compiled from: Picture.kt */
|
|
public final class PictureKt {
|
|
public static final Picture record(Picture picture, int i, int i2, Function1<? super Canvas, Unit> function1) {
|
|
m.checkNotNullParameter(picture, "<this>");
|
|
m.checkNotNullParameter(function1, "block");
|
|
Canvas beginRecording = picture.beginRecording(i, i2);
|
|
m.checkNotNullExpressionValue(beginRecording, "beginRecording(width, height)");
|
|
int i3 = 1;
|
|
try {
|
|
function1.invoke(beginRecording);
|
|
return picture;
|
|
} finally {
|
|
l.finallyStart(i3);
|
|
picture.endRecording();
|
|
l.finallyEnd(i3);
|
|
}
|
|
}
|
|
}
|