From d8547aa7ef0f1557a6c58121953a76ab91d0727e Mon Sep 17 00:00:00 2001 From: Anthony Geay Date: Wed, 5 Apr 2023 08:08:35 +0200 Subject: [PATCH] First Render view only into SALOME --- src/SPV3D/SPV3D_ViewModel.cxx | 4 ++-- src/Session/SALOME_Session_Server.cxx | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/SPV3D/SPV3D_ViewModel.cxx b/src/SPV3D/SPV3D_ViewModel.cxx index dfab79f24..e2ab71e3e 100644 --- a/src/SPV3D/SPV3D_ViewModel.cxx +++ b/src/SPV3D/SPV3D_ViewModel.cxx @@ -110,8 +110,8 @@ SUIT_ViewWindow* SPV3D_ViewModel::createView( SUIT_Desktop* theDesktop ) for(auto i = 0 ; i < argc ; ++i) argv[i] = strdup(args[i].toStdString().c_str()); argv[argc] = nullptr; - pqPVApplicationCore appPV(argc,argv); - QApplication::instance()->installEventFilter(&appPV); + pqPVApplicationCore *appPV = new pqPVApplicationCore(argc,argv); + QApplication::instance()->installEventFilter(appPV); new pqParaViewBehaviors(aViewWindow,aViewWindow); pqObjectBuilder *builder(pqApplicationCore::instance()->getObjectBuilder()); QObject::connect(builder, &pqObjectBuilder::sourceCreated, this, &SPV3D_ViewModel::onSourceCreated); diff --git a/src/Session/SALOME_Session_Server.cxx b/src/Session/SALOME_Session_Server.cxx index 876289b1b..2d02db84b 100644 --- a/src/Session/SALOME_Session_Server.cxx +++ b/src/Session/SALOME_Session_Server.cxx @@ -495,6 +495,7 @@ int AbstractGUIAppMain(int argc, char **argv) // Create Qt application instance: this should be done as early as possible! // Note: QApplication forces setting locale LC_ALL to system one: setlocale(LC_ALL, ""). + SetArgcArgv(argc,argv); Application app(argc, argv); // Initialize Python (only once) -- 2.39.2