package Ġcom . smp . coroutine playground . support Ċ Ċ import Ġandroidx . lifecycle . Mutable LiveData Ċ import Ġio . reactivex . Observable Ċ Ċ fun Ġ< T > ĠObservable < T >. sync Progress ( ĊĠĠĠ Ġprogress State : ĠMutable LiveData < Progress >, ĊĠĠĠ Ġstart sWith : ĠProgress Ġ= ĠProgress . INITIAL Ċ ): ĠObservable < T > Ġ{ ĊĠĠĠ Ġreturn Ġdo On Subscribe Ġ{ Ġprogress State . post Value ( startsWith ) Ġ} ĊĠĠĠĠĠĠĠ Ġ. do Finally Ġ{ Ġprogress State . post Value ( Progress . IDLE ) Ġ} Ċ }