Changeset View
Changeset View
Standalone View
Standalone View
workspace.cpp
Show First 20 Lines • Show All 44 Lines • ▼ Show 20 Line(s) | |||||
45 | #include "netinfo.h" | 45 | #include "netinfo.h" | ||
46 | #include "outline.h" | 46 | #include "outline.h" | ||
47 | #include "placement.h" | 47 | #include "placement.h" | ||
48 | #include "rules.h" | 48 | #include "rules.h" | ||
49 | #include "screenedge.h" | 49 | #include "screenedge.h" | ||
50 | #include "screens.h" | 50 | #include "screens.h" | ||
51 | #include "platform.h" | 51 | #include "platform.h" | ||
52 | #include "scripting/scripting.h" | 52 | #include "scripting/scripting.h" | ||
53 | #include "sync_filter.h" | ||||
53 | #ifdef KWIN_BUILD_TABBOX | 54 | #ifdef KWIN_BUILD_TABBOX | ||
54 | #include "tabbox.h" | 55 | #include "tabbox.h" | ||
55 | #endif | 56 | #endif | ||
56 | #include "unmanaged.h" | 57 | #include "unmanaged.h" | ||
57 | #include "useractions.h" | 58 | #include "useractions.h" | ||
58 | #include "virtualdesktops.h" | 59 | #include "virtualdesktops.h" | ||
59 | #include "was_user_interaction_x11_filter.h" | 60 | #include "was_user_interaction_x11_filter.h" | ||
60 | #include "wayland_server.h" | 61 | #include "wayland_server.h" | ||
▲ Show 20 Lines • Show All 380 Lines • ▼ Show 20 Line(s) | 440 | if (new_active_client == nullptr | |||
441 | // No client activated in manage() | 442 | // No client activated in manage() | ||
442 | if (new_active_client == nullptr) | 443 | if (new_active_client == nullptr) | ||
443 | new_active_client = topClientOnDesktop(VirtualDesktopManager::self()->current(), -1); | 444 | new_active_client = topClientOnDesktop(VirtualDesktopManager::self()->current(), -1); | ||
444 | if (new_active_client == nullptr && !desktops.isEmpty()) | 445 | if (new_active_client == nullptr && !desktops.isEmpty()) | ||
445 | new_active_client = findDesktop(true, VirtualDesktopManager::self()->current()); | 446 | new_active_client = findDesktop(true, VirtualDesktopManager::self()->current()); | ||
446 | } | 447 | } | ||
447 | if (new_active_client != nullptr) | 448 | if (new_active_client != nullptr) | ||
448 | activateClient(new_active_client); | 449 | activateClient(new_active_client); | ||
450 | | ||||
451 | if (Xcb::Extensions::self()->isSyncAvailable()) { | ||||
452 | m_syncFilter.reset(new SyncAlarmNotifyX11Filter()); | ||||
453 | } | ||||
449 | } | 454 | } | ||
450 | 455 | | |||
zzag: This `if` must be in `initWithX11`. | |||||
451 | Workspace::~Workspace() | 456 | Workspace::~Workspace() | ||
452 | { | 457 | { | ||
You don't need a connect and m_syncFilter is shadowed. if (Xcb::Extensions::self()->isSyncAvailable()) { m_syncFilter.reset(new SyncAlarmNotifyX11Filter); } zzag: You don't need a `connect` and `m_syncFilter` is shadowed.
```lang=cpp
if (Xcb::Extensions… | |||||
453 | blockStackingUpdates(true); | 458 | blockStackingUpdates(true); | ||
454 | 459 | | |||
455 | // TODO: grabXServer(); | 460 | // TODO: grabXServer(); | ||
456 | 461 | | |||
457 | // Use stacking_order, so that kwin --replace keeps stacking order | 462 | // Use stacking_order, so that kwin --replace keeps stacking order | ||
458 | const QList<Toplevel *> stack = stacking_order; | 463 | const QList<Toplevel *> stack = stacking_order; | ||
459 | // "mutex" the stackingorder, since anything trying to access it from now on will find | 464 | // "mutex" the stackingorder, since anything trying to access it from now on will find | ||
460 | // many dangeling pointers and crash | 465 | // many dangeling pointers and crash | ||
▲ Show 20 Lines • Show All 2324 Lines • Show Last 20 Lines |
This if must be in initWithX11.