UI: only draw a single header in the header region

While this isn't an issue with the default configuration it's possible
to register extra header types for a single region.

In this case the first header-type to successfully poll is drawn
without drawing other header types.

This issue was raised by T60195.
This commit is contained in:
Campbell Barton
2020-09-17 14:40:30 +10:00
parent 3fb7e5df50
commit 4b20eebb85

View File

@@ -3137,6 +3137,10 @@ void ED_region_header_layout(const bContext *C, ARegion *region)
}
UI_block_end(C, block);
/* In most cases there is only ever one header, it never makes sense to draw more than one
* header in the same region, this results in overlapping buttons, see: T60195. */
break;
}
if (!region_layout_based) {