Hello,

i'm reading the tutorial about QConcurrent in the doc, i am not sure to understand something: the QLabel is added to the layout, and then we launch the concurrent function to scale the images :

http://doc.qt.nokia.com/4.7/qtconcur...aling-cpp.html

Qt Code:
  1. int dim = sqrt(qreal(files.count())) + 1;
  2. for (int i = 0; i < dim; ++i) {
  3. for (int j = 0; j < dim; ++j) {
  4. QLabel *imageLabel = new QLabel;
  5. imageLabel->setFixedSize(imageSize,imageSize);
  6. imagesLayout->addWidget(imageLabel,i,j);
  7. labels.append(imageLabel);
  8. }
  9. }
  10.  
  11. // Use mapped to run the thread safe scale function on the files.
  12. imageScaling->setFuture(QtConcurrent::mapped(files, scale));
To copy to clipboard, switch view to plain text mode 

unless i'm missing something in the code, it seems that the asynchronous function scale the images only after they are onscreen. So i am not sure to understand where i'm wrong.

Thanks for your help