From 817656cb0bf9384f713638dead25987f28d4c256 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Mon, 18 Apr 2022 11:25:47 +0300 Subject: [PATCH] Remove AbstractClient plumbing casts in AbstractClient --- src/abstract_client.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/abstract_client.cpp b/src/abstract_client.cpp index 441822d408..919449d4c8 100644 --- a/src/abstract_client.cpp +++ b/src/abstract_client.cpp @@ -2472,8 +2472,8 @@ bool AbstractClient::performMouseCommand(Options::MouseCommand cmd, const QPoint auto it = workspace()->stackingOrder().constEnd(), begin = workspace()->stackingOrder().constBegin(); while (mustReplay && --it != begin && *it != this) { - auto c = static_cast((*it)->isClient() ? *it : nullptr); - if (!c || (c->keepAbove() && !keepAbove()) || (keepBelow() && !c->keepBelow())) { + auto c = *it; + if (!c->isClient() || (c->keepAbove() && !keepAbove()) || (keepBelow() && !c->keepBelow())) { continue; // can never raise above "it" } mustReplay = !(c->isOnCurrentDesktop() && c->isOnCurrentActivity() && c->frameGeometry().intersects(frameGeometry()));