Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Akonadi Data Import Wizard
Commits
1d70f151
Commit
1d70f151
authored
Feb 01, 2021
by
Laurent Montel
😁
Browse files
Adapt for building with qt6
parent
809a8a80
Pipeline
#49299
failed with stage
in 10 minutes and 2 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/balsa/balsaaddressbook.cpp
View file @
1d70f151
...
...
@@ -15,6 +15,9 @@
#include <KConfigGroup>
#include <KLocalizedString>
#include <QUrl>
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <QTextCodec>
#endif
#include "balsaplugin_debug.h"
#include <QFile>
...
...
@@ -73,7 +76,11 @@ void BalsaAddressBook::readAddressBook(const KConfigGroup &grp)
QFile
file
(
path
);
if
(
file
.
open
(
QIODevice
::
ReadOnly
|
QIODevice
::
Text
))
{
QTextStream
stream
(
&
file
);
stream
.
setCodec
(
"ISO 8859-1"
);
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
stream
.
setCodec
(
QTextCodec
::
codecForName
(
"ISO-8859-1"
));
#else
stream
.
setEncoding
(
QStringConverter
::
Encoding
::
Latin1
);
#endif
const
QString
wholeFile
=
stream
.
readAll
();
const
QDateTime
dtDefault
=
QFileInfo
(
file
).
lastModified
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment