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

Commit b271c3b3 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Controls UI - Close power menu on app open" into rvc-dev am: a621dad0

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11792010

Change-Id: Ife601f4c7ed9d05045d02e83bcc17ee45e27120b
parents f74a1de4 a621dad0
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -19,6 +19,7 @@ package com.android.systemui.controls.ui
import android.app.AlertDialog
import android.app.AlertDialog
import android.app.PendingIntent
import android.app.PendingIntent
import android.content.DialogInterface
import android.content.DialogInterface
import android.content.Intent
import android.content.pm.PackageManager
import android.content.pm.PackageManager
import android.service.controls.Control
import android.service.controls.Control
import android.view.View
import android.view.View
@@ -74,6 +75,7 @@ class StatusBehavior : Behavior {
                DialogInterface.OnClickListener { dialog, _ ->
                DialogInterface.OnClickListener { dialog, _ ->
                    try {
                    try {
                        cws.control?.getAppIntent()?.send()
                        cws.control?.getAppIntent()?.send()
                        context.sendBroadcast(Intent(Intent.ACTION_CLOSE_SYSTEM_DIALOGS))
                    } catch (e: PendingIntent.CanceledException) {
                    } catch (e: PendingIntent.CanceledException) {
                        cvh.setTransientStatus(
                        cvh.setTransientStatus(
                            cvh.context.resources.getString(R.string.controls_error_failed))
                            cvh.context.resources.getString(R.string.controls_error_failed))