PdfWorker: generatePreviews: take const ref to container with search results
This commit is contained in:
parent
fe57a8d41c
commit
75d7aed22d
@ -74,11 +74,11 @@ struct Renderer
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
QFuture<PdfPreview> PdfWorker::generatePreviews(QVector<SearchResult> paths, double scalefactor)
|
QFuture<PdfPreview> PdfWorker::generatePreviews(const QVector<SearchResult> paths, double scalefactor)
|
||||||
{
|
{
|
||||||
QVector<PdfPreview> previews;
|
QVector<PdfPreview> previews;
|
||||||
|
|
||||||
for(SearchResult &sr : paths)
|
for(const SearchResult &sr : paths)
|
||||||
{
|
{
|
||||||
for(int page : sr.pages)
|
for(int page : sr.pages)
|
||||||
{
|
{
|
||||||
|
@ -17,7 +17,7 @@ class PdfWorker : public QObject
|
|||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
QFuture<PdfPreview> generatePreviews(QVector<SearchResult> paths, double scalefactor);
|
QFuture<PdfPreview> generatePreviews(const QVector<SearchResult> paths, double scalefactor);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // PDFWORKER_H
|
#endif // PDFWORKER_H
|
||||||
|
Loading…
Reference in New Issue
Block a user