diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2016-01-28 16:48:36 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2016-02-02 10:20:00 +0000 |
commit | fdfd63053ae6b10af06553be3c1b15de274bebf7 (patch) | |
tree | e8fe0248ff2b926b0b351a012342fe4168911c2d /src/gui/text/qtextdocumentlayout.cpp | |
parent | 1d3503b8f3b49b0f684e1caa504deb0d05f2c60a (diff) |
QtBase: avoid uses of Java-style iterators [QHash, QMap]
Java-style iterators are slower than STL-style ones, so
they should not be used in library code.
Replaced them with C++11 range-for, STL iterators or, in
one case, qDeleteAll().
In one case, avoid a double hash lookup by using erase(it)
instead of remove(it.key()), which we can now do without
detaching, due to the new erase() taking const_iterator.
Change-Id: I96174657fed70f76120b2c9d8190b4e70d5d8179
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Diffstat (limited to 'src/gui/text/qtextdocumentlayout.cpp')
0 files changed, 0 insertions, 0 deletions