something like this should work `focus(mainWindow).then(...`