summaryrefslogtreecommitdiffstats
path: root/src/dbus/qdbusabstractinterface_p.h
diff options
context:
space:
mode:
authorShawn Rutledge <shawn.rutledge@qt.io>2019-09-05 17:01:23 +0200
committerShawn Rutledge <shawn.rutledge@qt.io>2019-09-10 12:00:31 +0000
commit3a50e51b012eddeee1af6d2d781151b22f47de6f (patch)
tree91d533b5da1ce69b1ed8e18c9a9204857492877c /src/dbus/qdbusabstractinterface_p.h
parent551f73bd8d745881e70a7808385f1a35c2d12b2a (diff)
QMenu::popup(): don't change the menu's screen if called from exec()
Since b3fc5e1ea3eb4fe838ac716aaca4efaa5de5a814, topData()->initialScreenIndex has always been short-lived: it only remembers the screen in case the widget parent is a QDesktopScreenWidget (gotten from QDesktopWidget::screen()), only until the window is created. Then it is reset. In the case of exec() we need to avoid calling setScreen() twice, because that would set the screen once, then forget which screen it was supposed to be on, then set the screen again when exec() calls popup(). This is achieved by using the stored eventLoop pointer to detect that popup() is being called from exec(), and avoid calling setScreen() a second time in popup(), because exec() already needed to call createWinId() before it created the event loop. Amends 82da8306bc1313b85632eee0faf858239261a092 Task-number: QTBUG-76162 Change-Id: I70da517b9d530630e59d103cb2a1ce11c897b2c8 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Joni Poikelin <joni.poikelin@qt.io> (cherry picked from commit 648dac1ceb40a346adf2081997f5c6166c3ad503)
Diffstat (limited to 'src/dbus/qdbusabstractinterface_p.h')
0 files changed, 0 insertions, 0 deletions