Skip to content

Do not clear CALayer contents when resizing macOS surfaces#357

Merged
mrobinson merged 1 commit into
servo:mainfrom
mrobinson:do-not-clear-contents-when-resizing-macos-surface
Jun 1, 2026
Merged

Do not clear CALayer contents when resizing macOS surfaces#357
mrobinson merged 1 commit into
servo:mainfrom
mrobinson:do-not-clear-contents-when-resizing-macos-surface

Conversation

@mrobinson
Copy link
Copy Markdown
Member

@mrobinson mrobinson commented Jun 1, 2026

The previous code was setting the layer contents to the
freshly-allocated front buffer when resizing. This meant that the layer
contents were blank (black) if painted to the screen before Servo had a
chance to repaint into the surface. This change removes that extra work
and ensures that the old contents are preserved.

The previous code was setting the layer contents to the
freshly-allocated front buffer when resizing. This meant that the layer
contents were blank (black) if painted to the screen before Servo had a
chance to repaint into the surface. This change removes that extra work
preserving the old contents.

Signed-off-by: Martin Robinson <mrobinson@abandonedwig.info>
@mrobinson mrobinson force-pushed the do-not-clear-contents-when-resizing-macos-surface branch from 1e6fa4a to af1c4c7 Compare June 1, 2026 10:24
@mrobinson mrobinson added this pull request to the merge queue Jun 1, 2026
Merged via the queue into servo:main with commit 7dd518e Jun 1, 2026
82 of 87 checks passed
@mrobinson mrobinson deleted the do-not-clear-contents-when-resizing-macos-surface branch June 1, 2026 11:28
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