MCPcopy Create free account
hub / github.com/bea4dev/ShojiWM / reapplyStaticManagedLayout

Method reapplyStaticManagedLayout

packages/config/src/window-manager.ts:3701–3724  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3699 return this.windows.find((window) => window.id === windowId);
3700 }
3701
3702 public isActiveWindowId(windowId: string): boolean {
3703 return this.activeWindowId === windowId;
3704 }
3705
3706 public moveFocusedTile(direction: -1 | 1): boolean {
3707 if (!this.isTiled) {
3708 return false;
3709 }
3710
3711 const focused = this.focusedWindow();
3712 if (!focused || !this.shouldTile(focused)) {
3713 return false;
3714 }
3715
3716 const tileable = this.tileableWindows();
3717 const currentIndex = tileable.findIndex(
3718 (window) => window.id === focused.id,
3719 );
3720 if (currentIndex < 0) {
3721 return false;
3722 }
3723
3724 const nextIndex = currentIndex + direction;
3725 if (nextIndex < 0 || nextIndex >= tileable.length) {
3726 return false;
3727 }

Callers 1

Calls 4

tileableWindowsMethod · 0.95
applyLayoutMethod · 0.95
markManagedWindowDirtyFunction · 0.90

Tested by

no test coverage detected