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

Commit 6d3f735e authored by Diksha Gohlyan's avatar Diksha Gohlyan Committed by Automerger Merge Worker
Browse files

Add more log statements for cancelnotification am: cd73fc80 am: 114cd654

Change-Id: I9f69ea928b10ac349a1f68f4b57788086e1b1668
parents d5639c16 114cd654
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -80,8 +80,10 @@ public class TestNotificationService extends NotificationListenerService {
        public void onReceive(Context context, Intent intent) {
        public void onReceive(Context context, Intent intent) {
            String action = intent.getAction();
            String action = intent.getAction();
            if (ACTION_CHANGE_CANCEL_MODE.equals(action)) {
            if (ACTION_CHANGE_CANCEL_MODE.equals(action)) {
                Log.i(TAG, "Received cancel mode");
                mCurrentMode = MODE.CANCEL_MODE;
                mCurrentMode = MODE.CANCEL_MODE;
            } else if (ACTION_CHANGE_EXECUTION_MODE.equals(action)) {
            } else if (ACTION_CHANGE_EXECUTION_MODE.equals(action)) {
                Log.i(TAG, "Received execution mode");
                mCurrentMode = MODE.EXECUTION_MODE;
                mCurrentMode = MODE.EXECUTION_MODE;
            }
            }
        }
        }
@@ -113,6 +115,9 @@ public class TestNotificationService extends NotificationListenerService {
    @Override
    @Override
    public void onNotificationPosted(StatusBarNotification sbn) {
    public void onNotificationPosted(StatusBarNotification sbn) {
        String pkgName = sbn.getPackageName();
        String pkgName = sbn.getPackageName();
        Log.i(TAG, "Entering notification posted cancelMode = " + MODE.CANCEL_MODE
                .equals(mCurrentMode) + " targetPackageName " + mTargetPackageName + " packageName "
                + pkgName);
        if (mTargetPackageName.equals(pkgName)) {
        if (mTargetPackageName.equals(pkgName)) {
            if (MODE.CANCEL_MODE.equals(mCurrentMode)) {
            if (MODE.CANCEL_MODE.equals(mCurrentMode)) {
                try {
                try {
@@ -126,6 +131,8 @@ public class TestNotificationService extends NotificationListenerService {


    @Override
    @Override
    public void onNotificationRemoved(StatusBarNotification sbn) {
    public void onNotificationRemoved(StatusBarNotification sbn) {
        Log.i(TAG, "Entering notification removed cancelMode = " + MODE.CANCEL_MODE
                .equals(mCurrentMode));
        String pkgName = sbn.getPackageName();
        String pkgName = sbn.getPackageName();
        if (!mTargetPackageName.equals(pkgName)) {
        if (!mTargetPackageName.equals(pkgName)) {
            return;
            return;