getting a pointer to the open modal dialog

Caolán McNamara caolanm at
Thu Oct 25 03:25:07 PDT 2012

On Thu, 2012-10-25 at 11:15 +0200, Markus Mohrhard wrote:
> Hey,
> is there a way to get the open dialog in the code? I know that there
> is a "way" for modeless dialogs if you know the id of the dialog but
> have still no idea about modal dialogs.

Can you give the use case ? I mean if you already have a window that you
want to get a dialog parent for or dialog child you could just go up and
down the hierarchy. Otherwise stuff like Application::GetActiveTopWindow
or some of the other thingies in Application might be useful. 

Another approach, depending on what you want to do, is to listen for a
window appearing, e.g. RunDialog in vcl/unx/gtk allows the gtkfilepicker
to auto-popdown if its already open and someone uses the systray menu to
launch another toplevel window.


More information about the LibreOffice mailing list