Commit c3772f4c authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

Delete pointless nullptr checks

Lifetime of XdgShellClient is bounded to Workspace, so we no longer need
to check whether tabbox is still present around.
parent 64feafc1
......@@ -214,7 +214,7 @@ void Client::releaseWindow(bool on_shutdown)
deleting = true;
#ifdef KWIN_BUILD_TABBOX
TabBox::TabBox *tabBox = TabBox::TabBox::self();
if (tabBox && tabBox->isDisplayed() && tabBox->currentClient() == this) {
if (tabBox->isDisplayed() && tabBox->currentClient() == this) {
tabBox->nextPrev(true);
}
#endif
......
......@@ -1792,7 +1792,7 @@ void Workspace::updateTabbox()
{
#ifdef KWIN_BUILD_TABBOX
TabBox::TabBox *tabBox = TabBox::TabBox::self();
if (tabBox && tabBox->isDisplayed()) {
if (tabBox->isDisplayed()) {
tabBox->reset(true);
}
#endif
......
......@@ -374,7 +374,7 @@ void XdgShellClient::destroyClient()
m_closing = true;
#ifdef KWIN_BUILD_TABBOX
TabBox::TabBox *tabBox = TabBox::TabBox::self();
if (tabBox && tabBox->isDisplayed() && tabBox->currentClient() == this) {
if (tabBox->isDisplayed() && tabBox->currentClient() == this) {
tabBox->nextPrev(true);
}
#endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment