Skip to content

[enigma2] Fix PiG video flash when opening a child screen#1265

Merged
Huevos merged 1 commit into
OpenViX:Developerfrom
xcentaurix:pig4
May 29, 2026
Merged

[enigma2] Fix PiG video flash when opening a child screen#1265
Huevos merged 1 commit into
OpenViX:Developerfrom
xcentaurix:pig4

Conversation

@xcentaurix
Copy link
Copy Markdown
Contributor

@xcentaurix xcentaurix commented May 29, 2026

Problem:
When a screen containing a PiG (Picture in Graphic) was visible and a child screen without a PiG was opened, a brief but visible flash occurred: the live TV video would momentarily scale to fullscreen and appear cropped inside the parent screen's PiG area before the child screen finished rendering.

Root cause:
updatePosition could not distinguish between two fundamentally different situations that both call it with disable=1:
The PiG widget's parent screen is temporarily hidden because a child screen is being pushed on top (widget still alive, will become visible again when the child closes).
The PiG widget is being destroyed because its screen is closing completely (fullscreen must be restored).

Fix:
Fullscreen restoration is moved entirely into ~eVideoWidget(). The destructor checks m_state & 1 — the flag that is set the first time updatePosition commits a position to the hardware — to confirm this widget actually controlled the decoder before writing the restore. The else branch of updatePosition (the temporary-hide path) now only clears the hardware-applied state flag and does nothing to the decoder position.

@Huevos Huevos merged commit 3d0fb57 into OpenViX:Developer May 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants