소스 검색

Don't unload plugin when uninstantiating a module

there might be some objects in the application that need the methods of the
library (e.g. destructor of objects).
Julien Finet 13 년 전
부모
커밋
e9565ee202
1개의 변경된 파일2개의 추가작업 그리고 6개의 파일을 삭제
  1. 2 6
      Libs/Core/ctkAbstractPluginFactory.tpp

+ 2 - 6
Libs/Core/ctkAbstractPluginFactory.tpp

@@ -64,12 +64,8 @@ void ctkFactoryPluginItem<BaseClassType>::uninstantiate()
     {
     return;
     }
-  // QPluginLoader::unload doc says: "don't try to delete the root component".
-  bool deleted = this->Loader.unload();
-  if (deleted)
-    {
-    this->Instance = 0;
-    }
+  this->Instance->deleteLater();
+  this->Instance = 0;
 }
 
 //----------------------------------------------------------------------------