Merge "Add Nullable annotation to getDecorView"

am: a018254b45

Change-Id: I50847403490455560f6c7db41db494bab3bc44f8
This commit is contained in:
Siarhei Vishniakou
2019-03-13 09:29:55 -07:00
committed by android-build-merger

View File

@@ -19,6 +19,7 @@ package android.preference;
import android.annotation.CallSuper; import android.annotation.CallSuper;
import android.annotation.DrawableRes; import android.annotation.DrawableRes;
import android.annotation.Nullable;
import android.annotation.StringRes; import android.annotation.StringRes;
import android.annotation.UnsupportedAppUsage; import android.annotation.UnsupportedAppUsage;
import android.app.AlertDialog; import android.app.AlertDialog;
@@ -347,6 +348,7 @@ public abstract class DialogPreference extends Preference implements
* @return the DecorView for the current dialog window, if it exists. * @return the DecorView for the current dialog window, if it exists.
* If the window does not exist, null is returned. * If the window does not exist, null is returned.
*/ */
@Nullable
private View getDecorView() { private View getDecorView() {
if (mDialog != null && mDialog.getWindow() != null) { if (mDialog != null && mDialog.getWindow() != null) {
return mDialog.getWindow().getDecorView(); return mDialog.getWindow().getDecorView();