summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qdrawhelper.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2019-09-04 19:30:08 +0200
committerMarc Mutz <marc.mutz@kdab.com>2019-09-05 15:40:40 +0000
commit236d4637b2258def1e678e515b42632943eb888d (patch)
tree7f8bb2e868932c3a7bcfa656ef1f7249b1f012b4 /src/gui/painting/qdrawhelper.cpp
parent6f4bc3942dda076eedf38d8c8604eb4fa5d7bd3b (diff)
Optimize QEventDispatcherWinRT::runOnMainThread()
- use std::make_shared instead of QSharedPointer - two memory allocations saved - co-locate semaphore and HRESULT object in a single State object - one more memory allocation saved - pass the shared_ptr<State> by value into the runnable - two more memory allocations saved Not only is the new code much faster, it's also much more readable. Also use QSemaphoreReleaser, just in case the delegate should throw. Change-Id: Ib99b9da86984d440d10b72e3071aa88099e24a1f Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'src/gui/painting/qdrawhelper.cpp')
0 files changed, 0 insertions, 0 deletions