I have an application that when you minimize it it goes to tray.. If you right click on the icon on the tray it show a menu.. See screenshot.

So when i press the About a QMessageBox is been shown.. See screenshot.

The problem is that when i press ok or close the QmessageBox the application closes.. I want to go back to the tray.. How can i do this?
This is what happens when you press About
msgBox.setText("<b>This is my <big>Clock</big> application<b>.");
msgBox.setInformativeText("If you like it, visit my <a href=http://www.qtforum.org>webpage</a>!");
msgBox.setWindowTitle("Clock v0.1 by bong.da.city!");
//set the icon of the message box to a custom pixmap of size 64x64
msgBox.
setIconPixmap(QIcon(":/new/clock/clock.png").
pixmap(QSize(64,
64)));
msgBox.
setWindowIcon(QIcon(":/new/clock/clock.png"));
msgBox.exec();
QMessageBox msgBox;
msgBox.setText("<b>This is my <big>Clock</big> application<b>.");
msgBox.setInformativeText("If you like it, visit my <a href=http://www.qtforum.org>webpage</a>!");
msgBox.setWindowTitle("Clock v0.1 by bong.da.city!");
//set the icon of the message box to a custom pixmap of size 64x64
msgBox.setIconPixmap(QIcon(":/new/clock/clock.png").pixmap(QSize(64,64)));
msgBox.setWindowIcon(QIcon(":/new/clock/clock.png"));
msgBox.exec();
To copy to clipboard, switch view to plain text mode
Bookmarks