mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 10:22:49 +00:00
kwin: const-ify iterator values where possible
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
affb5c58de
commit
e9eea95697
3 changed files with 7 additions and 8 deletions
|
@ -551,19 +551,19 @@ void Compositor::performCompositing()
|
|||
|
||||
bool Compositor::windowRepaintsPending() const
|
||||
{
|
||||
foreach (Toplevel * c, Workspace::self()->clientList()) {
|
||||
foreach (const Toplevel * c, Workspace::self()->clientList()) {
|
||||
if (!c->repaints().isEmpty())
|
||||
return true;
|
||||
}
|
||||
foreach (Toplevel * c, Workspace::self()->desktopList()) {
|
||||
foreach (const Toplevel * c, Workspace::self()->desktopList()) {
|
||||
if (!c->repaints().isEmpty())
|
||||
return true;
|
||||
}
|
||||
foreach (Toplevel * c, Workspace::self()->unmanagedList()) {
|
||||
foreach (const Toplevel * c, Workspace::self()->unmanagedList()) {
|
||||
if (!c->repaints().isEmpty())
|
||||
return true;
|
||||
}
|
||||
foreach (Toplevel * c, Workspace::self()->deletedList()) {
|
||||
foreach (const Toplevel * c, Workspace::self()->deletedList()) {
|
||||
if (!c->repaints().isEmpty())
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -102,7 +102,7 @@ void Deleted::copyToDeleted(Toplevel* c)
|
|||
m_minimized = client->isMinimized();
|
||||
m_modal = client->isModal();
|
||||
m_mainClients = client->mainClients();
|
||||
foreach (Client *c, m_mainClients) {
|
||||
foreach (const Client *c, m_mainClients) {
|
||||
connect(c, SIGNAL(windowClosed(KWin::Toplevel*,KWin::Deleted*)), SLOT(mainClientClosed(KWin::Toplevel*)));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1276,7 +1276,7 @@ QStringList EffectsHandlerImpl::loadedEffects() const
|
|||
|
||||
QStringList EffectsHandlerImpl::listOfEffects() const
|
||||
{
|
||||
KService::List offers = KServiceTypeTrader::self()->query("KWin/Effect");
|
||||
const KService::List offers = KServiceTypeTrader::self()->query("KWin/Effect");
|
||||
QStringList listOfModules;
|
||||
// First unload necessary effects
|
||||
foreach (const KService::Ptr & service, offers) {
|
||||
|
@ -1435,8 +1435,7 @@ bool EffectsHandlerImpl::loadEffect(const QString& name, bool checkDefault)
|
|||
// Make sure all depenedencies have been loaded
|
||||
// TODO: detect circular deps
|
||||
KPluginInfo plugininfo(service);
|
||||
QStringList dependencies = plugininfo.dependencies();
|
||||
foreach (const QString & depName, dependencies) {
|
||||
foreach (const QString & depName, plugininfo.dependencies()) {
|
||||
if (!loadEffect(depName)) {
|
||||
kError(1212) << "EffectsHandler::loadEffect : Couldn't load dependencies for effect " << name << endl;
|
||||
library->unload();
|
||||
|
|
Loading…
Add table
Reference in a new issue