Skip to content

Commit 6bb6183

Browse files
Popoclaude
andcommitted
fix: declare macOS platform, guard target windows to a single desktop
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 9c26ea2 commit 6bb6183

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

extensions/bento-window/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"author": "Popo",
88
"categories": ["Productivity", "System"],
99
"license": "MIT",
10+
"platforms": ["macOS"],
1011
"commands": [
1112
{
1213
"name": "tile",

extensions/bento-window/src/tiling.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,9 @@ export async function runTile(scope: "app" | "all") {
183183

184184
// Resolve desktop from the target windows so multi-monitor setups pick the correct screen
185185
const targetDesktopId = targetWindows[0].desktopId;
186+
// getWindowsOnActiveDesktop() already scopes to a single desktop (verified on dual-display
187+
// setups), so this filter is a no-op today — it just guarantees the invariant at code level.
188+
targetWindows = targetWindows.filter((w) => w.desktopId === targetDesktopId);
186189
const desktop =
187190
desktops.find((d) => d.id === targetDesktopId) ??
188191
desktops.find((d) => d.active && windows.some((w) => w.desktopId === d.id)) ??

0 commit comments

Comments
 (0)