From b10e33ff804a831c71be9303146cea892b9aeb5d Mon Sep 17 00:00:00 2001 From: Jorim Jaggi Date: Wed, 4 Feb 2015 21:57:40 +0100 Subject: Split up android.policy into framework.jar and services.jar 1/3 Change-Id: Ifd69f1f3dd308a7e17a1442e2f3950da8b03cec4 --- core/java/android/app/Dialog.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'core/java/android/app/Dialog.java') diff --git a/core/java/android/app/Dialog.java b/core/java/android/app/Dialog.java index 067073a1f71c..70e6e5a21086 100644 --- a/core/java/android/app/Dialog.java +++ b/core/java/android/app/Dialog.java @@ -16,14 +16,13 @@ package android.app; -import android.content.pm.ApplicationInfo; import com.android.internal.app.WindowDecorActionBar; -import com.android.internal.policy.PolicyManager; import android.content.ComponentName; import android.content.Context; import android.content.ContextWrapper; import android.content.DialogInterface; +import android.content.pm.ApplicationInfo; import android.graphics.drawable.Drawable; import android.net.Uri; import android.os.Bundle; @@ -42,6 +41,7 @@ import android.view.LayoutInflater; import android.view.Menu; import android.view.MenuItem; import android.view.MotionEvent; +import android.view.PhoneWindow; import android.view.View; import android.view.View.OnCreateContextMenuListener; import android.view.ViewGroup; @@ -134,14 +134,14 @@ public class Dialog implements DialogInterface, Window.Callback, /** * Create a Dialog window that uses a custom dialog style. - * + * * @param context The Context in which the Dialog should run. In particular, it * uses the window manager and theme from this context to * present its UI. - * @param theme A style resource describing the theme to use for the - * window. See Style - * and Theme Resources for more information about defining and using - * styles. This theme is applied on top of the current theme in + * @param theme A style resource describing the theme to use for the + * window. See Style + * and Theme Resources for more information about defining and using + * styles. This theme is applied on top of the current theme in * context. If 0, the default dialog theme will be used. */ public Dialog(Context context, int theme) { @@ -162,7 +162,7 @@ public class Dialog implements DialogInterface, Window.Callback, } mWindowManager = (WindowManager)context.getSystemService(Context.WINDOW_SERVICE); - Window w = PolicyManager.makeNewWindow(mContext); + Window w = new PhoneWindow(mContext); mWindow = w; w.setCallback(this); w.setOnWindowDismissedCallback(this); -- cgit v1.2.3