Initialize enabledDisplays with the correct displays
It could have happened that the list of displays was not up to date when DisplayRepository was being initialized. This makes a binder call to get them from the ui thread once DisplayRepository class is instantiated to ensure correctness immediately (and not eventual, as before) It would be possible to also have correctness immediately avoiding the binder call using SharedFlows, but we banned them due to performance concerns. The ui thread binder call here happens once per process start, so it shouldn't be that problematic. Fixes: 355364683 Test: DisplayRepositoryTest Flag: com.android.systemui.enable_efficient_display_repository Change-Id: If379d754fa378eaaeddb29fc5f94f5536f0b5c01
Loading
Please register or sign in to comment