summaryrefslogtreecommitdiff
path: root/src/helpers/Monitor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/helpers/Monitor.cpp')
-rw-r--r--src/helpers/Monitor.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/helpers/Monitor.cpp b/src/helpers/Monitor.cpp
index 08dbdaea..74dd995b 100644
--- a/src/helpers/Monitor.cpp
+++ b/src/helpers/Monitor.cpp
@@ -139,6 +139,8 @@ void CMonitor::onConnect(bool noRule) {
}
m_frameScheduler->onPresented();
+
+ m_events.presented.emit();
});
m_listeners.destroy = m_output->events.destroy.listen([this] {
@@ -1804,6 +1806,7 @@ bool CMonitor::attemptDirectScanout() {
auto PBUFFER = PSURFACE->m_current.buffer.m_buffer;
+ // #TODO this entire bit needs figuring out, vrr goes down the drain without it
if (PBUFFER == m_output->state->state().buffer) {
PSURFACE->presentFeedback(Time::steadyNow(), m_self.lock());
@@ -1822,6 +1825,10 @@ bool CMonitor::attemptDirectScanout() {
m_scanoutNeedsCursorUpdate = false;
}
+ //#TODO this entire bit is bootleg deluxe, above bit is to not make vrr go down the drain, returning early here means fifo gets forever locked.
+ if (PSURFACE->m_fifo)
+ PSURFACE->m_stateQueue.unlockFirst(LOCK_REASON_FIFO);
+
return true;
}