On 01/26/2012 08:21 PM, ext Anselmo L. S. Melo wrote: > Hi, > > A window is a top level window if it has no parent, correct? Code and > comments in qwindow.cpp also confirm that. > > With that in mind, it seems reasonable that > QGuiApplication::topLevelWindows() should return a list of QWindows with > parent()==0. > However, the returned list contains all QWindows created, including the ones > that don't respect this condition. > > So, it seems we need to either adjust QGuiApplication::topLevelWindows() or > control which windows are added to > QGuiApplicationPrivate::window_list - currently, all windows are prepended to > this list in QWindow's ctors.
Agreed, maybe just make QGuiApplication::topLevelWindows() filter the window_list, since it would take more work to keep track of a top_level_window_list in qwindow.cpp. > Also, would it be useful to have QGuiApplication::allWindows()? Yep, it might be. -- Samuel _______________________________________________ Development mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/development
