onut/include/Synchronous.h
void processQueue()
        {
            m_mutex.lock();
            while (!m_callbackQueue.empty())
            {
                auto pCallback = m_callbackQueue.front();
                m_callbackQueue.pop();

                // We unlock during the call. Because the call might add new callbacks!
                m_mutex.unlock();
                pCallback->call();
                m_mutex.lock();
                m_allocator.dealloc(pCallback);
            }
            m_mutex.unlock();
        }
/**
        Call all currently queued callbacks set using sync() calls.
        */
Call all currently queued callbacks set using sync() calls.
Call all currently queued callbacks set using sync () calls .
void processQueue()
        {
            m_mutex.lock();
            while (!m_callbackQueue.empty())
            {
                auto pCallback = m_callbackQueue.front();
                m_callbackQueue.pop();
                m_mutex.unlock();
                pCallback->call();
                m_mutex.lock();
                m_allocator.dealloc(pCallback);
            }
            m_mutex.unlock();
        }
void processQueue ( ) { m_mutex . lock ( ) ; while ( ! m_callbackQueue . empty ( ) ) { auto pCallback = m_callbackQueue . front ( ) ; m_callbackQueue . pop ( ) ; m_mutex . unlock ( ) ; pCallback -> call ( ) ; m_mutex . lock ( ) ; m_allocator . dealloc ( pCallback ) ; } m_mutex . unlock ( ) ; }
Call all currently queued callbacks set using sync() calls.
Call all currently queued callbacks set using sync () calls .
// We unlock during the call. Because the call might add new callbacks!