mirror of
https://github.com/ocornut/imgui.git
synced 2026-08-21 14:51:17 +00:00
DrawList: amend PushDrawFlag() to report reaching capacity.
This commit is contained in:
@@ -724,6 +724,7 @@ void ImDrawList::PushDrawFlag(ImDrawFlags flags, bool enabled)
|
||||
{
|
||||
IM_ASSERT((flags & ~ImDrawFlags_AllowInPushScope_) == 0);
|
||||
IM_ASSERT((flags & ImDrawFlags_StrokeMask_) == 0 || (flags & ImDrawFlags_StrokeMask_) == ImDrawFlags_StrokeLegacy);
|
||||
IM_ASSERT_USER_ERROR_RET(_DrawFlagsStack.Size < _DrawFlagsStack.capacity(), "PushDrawFlag() has a depth limit. Contact us.");
|
||||
_DrawFlagsStack.push_back(Flags);
|
||||
if (enabled)
|
||||
Flags |= flags;
|
||||
|
||||
Reference in New Issue
Block a user