mod(size): rename merge function to add; new max function
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 1m6s
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 1m6s
This commit is contained in:
@@ -86,12 +86,8 @@ pub fn Scrollable(Event: type) type {
|
||||
.resize => |size| {
|
||||
this.size = size;
|
||||
// TODO: scrollbar space - depending on configuration and only if necessary?
|
||||
const min_size = this.container.minSize();
|
||||
this.container_size = .{
|
||||
.anchor = size.anchor,
|
||||
.cols = @max(min_size.cols, size.cols),
|
||||
.rows = @max(min_size.rows, size.rows),
|
||||
};
|
||||
this.container_size = size.max(this.container.minSize());
|
||||
this.container_size.anchor = size.anchor;
|
||||
try this.container.handle(.{ .resize = this.container_size });
|
||||
},
|
||||
// TODO: other means to scroll except with the mouse? (i.e. Ctrl-u/d, k/j, etc.?)
|
||||
|
||||
Reference in New Issue
Block a user