Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving a window doesn't trigger a layout #93

Closed
dalyIsaac opened this issue Jun 26, 2022 · 2 comments
Closed

Moving a window doesn't trigger a layout #93

dalyIsaac opened this issue Jun 26, 2022 · 2 comments
Labels
bug Something isn't working core Whim

Comments

@dalyIsaac
Copy link
Owner

As a result:

  • The focus indicator doesn't update immediately
  • When moving windows between workspaces, windows don't immediately re-layout.
@dalyIsaac dalyIsaac added bug Something isn't working core Whim labels Jun 26, 2022
@dalyIsaac dalyIsaac moved this to In Progress in Whim Jun 27, 2022
@dalyIsaac
Copy link
Owner Author

dalyIsaac commented Jun 28, 2022

[DBG] Window:74 [Focus] Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}
[DBG] FocusIndicatorPlugin:97 [Show] Showing focus indicator
[VRB] FocusIndicatorPlugin:101 [Show] Focused monitor Screen[Bounds=(X: 0, Y: 0, Width: 3840, Height: 2160) WorkingArea=(X: 0, Y: 0, Width: 3840, Height: 2112) Primary=True DeviceName=\\.\DISPLAY4
[VRB] FocusIndicatorPlugin:102 [Show] Active workspace 1
[DBG] FocusIndicatorPlugin:106 [Show] No window to show focus indicator for
[DBG] FocusIndicatorPlugin:138 [Hide] Hiding focus indicator
[DBG] Win32Helper:44 [HideWindow] Hiding window HWND 27593494
[DBG] MonitorManager:73 [WindowManager_WindowFocused] Focusing on Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}
[DBG] WorkspaceManager:202 [GetMonitorForWorkspace] Getting monitor for active workspace 2
[DBG] WorkspaceManager:209 [GetMonitorForWorkspace] Found monitor Screen[Bounds=(X: 3840, Y: 940, Width: 1920, Height: 1080) WorkingArea=(X: 3840, Y: 940, Width: 1920, Height: 1032) Primary=False DeviceName=\\.\DISPLAY1 for workspace 2
[DBG] MonitorManager:79 [WindowManager_WindowFocused] Focused on monitor Screen[Bounds=(X: 3840, Y: 940, Width: 1920, Height: 1080) WorkingArea=(X: 3840, Y: 940, Width: 1920, Height: 1032) Primary=False DeviceName=\\.\DISPLAY1
[VRB] Workspace:141 [WindowManager_WindowFocused] Trying to focus window Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}
[VRB] Workspace:141 [WindowManager_WindowFocused] Trying to focus window Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}
[VRB] Workspace:141 [WindowManager_WindowFocused] Trying to focus window Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}
[DBG] Workspace:150 [WindowManager_WindowFocused] Focused window Untitled - Notepad (Notepad) [37144] <Notepad> {26872960} in workspace 2
[VRB] Workspace:141 [WindowManager_WindowFocused] Trying to focus window Untitled - Notepad (Notepad) [37144] <Notepad> {26872960}

The logs show the window focus event is handled by (in order):

  1. FocusIndicatorPlugin
  2. MonitorManager
  3. WorkspaceManager
  4. MonitorManager (the rest of the method from 2.)

This is because of the order of registration. Plugins register in DoConfig, then the managers are registered in Initialize.

This causes bugs manifesting as:

  • Out of order updates
  • Interleaving

dalyIsaac added a commit that referenced this issue Jun 29, 2022
@dalyIsaac
Copy link
Owner Author

Resolved by #103 and #121.

Repository owner moved this from In Progress to Done in Whim Jul 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working core Whim
Projects
Status: Done
Development

No branches or pull requests

1 participant