right order of arguments
  dialog should be ready
  state machine should be ready
 YAY we have dialog

by the combined forces of StateMchine, DialogWindow and Lua!