fixed dialog init issue