Skip to content

Show message dialogs in preferences dialog

The preferences dialog sometimes presents message dialogs to the user. One example is when the user changes some setting which requires a restart in order to take effect.

Some of these message dialogs are constructed and shown inside the "response" signal handler of the preferences dialog. I have not tested on Linux, but at least on Windows, message dialogs constructed within the "response" signal handler are never shown to the user.

That's because the message dialogs are not presented with gtk_dialog_run. Thus, as soon as they are shown, their transient parent is hidden, and at least on Windows all transient children of a window are hidden together with the parent.

Fix that by using gtk_dialog_run to show the message dialogs. This spins a nested main loop which prevents the preferences dialog from being hidden. gtk_dialog_run also marks the message dialog as a modal window (which is better, IMHO)

Edited by Luca Bacci

Merge request reports