Changeset View
Changeset View
Standalone View
Standalone View
events.cpp
Context not available. | |||||
328 | Unmanaged* c = findUnmanaged(event->window); | 328 | Unmanaged* c = findUnmanaged(event->window); | ||
---|---|---|---|---|---|
329 | if (c == nullptr) | 329 | if (c == nullptr) | ||
330 | c = createUnmanaged(event->window); | 330 | c = createUnmanaged(event->window); | ||
331 | if (c) | 331 | if (c) { | ||
332 | return c->windowEvent(e); | 332 | // if hasScheduledRelease is true, it means a unamp and map sequence has occurred. | ||
333 | // since release is scheduled after map notify, this old Unmanaged will get released | ||||
334 | // before KWIN has chance to remanage it again. so release it right now. | ||||
335 | if (c->hasScheduledRelease()) { | ||||
336 | c->release(); | ||||
337 | c = createUnmanaged(event->window); | ||||
338 | } | ||||
339 | if (c) | ||||
340 | return c->windowEvent(e); | ||||
341 | } | ||||
333 | } | 342 | } | ||
334 | return (event->event != event->window); // hide wm typical event from Qt | 343 | return (event->event != event->window); // hide wm typical event from Qt | ||
335 | } | 344 | } | ||
Context not available. | |||||
1265 | // short enough to not cause problems in the close window animations. | 1274 | // short enough to not cause problems in the close window animations. | ||
1266 | // It's of course still possible that we miss the destroy in which case non-fatal | 1275 | // It's of course still possible that we miss the destroy in which case non-fatal | ||
1267 | // X errors are reported to the event loop and logged by Qt. | 1276 | // X errors are reported to the event loop and logged by Qt. | ||
1277 | m_scheduledRelease = true; | ||||
1268 | QTimer::singleShot(1, this, SLOT(release())); | 1278 | QTimer::singleShot(1, this, SLOT(release())); | ||
1269 | break; | 1279 | break; | ||
1270 | } | 1280 | } | ||
Context not available. |