all/window: use global screeninfo pool for screen getter

This commit is contained in:
outfoxxed 2024-03-27 02:43:14 -07:00
parent 9cbd5abd96
commit 3026d3400a
Signed by: outfoxxed
GPG key ID: 4C88A185FB89301E
4 changed files with 17 additions and 8 deletions

View file

@ -14,6 +14,7 @@
#include <qtmetamacros.h>
#include <qtypes.h>
#include "../core/qmlglobal.hpp"
#include "../core/qmlscreen.hpp"
#include "../core/reload.hpp"
#include "session_lock/session_lock.hpp"
@ -243,10 +244,7 @@ QuickshellScreenInfo* WlSessionLockSurface::screen() const {
qscreen = this->window->screen();
}
return new QuickshellScreenInfo(
const_cast<WlSessionLockSurface*>(this), // NOLINT
qscreen
);
return QuickshellTracked::instance()->screenInfo(qscreen);
}
void WlSessionLockSurface::setScreen(QScreen* qscreen) {