Skip to content
Snippets Groups Projects
Commit d3b9d6dc authored by Fatih Uzunoğlu's avatar Fatih Uzunoğlu Committed by Steve Lhomme
Browse files

qt: hide interface window on close before waiting it to be handled

We are intercepting and inhibiting the close event for several reasons:
- Idle inhibit case (not inhibiting close used to crash at least Wayland).
- Video window using resources of the interface window case (Wayland, DComp).

Furthermore for the latter case we postpone destroying the window (hence
closing) even more, to the point destroying the window does not cause harm
with regard to the video window (fdb0a981 for DComp, 6923be9b for Wayland).

Because of this, the time between user clicks on the close button and the
window effectively closes is too much for responsiveness.

I propose to hide the window until destroying (and closing) to make close
more responsive. This should be fine because hiding should not
release the resources, as the default value of
`QQuickWindow::setPersistentGraphics()` is true and we are not overriding
it and we do not expect to override it as well.

I have also checked if this would cause saving the window state as hidden
before closing. However, `QVLCTools::saveWindowPosition()` does not save\
it so it should be fine.
parent a7c5f2e0
No related branches found
No related tags found
1 merge request!6902qt: restore the interface window closing responsiveness
Pipeline #569347 passed with stage
in 20 minutes and 54 seconds
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment