Add explicit, use nullptr etc.

wilder-5.14
Laurent Montel 8 years ago
parent 631502eda0
commit 37e57bc1ac
  1. 2
      applets/notifications/plugin/draghelper.h
  2. 2
      applets/notifications/plugin/notificationshelper.h
  3. 4
      applets/notifications/plugin/thumbnailer.cpp
  4. 2
      applets/systemtray/container/systemtraycontainer.cpp
  5. 2
      applets/systemtray/systemtray.cpp

@ -33,7 +33,7 @@ Q_OBJECT
Q_PROPERTY(bool dragActive READ dragActive NOTIFY dragActiveChanged)
public:
DragHelper(QObject *parent = nullptr);
explicit DragHelper(QObject *parent = nullptr);
~DragHelper();
bool dragActive() const;

@ -48,7 +48,7 @@ public:
};
Q_ENUM(PositionOnScreen)
NotificationsHelper(QObject *parent = nullptr);
explicit NotificationsHelper(QObject *parent = nullptr);
~NotificationsHelper() override;
Q_INVOKABLE void addNotificationPopup(QObject *win);
Q_INVOKABLE void closePopup(const QString &sourceName);

@ -133,7 +133,7 @@ void Thumbnailer::showContextMenu(int x, int y, const QString &path, QQuickItem
});
if (KProtocolManager::supportsListing(url)) {
QAction *openContainingFolderAction = menu->addAction(QIcon::fromTheme("folder-open"), i18n("Open Containing Folder"));
QAction *openContainingFolderAction = menu->addAction(QIcon::fromTheme(QStringLiteral("folder-open")), i18n("Open Containing Folder"));
connect(openContainingFolderAction, &QAction::triggered, [url] {
KIO::highlightInFileManager({url});
});
@ -158,7 +158,7 @@ void Thumbnailer::showContextMenu(int x, int y, const QString &path, QQuickItem
actions->addServiceActionsTo(menu);
actions->addPluginActionsTo(menu);
QAction *propertiesAction = menu->addAction(QIcon::fromTheme("document-properties"), i18n("Properties"));
QAction *propertiesAction = menu->addAction(QIcon::fromTheme(QStringLiteral("document-properties")), i18n("Properties"));
connect(propertiesAction, &QAction::triggered, [fileItem] {
KPropertiesDialog *dialog = new KPropertiesDialog(fileItem.url());
dialog->setAttribute(Qt::WA_DeleteOnClose);

@ -79,7 +79,7 @@ void SystemTrayContainer::ensureSystrayExists()
}
if (!m_innerContainment) {
m_innerContainment = c->createContainment("org.kde.plasma.private.systemtray", QVariantList() << "org.kde.plasma:force-create");
m_innerContainment = c->createContainment(QStringLiteral("org.kde.plasma.private.systemtray"), QVariantList() << "org.kde.plasma:force-create");
config().writeEntry("SystrayContainmentId", m_innerContainment->id());
}

@ -346,7 +346,7 @@ bool SystemTray::isSystemTrayApplet(const QString &appletId)
void SystemTray::restoreContents(KConfigGroup &group)
{
Q_UNUSED(group);
//NOTE: RestoreContents shouldnn't do anything here because is too soon, so have an empty reimplementation
//NOTE: RestoreContents shouldn't do anything here because is too soon, so have an empty reimplementation
}
void SystemTray::restorePlasmoids()

Loading…
Cancel
Save