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

Method refreshUsableAreaLayout

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

Source from the content-addressed store, hash-verified

3161 const output = COMPOSITOR.output.current[monitor];
3162 const ox = output?.position.x ?? 0;
3163 const oy = output?.position.y ?? 0;
3164 this.snapPreviewBroadcaster({
3165 monitor,
3166 kind,
3167 rect: {
3168 x: read(rect.x) - ox,
3169 y: read(rect.y) - oy,
3170 width: read(rect.width),
3171 height: read(rect.height),
3172 },
3173 });
3174 }
3175
3176 /** Update the floating-drag snap candidate + preview during a move. */
3177 private updateFloatingDragSnap(event: WindowMoveEvent) {
3178 if (event.modifiers.shift) {
3179 this.clearFloatingSnapPreview();
3180 return;
3181 }
3182 if (event.phase === "start") {
3183 this.clearFloatingSnapPreview();
3184 return;
3185 }
3186 if (event.phase === "end" || event.phase === "cancel") {
3187 return;
3188 }
3189
3190 const monitor =
3191 event.outputName && COMPOSITOR.output.list.includes(event.outputName)
3192 ? event.outputName
3193 : this.currentMonitor;
3194 const zone = monitor

Callers 1

Calls 5

tileViewportRectMethod · 0.95
applyLayoutMethod · 0.95
stopRectAnimationFunction · 0.90
managedRectEqualsFunction · 0.85
setMethod · 0.65

Tested by

no test coverage detected