QT窗口最小化后,不显示任务栏图标

void pxeclient::changeEvent(QEvent * event )
{
if(event->type()==QEvent::WindowStateChange)
{  
if(windowState() & Qt::WindowMinimized)
{  
hide();  
m_sysTrayIcon->show();//显示托盘
m_sysTrayIcon->showMessage(windowTitle(),"Here is program,click will show!", QSystemTrayIcon::Information, 10000);//提示
}  
QMainWindow::changeEvent(event);  
}
}

你可能感兴趣的:(QT窗口最小化后,不显示任务栏图标)