Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.9.1, 5.9.2
-
None
-
Windows 10 Pro Build 10586
Qt 5.9.1 x64
Description
I have a Menu with a submenu on a QSystemTrayIcon. When I open the menu including submenu, every is shown correcty (see screenshot 'first show'). you see the menu including submenu.
When I open the menu again, the menu is shown correctly, but the submenu is behind the taskbar of windows (see screenshot 'second show').
Example code:
#include "stdafx.h"int main( int argc, char* argv[] )
{{{}}
QApplication app( argc, argv );
QMenu* MainMenu = new QMenu();
{{ QMenu* SubMenu = new QMenu();}}
{{ SubMenu->setTitle( "Submenu" );}}
SubMenu->addAction( "Action 1" );
SubMenu->addAction( "Action 2" );
SubMenu->addAction( "Action 3" );
MainMenu->addMenu( SubMenu );
{{ QSystemTrayIcon OurIcon;}}
QIcon Ic( ":/Resources/TrayIcon.png" );
OurIcon.setIcon( Ic );
OurIcon.setContextMenu( MainMenu );
OurIcon.setVisible( true );return app.exec();
{{ }}}
also see QTBUG-64921