summaryrefslogtreecommitdiff
path: root/src/linguist/shared/simtexth.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2011-06-01 19:43:49 +0200
committerQt by Nokia <qt-info@nokia.com>2011-09-12 17:29:43 +0200
commit5cfff4988276aa2981c8fc833a760206e3aa3370 (patch)
tree130f1979b349c368eed6fe5000f27b2aa8cb4bd2 /src/linguist/shared/simtexth.cpp
parent6743a676111737dfa04528e869d1a86a7c49543c (diff)
downloadqttools-5cfff4988276aa2981c8fc833a760206e3aa3370.tar.gz
remove Translator::translatedMessages()
it's inefficient to construct a new list. on top of that, the only user actually checks the message state again. (cherry picked from commit 8a5d0e6c3d1cf6b269f755a8d54b25b704ba8356) Change-Id: I54159bc041fa5188affb1d54862f742c1e445628 Reviewed-on: http://codereview.qt-project.org/4610 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'src/linguist/shared/simtexth.cpp')
-rw-r--r--src/linguist/shared/simtexth.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/linguist/shared/simtexth.cpp b/src/linguist/shared/simtexth.cpp
index 31253d657..89335071f 100644
--- a/src/linguist/shared/simtexth.cpp
+++ b/src/linguist/shared/simtexth.cpp
@@ -238,9 +238,7 @@ CandidateList similarTextHeuristicCandidates(const Translator *tor,
QList<int> scores;
CandidateList candidates;
- TML all = tor->translatedMessages();
-
- foreach (const TranslatorMessage &mtm, all) {
+ foreach (const TranslatorMessage &mtm, tor->messages()) {
if (mtm.type() == TranslatorMessage::Unfinished
|| mtm.translation().isEmpty())
continue;