From: Anthony Geay Date: Wed, 5 Apr 2023 06:08:35 +0000 (+0200) Subject: First Render view only into SALOME X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d8547aa7ef0f1557a6c58121953a76ab91d0727e;p=modules%2Fgui.git First Render view only into SALOME --- 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)