snapshot: Fix push_repeat () with empty child bounds
authorSergey Bugaev <bugaevc@gmail.com>
Wed, 23 Aug 2023 14:39:44 +0000 (17:39 +0300)
committerMatthias Clasen <mclasen@redhat.com>
Tue, 19 Sep 2023 19:16:25 +0000 (15:16 -0400)
commit7e931fca41116844f04b90c4b2d049f61948d633
tree6f7ef8941c065f00b791563ec8d4e759cdf0d68a
parent2117afbbb55136d0e450deaed87e584f7cb7831c
snapshot: Fix push_repeat () with empty child bounds

The logic would confuse empty child bounds (in which case nothing should
get rendered) with NULL child bounds (in which case the child node's own
bounds should get used). In fact, if the child bounds are empty, we can
discard the descendant render nodes completely, getting a nice little
optimization.

Signed-off-by: Sergey Bugaev <bugaevc@gmail.com>
gtk/gtksnapshot.c