summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vcl/qt5/QtInstance.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/vcl/qt5/QtInstance.cxx b/vcl/qt5/QtInstance.cxx
index fbfc06ac61ee..2243b3dec590 100644
--- a/vcl/qt5/QtInstance.cxx
+++ b/vcl/qt5/QtInstance.cxx
@@ -823,9 +823,14 @@ std::unique_ptr<weld::Builder>
QtInstance::CreateBuilder(weld::Widget* pParent, const OUString& rUIRoot, const OUString& rUIFile)
{
if (!QtData::noWeldedWidgets() && QtInstanceBuilder::IsUIFileSupported(rUIFile))
- return std::make_unique<QtInstanceBuilder>(nullptr, rUIRoot, rUIFile);
+ {
+ QWidget* pQtParent = GetNativeParentFromWeldParent(pParent);
+ return std::make_unique<QtInstanceBuilder>(pQtParent, rUIRoot, rUIFile);
+ }
else
+ {
return SalInstance::CreateBuilder(pParent, rUIRoot, rUIFile);
+ }
}
weld::MessageDialog* QtInstance::CreateMessageDialog(weld::Widget* pParent,