Changeset View
Changeset View
Standalone View
Standalone View
effects/magiclamp/magiclamp.cpp
Context not available. | |||||
148 | } else { | 148 | } else { | ||
---|---|---|---|---|---|
149 | // Assumption: there is a panel containing the icon position | 149 | // Assumption: there is a panel containing the icon position | ||
150 | EffectWindow* panel = NULL; | 150 | EffectWindow* panel = NULL; | ||
151 | foreach (EffectWindow * window, effects->stackingOrder()) { | 151 | const KWin::EffectWindowList stack = effects->stackingOrder(); | ||
152 | for (EffectWindow * window : stack) { | ||||
152 | if (!window->isDock()) | 153 | if (!window->isDock()) | ||
153 | continue; | 154 | continue; | ||
154 | // we have to use intersects as there seems to be a Plasma bug | 155 | // we have to use intersects as there seems to be a Plasma bug | ||
Context not available. | |||||
228 | 229 | | |||
229 | if (position == Bottom) { | 230 | if (position == Bottom) { | ||
230 | float height_cube = float(geo.height()) * float(geo.height()) * float(geo.height()); | 231 | float height_cube = float(geo.height()) * float(geo.height()) * float(geo.height()); | ||
231 | foreach (WindowQuad quad, data.quads) { // krazy:exclude=foreach | 232 | for (WindowQuad quad : qAsConst(data.quads)) { | ||
232 | 233 | | |||
233 | if (quad[0].y() != lastQuad[0].y() || quad[2].y() != lastQuad[2].y()) { | 234 | if (quad[0].y() != lastQuad[0].y() || quad[2].y() != lastQuad[2].y()) { | ||
234 | quadFactor = quad[0].y() + (geo.height() - quad[0].y()) * progress; | 235 | quadFactor = quad[0].y() + (geo.height() - quad[0].y()) * progress; | ||
Context not available. | |||||
248 | } | 249 | } | ||
249 | } else if (position == Top) { | 250 | } else if (position == Top) { | ||
250 | float height_cube = float(geo.height()) * float(geo.height()) * float(geo.height()); | 251 | float height_cube = float(geo.height()) * float(geo.height()) * float(geo.height()); | ||
251 | foreach (WindowQuad quad, data.quads) { // krazy:exclude=foreach | 252 | for (WindowQuad quad : qAsConst(data.quads)) { | ||
252 | 253 | | |||
253 | if (quad[0].y() != lastQuad[0].y() || quad[2].y() != lastQuad[2].y()) { | 254 | if (quad[0].y() != lastQuad[0].y() || quad[2].y() != lastQuad[2].y()) { | ||
254 | quadFactor = geo.height() - quad[0].y() + (quad[0].y()) * progress; | 255 | quadFactor = geo.height() - quad[0].y() + (quad[0].y()) * progress; | ||
Context not available. | |||||
271 | } | 272 | } | ||
272 | } else if (position == Left) { | 273 | } else if (position == Left) { | ||
273 | float width_cube = float(geo.width()) * float(geo.width()) * float(geo.width()); | 274 | float width_cube = float(geo.width()) * float(geo.width()) * float(geo.width()); | ||
274 | foreach (WindowQuad quad, data.quads) { // krazy:exclude=foreach | 275 | for (WindowQuad quad : qAsConst(data.quads)) { | ||
275 | 276 | | |||
276 | if (quad[0].x() != lastQuad[0].x() || quad[1].x() != lastQuad[1].x()) { | 277 | if (quad[0].x() != lastQuad[0].x() || quad[1].x() != lastQuad[1].x()) { | ||
277 | quadFactor = geo.width() - quad[0].x() + (quad[0].x()) * progress; | 278 | quadFactor = geo.width() - quad[0].x() + (quad[0].x()) * progress; | ||
Context not available. | |||||
294 | } | 295 | } | ||
295 | } else if (position == Right) { | 296 | } else if (position == Right) { | ||
296 | float width_cube = float(geo.width()) * float(geo.width()) * float(geo.width()); | 297 | float width_cube = float(geo.width()) * float(geo.width()) * float(geo.width()); | ||
297 | foreach (WindowQuad quad, data.quads) { // krazy:exclude=foreach | 298 | for (WindowQuad quad : qAsConst(data.quads)) { | ||
298 | 299 | | |||
299 | if (quad[0].x() != lastQuad[0].x() || quad[1].x() != lastQuad[1].x()) { | 300 | if (quad[0].x() != lastQuad[0].x() || quad[1].x() != lastQuad[1].x()) { | ||
300 | quadFactor = quad[0].x() + (geo.width() - quad[0].x()) * progress; | 301 | quadFactor = quad[0].x() + (geo.width() - quad[0].x()) * progress; | ||
Context not available. |