Add destructor for pdfworker renderer
这个提交包含在:
父节点
d435ec3bfd
当前提交
fe57a8d41c
@ -21,7 +21,15 @@ struct Renderer
|
||||
{
|
||||
this->scaleX = scaleX;
|
||||
this->scaleY = scaleY;
|
||||
|
||||
}
|
||||
|
||||
~Renderer()
|
||||
{
|
||||
qDeleteAll(documentcache);
|
||||
}
|
||||
|
||||
|
||||
Poppler::Document *document(QString path)
|
||||
{
|
||||
if(documentcache.contains(path))
|
||||
@ -30,6 +38,7 @@ struct Renderer
|
||||
Poppler::Document *result = Poppler::Document::load(path);
|
||||
if(result == nullptr)
|
||||
{
|
||||
//TODO: some kind of user feedback would be nicec
|
||||
return nullptr;
|
||||
}
|
||||
result->setRenderHint(Poppler::Document::TextAntialiasing);
|
||||
|
正在加载...
在新工单中引用
屏蔽一个用户