I see no issues here with the focus, the focus is set on the Edit, when clicking on the button, the focus is set on the button. Then the dialog is shown which gains focus, afterwards, the button has focus again. I am testing this here on XE2. Which environment are you testing the components on?
Kind Regards,
Scheldeman Pieter