Use lambdas instead if we don't have C++11 support.

This commit is contained in:
Sacha committed 2013-04-14 23:08:51 +10:00
1 parent 0d0ed1256b
commit 3199137b46
1 file changed
+7 -2
+7 -2
View File
@@ -94,7 +94,12 @@ static void threadfunc(PrioritizedWorkQueue *wq) {
}
void ProcessWorkQueueOnThreadWhile(PrioritizedWorkQueue *wq) {
workThread = new std::thread(std::bind(&threadfunc, wq));
workThread = new std::thread(
#if defined(__SYMBIAN32__) || defined(MAEMO) || defined(MEEGO_EDITION_HARMATTAN) || defined(BLACKBERRY)
[wq](){threadfunc(wq);}
#else
std::bind(&threadfunc, wq)
);
}
void StopProcessingWorkQueue(PrioritizedWorkQueue *wq) {
@@ -102,4 +107,4 @@ void StopProcessingWorkQueue(PrioritizedWorkQueue *wq) {
workThread->join();
delete workThread;
workThread = 0;
}
}