File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed
Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -268,6 +268,8 @@ impl BufferInterface for BufferImpl<'_> {
268268 self . surface . damage ( 0 , 0 , i32:: MAX , i32:: MAX ) ;
269269 } else {
270270 for rect in damage {
271+ // Damage that falls outside the surface is ignored.
272+ // https://wayland.freedesktop.org/docs/html/apa.html#protocol-spec-wl_surface
271273 let x = rect. x . try_into ( ) . unwrap_or ( i32:: MAX ) ;
272274 let y = rect. y . try_into ( ) . unwrap_or ( i32:: MAX ) ;
273275 let width = rect. width . get ( ) . try_into ( ) . unwrap_or ( i32:: MAX ) ;
Original file line number Diff line number Diff line change @@ -265,6 +265,8 @@ impl Buffer<'_> {
265265
266266 /// Presents buffer to the window, with damage regions.
267267 ///
268+ /// Damage regions that fall outside the surface are ignored.
269+ ///
268270 /// # Platform dependent behavior
269271 ///
270272 /// Supported on:
You can’t perform that action at this time.
0 commit comments