Fix failing assert when splitting new asset browser in 2
This is an issue in master already, but for many layouts it just isn't triggered. Pretty sure the assert just shouldn't be executed in extreme cases, where there is no width for the layout and max-sizes become < 0.
This commit is contained in:
parent
5fcf6822dd
commit
ff213c802c
|
@ -1628,9 +1628,9 @@ float UI_text_clip_middle_ex(const uiFontStyle *fstyle,
|
|||
}
|
||||
|
||||
strwidth = BLF_width(fstyle->uifont_id, str, max_len);
|
||||
}
|
||||
|
||||
BLI_assert(strwidth <= okwidth);
|
||||
BLI_assert(strwidth <= okwidth);
|
||||
}
|
||||
|
||||
return strwidth;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue