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

Commit 0fa6d989 authored by Riley Jones's avatar Riley Jones Committed by Android (Google) Code Review
Browse files

Merge "Register xml parsing receiver on background thread" into main

parents cc9efa07 cb211281
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -127,6 +127,16 @@ flag {
    }
}

flag {
    name: "manager_avoid_receiver_timeout"
    namespace: "accessibility"
    description: "Register receivers on background handler so they have more time to complete"
    bug: "333890389"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "pinch_zoom_zero_min_span"
    namespace: "accessibility"
+3 −1
Original line number Diff line number Diff line
@@ -986,6 +986,8 @@ public class AccessibilityManagerService extends IAccessibilityManager.Stub
        intentFilter.addAction(Intent.ACTION_USER_REMOVED);
        intentFilter.addAction(Intent.ACTION_SETTING_RESTORED);

        Handler receiverHandler =
                Flags.managerAvoidReceiverTimeout() ? BackgroundThread.getHandler() : null;
        mContext.registerReceiverAsUser(new BroadcastReceiver() {
            @Override
            public void onReceive(Context context, Intent intent) {
@@ -1033,7 +1035,7 @@ public class AccessibilityManagerService extends IAccessibilityManager.Stub
                    }
                }
            }
        }, UserHandle.ALL, intentFilter, null, null);
        }, UserHandle.ALL, intentFilter, null, receiverHandler);

        final IntentFilter filter = new IntentFilter();
        filter.addAction(SafetyCenterManager.ACTION_SAFETY_CENTER_ENABLED_CHANGED);