Float undocked video/waveform while SE main is active#11246
Merged
Conversation
Apply WindowService.KeepTopmostWhileOwnerActive — introduced for Find/Replace in #11243 — to the undocked video player and audio visualizer windows. They now stay visually above SE main while either SE window is the active app, and drop behind when SE loses focus to another application. This addresses GrampaWildWilly's follow-up on #11229 ("the audio visualizer doesn't stay visible, floating on top of the main window") without touching Alt+Tab behavior — KeepTopmost… is just a Z-order knob; the two undocked windows remain independent top-levels in the Alt+Tab list, which was the point of #11229. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Applies the existing WindowService.KeepTopmostWhileOwnerActive behavior (added for Find/Replace) to the two “undocked” windows created from MainViewModel.VideoUndockControls, so they stay above the main window while Subtitle Edit is the active application and drop behind when SE loses focus.
Changes:
- Call
WindowService.KeepTopmostWhileOwnerActive(child, main)for the undocked video player window. - Call
WindowService.KeepTopmostWhileOwnerActive(child, main)for the undocked audio visualizer window. - Add inline comments clarifying Z-order intent and non-impact on Alt+Tab grouping.
|
THANK YOU!!!! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Applies
WindowService.KeepTopmostWhileOwnerActive— introduced for Find/Replace in #11243 — to the two undocked windows opened fromMainViewModel.VideoUndockControls(aroundMainViewModel.cs:5252/:5258).Result: the undocked video player and audio visualizer now stay visually above SE main while either SE window is the active app, and drop behind when SE loses focus to another application. Matches what
GrampaWildWillyasked for in their follow-up on #11229 ("the audio visualizer doesn't stay visible, floating on top of the main window").Important: this does not change Alt+Tab grouping.
KeepTopmost…is a Z-order knob, not an ownership change. The two undocked windows remain independent top-levels in the Alt+Tab list, which was the whole point of #11229.Why it's safe
ShowIndependentWindow, which runsconfigurebeforeShow(). The helper just subscribes toActivated/Deactivated(which fire after Show) and writes one initial Topmost value — both safe on an unshown window.Closedevent, so the existing redock/cleanup path inMainViewModel.cs:5230-5263continues to work unchanged.Topmostflips tofalseon Deactivated, so it does not leak across applications.main.IsActivegoes to false, so neither helper raises its child above the fullscreen window.Test plan
Closedcleanup).🤖 Generated with Claude Code