Skip to content

Commit

Permalink
LXQtTaskbarWaylandBackend: possibly fix crash on showDesktop for non-
Browse files Browse the repository at this point in the history
KWin
  • Loading branch information
gfgit committed Mar 28, 2024
1 parent 8773243 commit 0b91f57
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion panel/backends/wayland/lxqttaskbarbackendwayland.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -450,11 +450,14 @@ bool LXQtTaskbarWaylandBackend::isAreaOverlapped(const QRect &area) const

bool LXQtTaskbarWaylandBackend::isShowingDesktop() const
{
return m_managment->isShowingDesktop();
return m_managment->isActive() ? m_managment->isShowingDesktop() : false;
}

bool LXQtTaskbarWaylandBackend::showDesktop(bool value)
{
if(!m_managment->isActive())
return false;

enum LXQtTaskBarPlasmaWindowManagment::show_desktop flag_;
if(value)
flag_ = LXQtTaskBarPlasmaWindowManagment::show_desktop::show_desktop_enabled;
Expand Down

0 comments on commit 0b91f57

Please sign in to comment.