Qt: How to give focus to a modeless QDialog created from the main window when the main window is blocked by a modal QDialog
问题 In my Qt Application I'm facing the following scenario: When a specific event is raised I show a modeless QDialog which asks the user for a confirmation. The Dialog is showed using show() function from a QMainWindow . Anytime the event is raised and no other modal QDialog are shown, the user is able to click the confirmation button. Unfortunately if a modal QDialog is visible when the event is raised, the modeless QDialog is unaccessible. This means that the user cannot click the confirmation