[Plasma Theme] Use new connect syntax

Saves some cycles

Differential Revision: https://phabricator.kde.org/D18356
This commit is contained in:
Kai Uwe Broulik 2019-01-18 12:34:06 +01:00
parent eac69e0469
commit 8c50991407

View File

@ -59,8 +59,8 @@ Theme::Theme(QObject *parent)
d->settingsChanged(false);
if (QCoreApplication::instance()) {
connect(QCoreApplication::instance(), SIGNAL(aboutToQuit()),
d, SLOT(onAppExitCleanup()));
connect(QCoreApplication::instance(), &QCoreApplication::aboutToQuit,
d, &ThemePrivate::onAppExitCleanup);
}
connect(d, &ThemePrivate::themeChanged, this, &Theme::themeChanged);
connect(d, &ThemePrivate::defaultFontChanged, this, &Theme::defaultFontChanged);
@ -85,8 +85,8 @@ Theme::Theme(const QString &themeName, QObject *parent)
d->cacheTheme = useCache;
d->fixedName = true;
if (QCoreApplication::instance()) {
connect(QCoreApplication::instance(), SIGNAL(aboutToQuit()),
d, SLOT(onAppExitCleanup()));
connect(QCoreApplication::instance(), &QCoreApplication::aboutToQuit,
d, &ThemePrivate::onAppExitCleanup);
}
connect(d, &ThemePrivate::themeChanged, this, &Theme::themeChanged);
}
@ -131,8 +131,8 @@ void Theme::setThemeName(const QString &themeName)
ThemePrivate::themesRefCount[themeName].ref();
d = ThemePrivate::themes[themeName];
if (QCoreApplication::instance()) {
connect(QCoreApplication::instance(), SIGNAL(aboutToQuit()),
d, SLOT(onAppExitCleanup()));
connect(QCoreApplication::instance(), &QCoreApplication::aboutToQuit,
d, &ThemePrivate::onAppExitCleanup);
}
connect(d, &ThemePrivate::themeChanged, this, &Theme::themeChanged);
}