mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-07-26 01:31:54 -07:00
input: improve mouse release conditions
This commit is contained in:
@@ -770,6 +770,8 @@ void CKeybindManager::changeworkspace(std::string args) {
|
||||
|
||||
auto pWorkspaceToChangeTo = g_pCompositor->getWorkspaceByID(PCURRENTWORKSPACE->m_sPrevWorkspace.iID);
|
||||
|
||||
g_pInputManager->releaseAllMouseButtons();
|
||||
|
||||
if (pWorkspaceToChangeTo) {
|
||||
const auto PMONITORWORKSPACEOWNER = PMONITOR->ID == pWorkspaceToChangeTo->m_iMonitorID ? PMONITOR : g_pCompositor->getMonitorFromID(pWorkspaceToChangeTo->m_iMonitorID);
|
||||
|
||||
@@ -814,6 +816,8 @@ void CKeybindManager::changeworkspace(std::string args) {
|
||||
return;
|
||||
}
|
||||
|
||||
g_pInputManager->releaseAllMouseButtons();
|
||||
|
||||
const auto PMONITORWORKSPACEOWNER = PMONITOR->ID == pWorkspaceToChangeTo->m_iMonitorID ? PMONITOR : g_pCompositor->getMonitorFromID(pWorkspaceToChangeTo->m_iMonitorID);
|
||||
|
||||
g_pCompositor->setActiveMonitor(PMONITORWORKSPACEOWNER);
|
||||
|
Reference in New Issue
Block a user