Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.7.0
-
None
-
-
988039729 (dev), 4d5aedac1 (6.7)
Description
The native NSSearchField, which is added using QWidget::createWindowContainer is no longer visible after hide/show of the QDialog.
It used to work with in Qt 5 with QMacCocoaViewContainer(), but the same code no longer works in Qt 5 or Qt 6 using the new QWidget::createWindowContainer.
Specifically, it's added to the QDialog using:
layout()->addWidget(QWidget::createWindowContainer(QWindow::fromWinId(WId(nsSearchField)), this));
See attached test project.
To reproduce:
1. Press the button to open the dialog, search field appears.
2. Close the dialog
3. Press the button again to open the dialog, search field is no longer visible.