mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-05 06:25:59 +01:00
pointermgr: avoid hogging CMonitor refs
This commit is contained in:
parent
8b86ee8bf0
commit
49713fab04
1 changed files with 2 additions and 4 deletions
|
@ -17,10 +17,8 @@ CPointerManager::CPointerManager() {
|
||||||
|
|
||||||
onMonitorLayoutChange();
|
onMonitorLayoutChange();
|
||||||
|
|
||||||
PMONITOR->events.modeChanged.registerStaticListener(
|
PMONITOR->events.modeChanged.registerStaticListener([this](void* owner, std::any data) { g_pEventLoopManager->doLater([this]() { onMonitorLayoutChange(); }); }, nullptr);
|
||||||
[this, PMONITOR](void* owner, std::any data) { g_pEventLoopManager->doLater([this, PMONITOR]() { onMonitorLayoutChange(); }); }, nullptr);
|
PMONITOR->events.disconnect.registerStaticListener([this](void* owner, std::any data) { g_pEventLoopManager->doLater([this]() { onMonitorLayoutChange(); }); }, nullptr);
|
||||||
PMONITOR->events.disconnect.registerStaticListener(
|
|
||||||
[this, PMONITOR](void* owner, std::any data) { g_pEventLoopManager->doLater([this, PMONITOR]() { onMonitorLayoutChange(); }); }, nullptr);
|
|
||||||
PMONITOR->events.destroy.registerStaticListener(
|
PMONITOR->events.destroy.registerStaticListener(
|
||||||
[this](void* owner, std::any data) {
|
[this](void* owner, std::any data) {
|
||||||
if (g_pCompositor && !g_pCompositor->m_bIsShuttingDown)
|
if (g_pCompositor && !g_pCompositor->m_bIsShuttingDown)
|
||||||
|
|
Loading…
Reference in a new issue