PDA

View Full Version : program exits



ldsjohn
20th September 2006, 19:42
anyone know how to make my program stay open with no mainwindow?

I have a program that when runs the mainwindow constructor doesn't show the mainwindow, it just creates a tray icon and a keyboard hook, and then shows windows as needed

problem is if a dialog is displayed when it closes qt quits altogehter, I can't keep my program alive in the tray

thanks in advance for the help and if you want code just ask and I can post some stuff

jacek
20th September 2006, 19:44
QApplication::setQuitOnLastWindowClosed() (http://doc.trolltech.com/4.1/qapplication.html#quitOnLastWindowClosed-prop)

ldsjohn
20th September 2006, 20:03
now I feel dumb for posting this, thanks a lot that was exactly what I needed