Commit f167396a authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use QT_VERSION when code will be not used in qt6

parent 50728580
......@@ -11,7 +11,9 @@
#include <KAboutData>
#include <KCrash>
#include <KDBusService>
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <Kdelibs4ConfigMigrator>
#endif
#include <KLocalizedString>
#include <QApplication>
......@@ -21,18 +23,20 @@
int main( int argc, char* argv[] )
{
// Fixes blurry icons with fractional scaling
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
QGuiApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
#endif
QApplication app( argc, argv );
app.setWindowIcon(QIcon::fromTheme(QStringLiteral( "klickety" )));
KLocalizedString::setApplicationDomain("klickety");
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
// Migrate pre-existing (4.x) configuration
Kdelibs4ConfigMigrator migrate(QStringLiteral("klickety"));
migrate.setConfigFiles(QStringList() << QStringLiteral("klicketyrc"));
migrate.setUiFiles(QStringList() << QStringLiteral("klicketyui.rc"));
migrate.migrate();
#endif
KAboutData aboutData( QStringLiteral( "klickety" ), i18n( "Klickety" ), QStringLiteral( KLICKETY_VERSION_STRING ),
i18n( "Klickety is an adaptation of the \"clickomania\" game" ),
KAboutLicense::GPL,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment