title: kotlin coroutine - how to ensure some commands run on UI main thread when invoked inside coroutine?
body: <p>i have a very simple coroutine that just does some delay and then what i want it to do is post commands to UI message queue. so run the last two lines on UI thread. here is the coroutine:</p>
  
  <pre><code>async{
      delay(5000)
      doSomething()
      doAnotherThing()
  }
  </code></pre>
  
  <p>I want the last two methods doSomething() and doAnotherThing() to run on the UI thread ? how can this be done ? From what i have read the delay(5000) will automatically run asynchronously but how to make the rest run on UI thread ? To be very clear, i am doing this from an object that was launched from main thread. </p>