summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-12-15 17:17:15 +0000
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-12-15 17:17:15 +0000
commit3bd9ee0d32c08922ebe943c8319aa756ecc55cca (patch)
treefa8411c8d171b74c496d61cdee3e54a01781455e /src
parent95a042691a34d6d04dc8a3cf5715165f34d1fa71 (diff)
minor xcursor and scale fixes
Diffstat (limited to 'src')
-rw-r--r--src/helpers/Monitor.cpp4
-rw-r--r--src/helpers/Monitor.hpp2
-rw-r--r--src/render/Renderer.cpp2
3 files changed, 5 insertions, 3 deletions
diff --git a/src/helpers/Monitor.cpp b/src/helpers/Monitor.cpp
index d322cee5..823066ac 100644
--- a/src/helpers/Monitor.cpp
+++ b/src/helpers/Monitor.cpp
@@ -96,8 +96,6 @@ void CMonitor::onConnect(bool noRule) {
}
m_bEnabled = true;
-
- wlr_xcursor_manager_load(g_pCompositor->m_sWLRXCursorMgr, monitorRule.scale);
// create it in the arr
vecPosition = monitorRule.offset;
@@ -110,6 +108,8 @@ void CMonitor::onConnect(bool noRule) {
if (!noRule)
g_pHyprRenderer->applyMonitorRule(this, &monitorRule, true);
+ wlr_xcursor_manager_load(g_pCompositor->m_sWLRXCursorMgr, scale);
+
Debug::log(LOG, "Added new monitor with name %s at %i,%i with size %ix%i, pointer %x", output->name, (int)vecPosition.x, (int)vecPosition.y, (int)vecPixelSize.x, (int)vecPixelSize.y, output);
damage = wlr_output_damage_create(output);
diff --git a/src/helpers/Monitor.hpp b/src/helpers/Monitor.hpp
index b5fea7a9..75cdb969 100644
--- a/src/helpers/Monitor.hpp
+++ b/src/helpers/Monitor.hpp
@@ -20,7 +20,7 @@ public:
uint64_t ID = -1;
int activeWorkspace = -1;
- float scale = 1;
+ float scale = 1;
std::string szName = "";
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp
index 20e77afe..90dfaa71 100644
--- a/src/render/Renderer.cpp
+++ b/src/render/Renderer.cpp
@@ -1410,6 +1410,8 @@ bool CHyprRenderer::applyMonitorRule(CMonitor* pMonitor, SMonitorRule* pMonitorR
pMonitor->vecPosition = pMonitorRule->offset;
}
+ wlr_output_enable(pMonitor->output, 1);
+
// update renderer (here because it will call rollback, so we cannot do this before committing)
g_pHyprOpenGL->destroyMonitorResources(pMonitor);