aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornovakne <hmachet@zoho.com>2021-04-20 11:56:25 +0200
committerIsaac Freund <ifreund@ifreund.xyz>2021-04-20 13:14:45 +0200
commitdf3e9930137c0ec4871208b09832e59d537453b7 (patch)
treee1fe3c8ec5921fd21093059ff20adf89e0579835
parent6d36846cdfbb79e5a5041dd312edf8aa96ac5ebf (diff)
downloadriver-df3e9930137c0ec4871208b09832e59d537453b7.tar.gz
river-df3e9930137c0ec4871208b09832e59d537453b7.tar.xz
river: fix to work with latest zig-pixman
m---------deps/zig-pixman0
-rw-r--r--river/PointerConstraint.zig4
2 files changed, 2 insertions, 2 deletions
diff --git a/deps/zig-pixman b/deps/zig-pixman
-Subproject 7847fd1bae7021cdb572e77eac93676c551fd1e
+Subproject f8e682ac2f640368ebb414aa2e7db6a2be1b179
diff --git a/river/PointerConstraint.zig b/river/PointerConstraint.zig
index cf666dd..fc5cf20 100644
--- a/river/PointerConstraint.zig
+++ b/river/PointerConstraint.zig
@@ -66,7 +66,7 @@ pub fn setAsActive(self: *Self) void {
self.cursor.constraint = self.constraint;
- if (self.constraint.current.region.notEmpty() != 0) {
+ if (self.constraint.current.region.notEmpty()) {
_ = self.constraint.region.intersect(&self.constraint.surface.input_region, &self.constraint.current.region);
} else {
_ = self.constraint.region.copy(&self.constraint.surface.input_region);
@@ -84,7 +84,7 @@ fn constrainToRegion(self: *Self) void {
var box: pixman.Box32 = undefined;
- if (self.constraint.region.containsPoint(cx, cy, &box) == 0) {
+ if (!self.constraint.region.containsPoint(cx, cy, &box)) {
var nRects: c_int = undefined;
const rects = self.constraint.region.rectangles(&nRects);