summaryrefslogtreecommitdiff
path: root/src/backend/drivers/cswordlexiconmoduleinfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/drivers/cswordlexiconmoduleinfo.cpp')
-rw-r--r--src/backend/drivers/cswordlexiconmoduleinfo.cpp23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/backend/drivers/cswordlexiconmoduleinfo.cpp b/src/backend/drivers/cswordlexiconmoduleinfo.cpp
index 350a49c..d523fa0 100644
--- a/src/backend/drivers/cswordlexiconmoduleinfo.cpp
+++ b/src/backend/drivers/cswordlexiconmoduleinfo.cpp
@@ -2,19 +2,19 @@
*
* This file is part of BibleTime's source code, http://www.bibletime.info/.
*
-* Copyright 1999-2014 by the BibleTime developers.
+* Copyright 1999-2016 by the BibleTime developers.
* The BibleTime source code is licensed under the GNU General Public License version 2.0.
*
**********/
-#include "backend/drivers/cswordlexiconmoduleinfo.h"
+#include "cswordlexiconmoduleinfo.h"
#include <QFile>
#include <QDataStream>
#include <QTextCodec>
#include <QDebug>
-#include "util/directory.h"
+#include "../../util/directory.h"
// Sword includes:
#include <swmodule.h>
@@ -69,25 +69,26 @@ const QStringList &CSwordLexiconModuleInfo::entries() const {
*/
qDebug() << "Read all entries of lexicon" << name();
- module()->setSkipConsecutiveLinks(true);
- module()->setPosition(sword::TOP);
+ auto & m = module();
+ m.setSkipConsecutiveLinks(true);
+ m.setPosition(sword::TOP);
snap(); //snap to top entry
do {
if ( isUnicode() ) {
- m_entries.append(QString::fromUtf8(module()->getKeyText()));
+ m_entries.append(QString::fromUtf8(m.getKeyText()));
}
else {
//for latin1 modules use fromLatin1 because of speed
QTextCodec* codec = QTextCodec::codecForName("Windows-1252");
- m_entries.append(codec->toUnicode(module()->getKeyText()));
+ m_entries.append(codec->toUnicode(m.getKeyText()));
}
- module()->increment();
- } while (!module()->popError());
+ m.increment();
+ } while (!m.popError());
- module()->setPosition(sword::TOP); // back to the first entry
- module()->setSkipConsecutiveLinks(false);
+ m.setPosition(sword::TOP); // back to the first entry
+ m.setSkipConsecutiveLinks(false);
/// \todo Document why the following code is here:
if (!m_entries.empty() && m_entries.front().simplified().isEmpty())