-
Notifications
You must be signed in to change notification settings - Fork 3
shell: dismiss folder overlays when the launcher closes #18
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
Open
perlowja
wants to merge
3
commits into
singularityos-lab:main
Choose a base branch
from
perlowja:fix/folder-overlay-dismissal
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| using Gtk; | ||
|
|
||
| namespace Singularity { | ||
|
|
||
| /** | ||
| * Hide a layer-shell window and drop its GdkSurface. | ||
| * | ||
| * GTK keeps one wl_surface alive across hide/show, while gtk4-layer-shell | ||
| * destroys the zwlr_layer_surface_v1 at unmap and creates a NEW one over | ||
| * that same wl_surface on the next open. wl_surface state is persistent, so | ||
| * a frame that lands after the unmap leaves a buffer attached, and creating | ||
| * a layer surface over a surface that still holds a buffer is a client | ||
| * error the compositor answers by killing the connection: | ||
| * | ||
| * Gdk-Message: Error 71 (Protocol error) dispatching to Wayland display | ||
| * zwlr_layer_surface_v1 has never been configured | ||
| * | ||
| * Whether the stray frame lands is a race on wl_buffer.release, which is | ||
| * why a window would survive a variable number of open/close cycles before | ||
| * dying. Dropping the GdkSurface means the next open allocates a fresh | ||
| * wl_surface that cannot carry a stale buffer. | ||
| * | ||
| * This is the same sequence gtk4-layer-shell performs internally in | ||
| * gtk_layer_surface_remap(), so it is a supported, exercised path. | ||
| * unrealize() on a never-realized widget is a documented no-op, which makes | ||
| * this safe to call from a constructor-time hide. | ||
| * | ||
| * The cast matters: GtkWindow implements GtkNative, so a bare unrealize() | ||
| * binds to gtk_native_unrealize -- an internal vfunc -- rather than | ||
| * gtk_widget_unrealize. Verified by inspecting the C that valac emits for | ||
| * each spelling. | ||
| */ | ||
| public void close_layer_window (Gtk.Window window) { | ||
| ((Gtk.Widget) window).hide (); | ||
| ((Gtk.Widget) window).unrealize (); | ||
| } | ||
| } |
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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When an autohiding dock starts hiding and is revealed again within the 350 ms pulse window, this newly added unrealize creates a different surface/frame clock.
pulse_frame_clock()begins updating the old clock at line 977, but its timeout fetches the current clock at lines 979-980; after this remap, the old timeout therefore ends the new clock early, and the new timeout later callsend_updating()on it again. This can truncate the reveal transition or trigger an unmatched frame-clock update warning during ordinary rapid pointer leave/re-enter, so the timeout should retain and end the samefcinstance it began rather than looking it up again.Useful? React with 👍 / 👎.