Changeset View
Changeset View
Standalone View
Standalone View
shell/currentcontainmentactionsmodel.cpp
Show First 20 Lines • Show All 264 Lines • ▼ Show 20 Line(s) | 262 | if (ctx && ctx->window()) { | |||
---|---|---|---|---|---|
265 | aboutDialog->windowHandle()->setTransientParent(ctx->window()); | 265 | aboutDialog->windowHandle()->setTransientParent(ctx->window()); | ||
266 | } | 266 | } | ||
267 | aboutDialog->show(); | 267 | aboutDialog->show(); | ||
268 | } | 268 | } | ||
269 | 269 | | |||
270 | void CurrentContainmentActionsModel::save() | 270 | void CurrentContainmentActionsModel::save() | ||
271 | { | 271 | { | ||
272 | 272 | | |||
273 | foreach (const QString &removedTrigger, m_removedTriggers) { | 273 | for (const QString &removedTrigger : qAsConst(m_removedTriggers)) { | ||
274 | m_containment->setContainmentActions(removedTrigger, QString()); | 274 | m_containment->setContainmentActions(removedTrigger, QString()); | ||
275 | } | 275 | } | ||
276 | m_removedTriggers.clear(); | 276 | m_removedTriggers.clear(); | ||
277 | 277 | | |||
278 | QHashIterator<QString, Plasma::ContainmentActions*> i(m_plugins); | 278 | QHashIterator<QString, Plasma::ContainmentActions*> i(m_plugins); | ||
279 | while (i.hasNext()) { | 279 | while (i.hasNext()) { | ||
280 | i.next(); | 280 | i.next(); | ||
281 | 281 | | |||
282 | KConfigGroup cfg(&m_baseCfg, i.key()); | 282 | KConfigGroup cfg(&m_baseCfg, i.key()); | ||
283 | i.value()->save(cfg); | 283 | i.value()->save(cfg); | ||
284 | 284 | | |||
285 | m_containment->setContainmentActions(i.key(), i.value()->pluginInfo().pluginName()); | 285 | m_containment->setContainmentActions(i.key(), i.value()->pluginInfo().pluginName()); | ||
286 | } | 286 | } | ||
287 | } | 287 | } | ||
288 | 288 | | |||
289 | #include "moc_currentcontainmentactionsmodel.cpp" | 289 | #include "moc_currentcontainmentactionsmodel.cpp" |