Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3efd1660 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add @NonNull annotation to getDecorView()"

parents a37fd550 c771e7e8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1657,7 +1657,7 @@ public abstract class Window {
     *
     * @return Returns the top-level window decor view.
     */
    public abstract View getDecorView();
    public abstract @NonNull View getDecorView();

    /**
     * Retrieve the current decor view, but only if it has already been created;
+2 −1
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ import static android.view.ViewGroup.LayoutParams.MATCH_PARENT;
import static android.view.ViewGroup.LayoutParams.WRAP_CONTENT;
import static android.view.WindowManager.LayoutParams.*;

import android.annotation.NonNull;
import android.app.ActivityManager;
import android.app.SearchManager;
import android.os.UserHandle;
@@ -2066,7 +2067,7 @@ public class PhoneWindow extends Window implements MenuBuilder.Callback {
    }

    @Override
    public final View getDecorView() {
    public final @NonNull View getDecorView() {
        if (mDecor == null || mForceDecorInstall) {
            installDecor();
        }