How to get a pointer for mainwindow?

Andreas Pakulat apaku at gmx.de
Tue Mar 27 10:59:10 UTC 2007


On 27.03.07 12:30:33, Andras Mantia wrote:
> The second issue was to display dialog boxes that have mainwindow as the 
> parent. For example when such an action executes a command line 
> application

That action should use the outputview for such things, this way there's
no need for a messsagebox.

> and the execution fails and a message box needs to be 
> displayed there is no widget that we can use to have the parent, but 
> the mainwindow. This is important for multiple screens and for focus 
> steeling prevention, as if we pass 0L as parent, the dialog might 
> appear in wrong place, while if mainwindow is the parent, it is sure 
> that it will appear on top of KDevelop and on the same screen where the 
> KDevelop window is.

This is still valid though, there are quite some cases where we'll
display a message box or some other dialog from a plugin, so getting a
proper parent for those is a good reason to add that method.

Andreas

-- 
Exercise caution in your daily affairs.




More information about the KDevelop-devel mailing list