macos: use GdkMacosBuffer for storing damage region
authorChristian Hergert <christian@hergert.me>
Wed, 2 Mar 2022 08:36:17 +0000 (00:36 -0800)
committerChristian Hergert <christian@hergert.me>
Wed, 2 Mar 2022 08:36:17 +0000 (00:36 -0800)
commitbdd5393084fa9118049d3871030457f81e02a175
treedd18a55a1fe8725c79c5bb10a7db2070060a353b
parent27b87ebec53e1af8bc819bfdabc2bc8deaea4749
macos: use GdkMacosBuffer for storing damage region

The GdkMacosBuffer object already has storage for tracking the damage
region as it is used in GdkMacosCairoContext to manually copy regions from
the front buffer to the back buffer. This makes the GdkMacosGLContext also
use that field so that we can easily drop old damage regions when the
buffer is lost. This happens during resizes, monitor changes, etc.
gdk/macos/gdkmacosglcontext-private.h
gdk/macos/gdkmacosglcontext.c