From b6cedbe4afdd7623884a3e90057739a5047bf8c2 Mon Sep 17 00:00:00 2001 From: sledgehammer999 Date: Wed, 26 Dec 2012 20:00:31 +0200 Subject: [PATCH] Optimize the preview of huge torrents. Fixes issue #288. --- src/previewselect.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/previewselect.cpp b/src/previewselect.cpp index 1867430dc..5ba887298 100644 --- a/src/previewselect.cpp +++ b/src/previewselect.cpp @@ -99,9 +99,10 @@ void PreviewSelect::on_previewButton_clicked() { // Flush data h.flush_cache(); + QStringList absolute_paths(h.absolute_files_path()); QString path; foreach (index, selectedIndexes) { - path = h.absolute_files_path().at(indexes.at(index.row())); + path = absolute_paths.at(indexes.at(index.row())); // File if (QFile::exists(path)) { emit readyToPreviewFile(path);