mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
Flag unused parameters with Q_UNUSED()
This commit is contained in:
parent
f726443f77
commit
4371c95194
6 changed files with 8 additions and 1 deletions
|
|
@ -26,6 +26,7 @@ MobileShellSettings::MobileShellSettings(QObject *parent)
|
|||
m_configWatcher = KConfigWatcher::create(m_config);
|
||||
|
||||
connect(m_configWatcher.data(), &KConfigWatcher::configChanged, this, [this](const KConfigGroup &group, const QByteArrayList &names) -> void {
|
||||
Q_UNUSED(names)
|
||||
if (group.name() == GENERAL_CONFIG_GROUP) {
|
||||
Q_EMIT vibrationsEnabledChanged();
|
||||
Q_EMIT vibrationDurationChanged();
|
||||
|
|
|
|||
|
|
@ -39,6 +39,7 @@ WallpaperPlugin::WallpaperPlugin(QObject *parent)
|
|||
}
|
||||
|
||||
connect(m_lockscreenConfigWatcher.data(), &KConfigWatcher::configChanged, this, [this](const KConfigGroup &group) {
|
||||
Q_UNUSED(group)
|
||||
loadLockscreenSettings();
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -173,6 +173,7 @@ void DelegateTouchArea::hoverLeaveEvent(QHoverEvent *event)
|
|||
|
||||
void DelegateTouchArea::handlePressEvent(QPointerEvent *event, QPointF point)
|
||||
{
|
||||
Q_UNUSED(event)
|
||||
// ignore multiple press events
|
||||
if (m_pressed) {
|
||||
return;
|
||||
|
|
@ -190,7 +191,7 @@ void DelegateTouchArea::handlePressEvent(QPointerEvent *event, QPointF point)
|
|||
void DelegateTouchArea::handleReleaseEvent(QPointerEvent *event, bool click)
|
||||
{
|
||||
// NOTE: event can be nullptr!
|
||||
|
||||
Q_UNUSED(event)
|
||||
bool wasPressed = m_pressed;
|
||||
setPressed(false);
|
||||
|
||||
|
|
@ -208,6 +209,7 @@ void DelegateTouchArea::handleReleaseEvent(QPointerEvent *event, bool click)
|
|||
|
||||
void DelegateTouchArea::handleMoveEvent(QPointerEvent *event, QPointF point)
|
||||
{
|
||||
Q_UNUSED(event)
|
||||
if (QPointF(point - m_mouseDownPosition).manhattanLength() >= QGuiApplication::styleHints()->startDragDistance()) {
|
||||
m_pressAndHoldTimer->stop();
|
||||
setPressed(false);
|
||||
|
|
|
|||
|
|
@ -89,6 +89,7 @@ void ApplicationListModel::loadApplications()
|
|||
|
||||
QVariant ApplicationListModel::data(const QModelIndex &index, int role) const
|
||||
{
|
||||
Q_UNUSED(role)
|
||||
if (!index.isValid()) {
|
||||
return QVariant();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,6 +23,7 @@ PinnedModel *PinnedModel::self()
|
|||
|
||||
int PinnedModel::rowCount(const QModelIndex &parent) const
|
||||
{
|
||||
Q_UNUSED(parent)
|
||||
return m_applications.count();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -57,6 +57,7 @@ void EffectTouchBorder::setBorders(const QList<int> &touchActivateBorders)
|
|||
effects->registerRealtimeTouchBorder(ElectricBorder(border),
|
||||
m_state->activateAction(),
|
||||
[this](ElectricBorder border, const QPointF &deltaProgress, const Output *screen) {
|
||||
Q_UNUSED(screen)
|
||||
m_state->setInProgress(true);
|
||||
|
||||
if (border == ElectricTop || border == ElectricBottom) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue