[Ide] Fix window focusing issue when showing a message dialog

When showing a message dialog, use the current top level window
as TransientFor window. Without this, message dialogs are always
parented to the main window, and that causes focusing problems
when working with other top level windows, such as floating
documents.

Fixes bug #21008 - On Canceling close action for floating window,
floating editor window should not disappear from top