mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-22 21:06:01 +01:00
fix mouse glitches on clicks in constrained
This commit is contained in:
parent
80fc30d03e
commit
8e14f3a08d
1 changed files with 2 additions and 2 deletions
|
@ -156,7 +156,8 @@ void CInputManager::onMouseButton(wlr_pointer_button_event* e) {
|
||||||
|
|
||||||
switch (e->state) {
|
switch (e->state) {
|
||||||
case WLR_BUTTON_PRESSED:
|
case WLR_BUTTON_PRESSED:
|
||||||
refocus();
|
if (!g_pCompositor->m_sSeat.mouse->currentConstraint)
|
||||||
|
refocus();
|
||||||
|
|
||||||
// if clicked on a floating window make it top
|
// if clicked on a floating window make it top
|
||||||
if (g_pCompositor->windowValidMapped(g_pCompositor->m_pLastWindow) && g_pCompositor->m_pLastWindow->m_bIsFloating)
|
if (g_pCompositor->windowValidMapped(g_pCompositor->m_pLastWindow) && g_pCompositor->m_pLastWindow->m_bIsFloating)
|
||||||
|
@ -352,7 +353,6 @@ void CInputManager::recheckConstraint(SMouse* pMouse) {
|
||||||
if (!pMouse->currentConstraint)
|
if (!pMouse->currentConstraint)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
const auto MOUSECOORDS = getMouseCoordsInternal();
|
|
||||||
const auto PREGION = &pMouse->currentConstraint->region;
|
const auto PREGION = &pMouse->currentConstraint->region;
|
||||||
|
|
||||||
if (pMouse->currentConstraint->type == WLR_POINTER_CONSTRAINT_V1_CONFINED) {
|
if (pMouse->currentConstraint->type == WLR_POINTER_CONSTRAINT_V1_CONFINED) {
|
||||||
|
|
Loading…
Reference in a new issue