fix clazy warning: Pass a context object as 3rd connect parameter

GIT_SILENT
This commit is contained in:
Ahmad Samir 2021-08-22 14:51:36 +02:00
parent 1e572a4299
commit 9f41691684
10 changed files with 13 additions and 13 deletions

View file

@ -2201,7 +2201,7 @@ void AbstractClient::checkQuickTilingMaximizationZones(int xroot, int yroot)
m_electricMaximizingDelay = new QTimer(this);
m_electricMaximizingDelay->setInterval(250);
m_electricMaximizingDelay->setSingleShot(true);
connect(m_electricMaximizingDelay, &QTimer::timeout, [this]() {
connect(m_electricMaximizingDelay, &QTimer::timeout, this, [this]() {
if (isInteractiveMove())
setElectricBorderMaximizing(electricBorderMode() != QuickTileMode(QuickTileFlag::None));
});

View file

@ -1111,7 +1111,7 @@ void X11Client::focusOutEvent(xcb_focus_out_event_t *e)
m_focusOutTimer = new QTimer(this);
m_focusOutTimer->setSingleShot(true);
m_focusOutTimer->setInterval(0);
connect(m_focusOutTimer, &QTimer::timeout, [this]() {
connect(m_focusOutTimer, &QTimer::timeout, this, [this]() {
setActive(false);
});
}

View file

@ -87,7 +87,7 @@ PreviewClient::PreviewClient(DecoratedClient *c, Decoration *decoration)
Q_EMIT onAllDesktopsChanged(isOnAllDesktops());
}
);
connect(&m_palette, &KWin::Decoration::DecorationPalette::changed, [this]() {
connect(&m_palette, &KWin::Decoration::DecorationPalette::changed, this, [this]() {
Q_EMIT paletteChanged(m_palette.palette());
});
auto emitEdgesChanged = [this, c]() {

View file

@ -226,7 +226,7 @@ void ApplicationX11::performStartup()
::exit(1);
});
connect(owner.data(), &KSelectionOwner::lostOwnership, this, &ApplicationX11::lostSelection);
connect(owner.data(), &KSelectionOwner::claimedOwnership, [this]{
connect(owner.data(), &KSelectionOwner::claimedOwnership, this, [this]{
installNativeX11EventFilter();
// first load options - done internally by a different thread
createOptions();

View file

@ -302,7 +302,7 @@ WaylandSeat::WaylandSeat(wl_seat *seat, WaylandBackend *backend)
}
}
);
connect(m_seat, &Seat::hasTouchChanged,
connect(m_seat, &Seat::hasTouchChanged, this,
[this] (bool hasTouch) {
if (hasTouch && !m_touch) {
m_touch = m_seat->createTouch(this);

View file

@ -36,7 +36,7 @@ WaylandOutput::WaylandOutput(Surface *surface, WaylandBackend *backend)
setName("WL-" + QString::number(identifier));
setCapabilityInternal(Capability::Dpms);
connect(surface, &Surface::frameRendered, [this] {
connect(surface, &Surface::frameRendered, this, [this] {
m_rendered = true;
Q_EMIT frameRendered();
});

View file

@ -30,7 +30,7 @@ void DBusCall::call()
msg.setArguments(m_arguments);
QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(QDBusConnection::sessionBus().asyncCall(msg), this);
connect(watcher, &QDBusPendingCallWatcher::finished, [this, watcher]() {
connect(watcher, &QDBusPendingCallWatcher::finished, this, [this, watcher]() {
watcher->deleteLater();
if (watcher->isError()) {
Q_EMIT failed();

View file

@ -27,7 +27,7 @@ SwitcherItem::SwitcherItem(QObject *parent)
, m_allDesktops(false)
, m_currentIndex(0)
{
m_selectedIndexConnection = connect(tabBox, &TabBoxHandler::selectedIndexChanged, [this] {
m_selectedIndexConnection = connect(tabBox, &TabBoxHandler::selectedIndexChanged, this, [this] {
if (isVisible()) {
setCurrentIndex(tabBox->currentIndex().row());
}

View file

@ -224,7 +224,7 @@ void UserActionsMenu::init()
connect(m_menu, &QMenu::triggered, this, &UserActionsMenu::slotWindowOperation, Qt::QueuedConnection);
QMenu *advancedMenu = new QMenu(m_menu);
connect(advancedMenu, &QMenu::aboutToShow, [this, advancedMenu]() {
connect(advancedMenu, &QMenu::aboutToShow, this, [this, advancedMenu]() {
if (m_client) {
advancedMenu->setPalette(m_client->palette());
}
@ -830,7 +830,7 @@ ShortcutDialog::ShortcutDialog(const QKeySequence& cut)
// Listen to changed shortcuts
connect(m_ui.keySequenceEdit, &QKeySequenceEdit::editingFinished, this, &ShortcutDialog::keySequenceChanged);
connect(m_ui.clearButton, &QToolButton::clicked, [this]{
connect(m_ui.clearButton, &QToolButton::clicked, this, [this]{
_shortcut = QKeySequence();
});
m_ui.keySequenceEdit->setFocus();

View file

@ -452,7 +452,7 @@ bool WaylandServer::init(InitializationFlags flags)
connect(this, &WaylandServer::shellClientAdded, idleInhibition, &IdleInhibition::registerClient);
new IdleInhibitManagerV1Interface(m_display, m_display);
m_plasmaShell = new PlasmaShellInterface(m_display, m_display);
connect(m_plasmaShell, &PlasmaShellInterface::surfaceCreated,
connect(m_plasmaShell, &PlasmaShellInterface::surfaceCreated, this,
[this] (PlasmaShellSurfaceInterface *surface) {
if (XdgSurfaceClient *client = findXdgSurfaceClient(surface->surface())) {
client->installPlasmaShellSurface(surface);
@ -460,7 +460,7 @@ bool WaylandServer::init(InitializationFlags flags)
}
);
m_appMenuManager = new AppMenuManagerInterface(m_display, m_display);
connect(m_appMenuManager, &AppMenuManagerInterface::appMenuCreated,
connect(m_appMenuManager, &AppMenuManagerInterface::appMenuCreated, this,
[this] (AppMenuInterface *appMenu) {
if (XdgToplevelClient *client = findXdgToplevelClient(appMenu->surface())) {
client->installAppMenu(appMenu);
@ -468,7 +468,7 @@ bool WaylandServer::init(InitializationFlags flags)
}
);
m_paletteManager = new ServerSideDecorationPaletteManagerInterface(m_display, m_display);
connect(m_paletteManager, &ServerSideDecorationPaletteManagerInterface::paletteCreated,
connect(m_paletteManager, &ServerSideDecorationPaletteManagerInterface::paletteCreated, this,
[this] (ServerSideDecorationPaletteInterface *palette) {
if (XdgToplevelClient *client = findXdgToplevelClient(palette->surface())) {
client->installPalette(palette);