Merge "Scale back channel toast" into tm-qpr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
99a5adfae1
@@ -6764,9 +6764,8 @@ public class NotificationManagerService extends SystemService {
|
|||||||
|
|
||||||
protected void doChannelWarningToast(int forUid, CharSequence toastText) {
|
protected void doChannelWarningToast(int forUid, CharSequence toastText) {
|
||||||
Binder.withCleanCallingIdentity(() -> {
|
Binder.withCleanCallingIdentity(() -> {
|
||||||
final int defaultWarningEnabled = Build.IS_DEBUGGABLE ? 1 : 0;
|
|
||||||
final boolean warningEnabled = Settings.Global.getInt(getContext().getContentResolver(),
|
final boolean warningEnabled = Settings.Global.getInt(getContext().getContentResolver(),
|
||||||
Settings.Global.SHOW_NOTIFICATION_CHANNEL_WARNINGS, defaultWarningEnabled) != 0;
|
Settings.Global.SHOW_NOTIFICATION_CHANNEL_WARNINGS, 0) != 0;
|
||||||
if (warningEnabled) {
|
if (warningEnabled) {
|
||||||
Toast toast = Toast.makeText(getContext(), mHandler.getLooper(), toastText,
|
Toast toast = Toast.makeText(getContext(), mHandler.getLooper(), toastText,
|
||||||
Toast.LENGTH_SHORT);
|
Toast.LENGTH_SHORT);
|
||||||
|
|||||||
Reference in New Issue
Block a user