diff --git a/core/api/current.txt b/core/api/current.txt index b75c6d5f2d979..5f31e0be99654 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -14982,7 +14982,7 @@ package android.graphics { method public void drawTextRun(@NonNull android.graphics.text.MeasuredText, int, int, int, int, float, float, boolean, @NonNull android.graphics.Paint); method public void drawVertices(@NonNull android.graphics.Canvas.VertexMode, int, @NonNull float[], int, @Nullable float[], int, @Nullable int[], int, @Nullable short[], int, int, @NonNull android.graphics.Paint); method public void enableZ(); - method public boolean getClipBounds(@Nullable android.graphics.Rect); + method public boolean getClipBounds(@NonNull android.graphics.Rect); method @NonNull public final android.graphics.Rect getClipBounds(); method public int getDensity(); method @Nullable public android.graphics.DrawFilter getDrawFilter(); diff --git a/graphics/java/android/graphics/Canvas.java b/graphics/java/android/graphics/Canvas.java index 81aeec07db9ed..abf7e99110864 100644 --- a/graphics/java/android/graphics/Canvas.java +++ b/graphics/java/android/graphics/Canvas.java @@ -1272,11 +1272,10 @@ public class Canvas extends BaseCanvas { * in a way similar to quickReject, in that it tells you that drawing * outside of these bounds will be clipped out. * - * @param bounds Return the clip bounds here. If it is null, ignore it but - * still return true if the current clip is non-empty. + * @param bounds Return the clip bounds here. * @return true if the current clip is non-empty. */ - public boolean getClipBounds(@Nullable Rect bounds) { + public boolean getClipBounds(@NonNull Rect bounds) { return nGetClipBounds(mNativeCanvasWrapper, bounds); }