diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 88d7349915..741723191c 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -1274,7 +1274,7 @@ void DesktopGridEffect::slotNumberDesktopsChanged(uint old) { if (!activated) return; - const int desktop = effects->numberOfDesktops(); + const uint desktop = effects->numberOfDesktops(); bool enableAdd = desktop < 20; bool enableRemove = desktop > 1; for (QHash< DesktopButtonsView*, EffectWindow* >::iterator it = m_desktopButtonsViews.begin(); diff --git a/manage.cpp b/manage.cpp index c06071329f..738decad48 100644 --- a/manage.cpp +++ b/manage.cpp @@ -207,7 +207,7 @@ bool Client::manage(Window w, bool isMapped) } if (desk == 0) // Assume window wants to be visible on the current desktop - desk = isDesktop() ? NET::OnAllDesktops : VirtualDesktopManager::self()->current(); + desk = isDesktop() ? static_cast(NET::OnAllDesktops) : VirtualDesktopManager::self()->current(); desk = rules()->checkDesktop(desk, !isMapped); if (desk != NET::OnAllDesktops) // Do range check desk = qBound(1, desk, static_cast(VirtualDesktopManager::self()->count()));