Fix ConcurrentModificationException when addTunable
Calls to addTunnable() in systemui are all in mainExecutor, we should also use it in ScreenDecorations to prevent concurrent issue. Bug: 199385132 Test: atest ScreenDecorationsTest Change-Id: Idb8c3800c1bf222f57e212a89c6466367aa5d818
This commit is contained in:
@@ -342,7 +342,7 @@ public class ScreenDecorations extends CoreStartable implements Tunable {
|
||||
mDisplayManager.getDisplay(DEFAULT_DISPLAY).getMetrics(metrics);
|
||||
mDensity = metrics.density;
|
||||
|
||||
mExecutor.execute(() -> mTunerService.addTunable(this, SIZE));
|
||||
mMainExecutor.execute(() -> mTunerService.addTunable(this, SIZE));
|
||||
|
||||
// Watch color inversion and invert the overlay as needed.
|
||||
if (mColorInversionSetting == null) {
|
||||
|
||||
Reference in New Issue
Block a user