mirror of
https://github.com/Trensa-Organization/hy3.git
synced 2025-03-15 18:53:40 +01:00
fixup: fix breakage after cursor rewrite
This commit is contained in:
parent
33c8d761ff
commit
400930e039
4 changed files with 35 additions and 51 deletions
77
flake.lock
generated
77
flake.lock
generated
|
@ -32,46 +32,47 @@
|
||||||
"hyprland": {
|
"hyprland": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"hyprcursor": "hyprcursor",
|
"hyprcursor": "hyprcursor",
|
||||||
"hyprland-protocols": "hyprland-protocols",
|
|
||||||
"hyprlang": "hyprlang",
|
"hyprlang": "hyprlang",
|
||||||
"hyprwayland-scanner": "hyprwayland-scanner",
|
"hyprwayland-scanner": "hyprwayland-scanner",
|
||||||
"nixpkgs": "nixpkgs",
|
"nixpkgs": "nixpkgs",
|
||||||
"systems": "systems",
|
"systems": "systems",
|
||||||
"wlroots": "wlroots",
|
|
||||||
"xdph": "xdph"
|
"xdph": "xdph"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714837352,
|
"lastModified": 1715817355,
|
||||||
"narHash": "sha256-QzzJTb+0CBqgAT0wKZsOt1rky5+u2zMUlNxbZcGj2VM=",
|
"narHash": "sha256-/XuIc6AkzUZVJkKNYBCSGK+G5sLgfLY9zd+gIXLNcGA=",
|
||||||
"owner": "hyprwm",
|
"ref": "refs/heads/main",
|
||||||
"repo": "Hyprland",
|
"rev": "de9798fcf9494eb082bd168175390c0d47b8478b",
|
||||||
"rev": "cba1ade848feac44b2eda677503900639581c3f4",
|
"revCount": 4702,
|
||||||
"type": "github"
|
"submodules": true,
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/hyprwm/hyprland"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "hyprwm",
|
"submodules": true,
|
||||||
"repo": "Hyprland",
|
"type": "git",
|
||||||
"rev": "cba1ade848feac44b2eda677503900639581c3f4",
|
"url": "https://github.com/hyprwm/hyprland"
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"hyprland-protocols": {
|
"hyprland-protocols": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"hyprland",
|
"hyprland",
|
||||||
|
"xdph",
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"systems": [
|
"systems": [
|
||||||
"hyprland",
|
"hyprland",
|
||||||
|
"xdph",
|
||||||
"systems"
|
"systems"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714869498,
|
"lastModified": 1691753796,
|
||||||
"narHash": "sha256-vbLVOWvQqo4n1yvkg/Q70VTlPbMmTiCQfNTgcWDCfJM=",
|
"narHash": "sha256-zOEwiWoXk3j3+EoF3ySUJmberFewWlagvewDRuWYAso=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprland-protocols",
|
"repo": "hyprland-protocols",
|
||||||
"rev": "e06482e0e611130cd1929f75e8c1cf679e57d161",
|
"rev": "0c2ce70625cb30aef199cb388f99e19a61a6ce03",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -92,11 +93,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713121246,
|
"lastModified": 1715610285,
|
||||||
"narHash": "sha256-502X0Q0fhN6tJK7iEUA8CghONKSatW/Mqj4Wappd++0=",
|
"narHash": "sha256-i8ZQeEiwXYhmzqyUaFeHhnRVu6L7g5cy33PcTQjPw4U=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprlang",
|
"repo": "hyprlang",
|
||||||
"rev": "78fcaa27ae9e1d782faa3ff06c8ea55ddce63706",
|
"rev": "19ec261528f924a275860dcab7979519e41809e5",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -117,11 +118,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714755542,
|
"lastModified": 1715608589,
|
||||||
"narHash": "sha256-D0pg+ZRwrt4lavZ97Ca8clsgbPA3duLj8iEM7riaIFY=",
|
"narHash": "sha256-vimNaLjLcoNIvBhF37GaB6PRYEvKMamY3UnDE9M5MW8=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprwayland-scanner",
|
"repo": "hyprwayland-scanner",
|
||||||
"rev": "1270ebaa539e56d61b708c24b072b09cbbd3a828",
|
"rev": "65c2636484e5cb00583b8a7446c3fb657f568883",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -132,11 +133,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714253743,
|
"lastModified": 1715447595,
|
||||||
"narHash": "sha256-mdTQw2XlariysyScCv2tTE45QSU9v/ezLcHJ22f0Nxc=",
|
"narHash": "sha256-VsVAUQOj/cS1LCOmMjAGeRksXIAdPnFIjCQ0XLkCsT0=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "58a1abdbae3217ca6b702f03d3b35125d88a2994",
|
"rev": "062ca2a9370a27a35c524dc82d540e6e9824b652",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -166,29 +167,9 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"wlroots": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1713731601,
|
|
||||||
"narHash": "sha256-bdcKdtLkusvv85DNuJsajZLFeq7bXp+x5AGP1Sd4wD8=",
|
|
||||||
"owner": "hyprwm",
|
|
||||||
"repo": "wlroots-hyprland",
|
|
||||||
"rev": "5c1d51c5a2793480f5b6c4341ad0797052aec2ea",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hyprwm",
|
|
||||||
"repo": "wlroots-hyprland",
|
|
||||||
"rev": "5c1d51c5a2793480f5b6c4341ad0797052aec2ea",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"xdph": {
|
"xdph": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"hyprland-protocols": [
|
"hyprland-protocols": "hyprland-protocols",
|
||||||
"hyprland",
|
|
||||||
"hyprland-protocols"
|
|
||||||
],
|
|
||||||
"hyprlang": [
|
"hyprlang": [
|
||||||
"hyprland",
|
"hyprland",
|
||||||
"hyprlang"
|
"hyprlang"
|
||||||
|
@ -203,11 +184,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714060055,
|
"lastModified": 1714662532,
|
||||||
"narHash": "sha256-j43TS9wv9luaAlpxcxw0sjxkbcc2mGANVR2RYgo3RCw=",
|
"narHash": "sha256-Pj2xGSYhapYbXL7sk7TTlOtCZcTfPQoL3fPbZeg7L4Y=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "xdg-desktop-portal-hyprland",
|
"repo": "xdg-desktop-portal-hyprland",
|
||||||
"rev": "0fe840441e43da12cd7865ed9aa8cdc35a8da85a",
|
"rev": "1f228ba2f1f254195c0b571302b37482861abee3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -30,7 +30,9 @@
|
||||||
impure = import ./shell.nix {
|
impure = import ./shell.nix {
|
||||||
pkgs = import <nixpkgs> {};
|
pkgs = import <nixpkgs> {};
|
||||||
hlversion = props.version;
|
hlversion = props.version;
|
||||||
hyprland = (pkgs.appendOverlays [ hyprland.overlays.hyprland-packages ]).hyprland-debug;
|
hyprland = (pkgs.appendOverlays [ hyprland.overlays.hyprland-packages ]).hyprland-debug.overrideAttrs {
|
||||||
|
dontStrip = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
#include <hyprland/src/desktop/DesktopTypes.hpp>
|
#include <hyprland/src/desktop/DesktopTypes.hpp>
|
||||||
#include <hyprland/src/desktop/Workspace.hpp>
|
#include <hyprland/src/desktop/Workspace.hpp>
|
||||||
#include <hyprland/src/plugins/PluginAPI.hpp>
|
#include <hyprland/src/plugins/PluginAPI.hpp>
|
||||||
|
#include <hyprland/src/managers/PointerManager.hpp>
|
||||||
#include <ranges>
|
#include <ranges>
|
||||||
|
|
||||||
#include "Hy3Layout.hpp"
|
#include "Hy3Layout.hpp"
|
||||||
|
@ -1358,7 +1359,7 @@ fsupdate:
|
||||||
}
|
}
|
||||||
|
|
||||||
void Hy3Layout::warpCursorToBox(const Vector2D& pos, const Vector2D& size) {
|
void Hy3Layout::warpCursorToBox(const Vector2D& pos, const Vector2D& size) {
|
||||||
auto cursorpos = Vector2D(g_pCompositor->m_sWLRCursor->x, g_pCompositor->m_sWLRCursor->y);
|
auto cursorpos = g_pPointerManager->position();
|
||||||
|
|
||||||
if (cursorpos.x < pos.x || cursorpos.x >= pos.x + size.x || cursorpos.y < pos.y
|
if (cursorpos.x < pos.x || cursorpos.x >= pos.x + size.x || cursorpos.y < pos.y
|
||||||
|| cursorpos.y >= pos.y + size.y)
|
|| cursorpos.y >= pos.y + size.y)
|
||||||
|
|
|
@ -113,7 +113,7 @@ void dispatch_movefocus(std::string value) {
|
||||||
|
|
||||||
auto args = CVarList(value);
|
auto args = CVarList(value);
|
||||||
|
|
||||||
static const auto no_cursor_warps = ConfigValue<Hyprlang::INT>("general:no_cursor_warps");
|
static const auto no_cursor_warps = ConfigValue<Hyprlang::INT>("cursor:no_warps");
|
||||||
auto warp_cursor = !*no_cursor_warps;
|
auto warp_cursor = !*no_cursor_warps;
|
||||||
|
|
||||||
int argi = 0;
|
int argi = 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue