~aacid/unity8/fix_testDash

Viewing all changes in revision 1462.

  • Committer: CI bot
  • Author(s): Albert Astals
  • Date: 2014-12-02 09:24:51 UTC
  • mfrom: (1368.17.17 asyncCroppedImageSizer)
  • Revision ID: ps-jenkins@lists.canonical.com-20141202092451-jr8woeiy90bfucxj
Make CroppedImageSizer async

QImageReader can block waiting on disk I/O so let's not have it on the main thread. 

CroppedImageSizerAsyncWorker is using a QFuture via QtConcurrent::run to get a thread and do the work. CroppedImageSizerAsyncWorker is created by CroppedImageSizer but deletes itself, either when the work has been finished or when it's aborted by CroppedImageSizer. This is why it's held with a QPointer in CroppedImageSizer. Fixes: #1384374
Approved by: Michał Sawicz, Michael Zanetti

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: