Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -235,12 +235,19 @@ export class TilingWindowManager {
);
}

if (verticalMaximize) {
// When maximize-with-gap is enabled, skip the VERTICAL/HORIZONTAL maximize
// flag: Meta's maximize snaps the window to the full work-area extent and
// ignores the gapped rect computed by addGaps(), so half-tiles lose their
// top/bottom (or left/right) gaps. Fall through to the override_constraints
// path used by quarter-tiles, which preserves gaps. Mirrors the
// full-maximize-with-gap handling above.
Comment on lines +241 to +243

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would be more concerned with what happens if window.override_constraints does not exist (i.e. on non-Ubuntu)?

const gappedTile = Settings.getBoolean('maximize-with-gap');
if (verticalMaximize && !gappedTile) {
if (window.set_maximize_flags)
window.set_maximize_flags(Meta.MaximizeFlags.VERTICAL);
else
window.maximize(Meta.MaximizeFlags.VERTICAL);
} else if (horizontalMaximize) {
} else if (horizontalMaximize && !gappedTile) {
if (window.set_maximize_flags)
window.set_maximize_flags(Meta.MaximizeFlags.HORIZONTAL);
else
Expand Down
Loading