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

Commit c2ece8d4 authored by Kshitij Gupta's avatar Kshitij Gupta
Browse files

ModesDndTile: Drop usages of runBlocking

- This CL refactors ModesDndTile to drop use of runBlocking.
  Previously, runBlocking was used to call userActionInteractor's
  handleClick() method which could take up time and block the main
  thread.
- We now do this asynchronously via lifecycleScope. While
  lifecycleScope also uses the main thread internally, we do not block
  the main thread anymore. Additionally, the life of this coroutine is
  managed by the lifecycle of the Tile.

Bug: 423462317
Flag: com.android.systemui.do_not_use_run_blocking
Test: atest ModesDndTileTest
Change-Id: I317e6d4c82e0f62296a00b7ca965bf051e248beb
parent 4ae82493
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment