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

Commit f278b180 authored by Vishnu Nair's avatar Vishnu Nair Committed by Android (Google) Code Review
Browse files

Merge "Add null checks for trusted presentation listener apis" into main

parents c3c62274 64c8e0d8
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -520,11 +520,16 @@ public final class WindowManagerImpl implements WindowManager {
    public void registerTrustedPresentationListener(@NonNull IBinder window,
            @NonNull TrustedPresentationThresholds thresholds, @NonNull Executor executor,
            @NonNull Consumer<Boolean> listener) {
        Objects.requireNonNull(window, "window must not be null");
        Objects.requireNonNull(thresholds, "thresholds must not be null");
        Objects.requireNonNull(executor, "executor must not be null");
        Objects.requireNonNull(listener, "listener must not be null");
        mGlobal.registerTrustedPresentationListener(window, thresholds, executor, listener);
    }

    @Override
    public void unregisterTrustedPresentationListener(@NonNull Consumer<Boolean> listener) {
        Objects.requireNonNull(listener, "listener must not be null");
        mGlobal.unregisterTrustedPresentationListener(listener);
    }