Merge cherrypicks of [6716922, 6716923, 6716413, 6717023, 6717024, 6716716, 6715859, 6717160, 6717161, 6717162, 6717163, 6716295, 6717141, 6717181, 6717183, 6717184, 6717185, 6714937, 6717028, 6716717, 6716927, 6717200, 6717029, 6717030, 6717031, 6717032, 6717033, 6716928, 6717034, 6717035, 6716929, 6717201, 6716930, 6712377, 6712378, 6716643, 6717164, 6712379] into pi-qpr3-release
Change-Id: I44e0ddc16fe96031eced87cf1e5f9b2019399b6d
This commit is contained in:
@@ -16,6 +16,8 @@
|
||||
|
||||
package com.android.settings;
|
||||
|
||||
import static android.view.WindowManager.LayoutParams.PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
@@ -30,6 +32,8 @@ import android.text.TextUtils;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.view.Window;
|
||||
import android.view.WindowManager;
|
||||
import android.widget.BaseAdapter;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
@@ -59,6 +63,22 @@ public final class SmsDefaultDialog extends AlertActivity implements
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onStart() {
|
||||
super.onStart();
|
||||
getWindow().addPrivateFlags(PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS);
|
||||
android.util.EventLog.writeEvent(0x534e4554, "120484087", -1, "");
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onStop() {
|
||||
super.onStop();
|
||||
final Window window = getWindow();
|
||||
final WindowManager.LayoutParams attrs = window.getAttributes();
|
||||
attrs.privateFlags &= ~PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS;
|
||||
window.setAttributes(attrs);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
switch (which) {
|
||||
@@ -84,7 +104,7 @@ public final class SmsDefaultDialog extends AlertActivity implements
|
||||
}
|
||||
|
||||
private boolean buildDialog(String packageName) {
|
||||
TelephonyManager tm = (TelephonyManager)getSystemService(Context.TELEPHONY_SERVICE);
|
||||
TelephonyManager tm = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
|
||||
if (!tm.isSmsCapable()) {
|
||||
// No phone, no SMS
|
||||
return false;
|
||||
@@ -198,7 +218,7 @@ public final class SmsDefaultDialog extends AlertActivity implements
|
||||
} else {
|
||||
view.findViewById(R.id.default_label).setVisibility(View.GONE);
|
||||
}
|
||||
ImageView imageView = (ImageView)view.findViewById(android.R.id.icon);
|
||||
ImageView imageView = (ImageView) view.findViewById(android.R.id.icon);
|
||||
imageView.setImageDrawable(item.icon);
|
||||
return view;
|
||||
}
|
||||
|
Reference in New Issue
Block a user