mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-06 13:08:47 +02:00
Internals: Routing recoverable user errors via IMGUI_USER_ERROR() macro. (#1651)
This commit is contained in:
@ -6472,8 +6472,8 @@ void ImGui::EndTabBar()
|
||||
ImGuiTabBar* tab_bar = g.CurrentTabBar;
|
||||
if (tab_bar == NULL)
|
||||
{
|
||||
IM_ASSERT(tab_bar != NULL && "Mismatched BeginTabBar()/EndTabBar()!");
|
||||
return; // FIXME-ERRORHANDLING
|
||||
IMGUI_USER_ERROR(tab_bar != NULL, "Mismatched BeginTabBar()/EndTabBar()!");
|
||||
return;
|
||||
}
|
||||
if (tab_bar->WantLayout)
|
||||
TabBarLayout(tab_bar);
|
||||
@ -6869,8 +6869,8 @@ bool ImGui::BeginTabItem(const char* label, bool* p_open, ImGuiTabItemFlags f
|
||||
ImGuiTabBar* tab_bar = g.CurrentTabBar;
|
||||
if (tab_bar == NULL)
|
||||
{
|
||||
IM_ASSERT(tab_bar && "Needs to be called between BeginTabBar() and EndTabBar()!");
|
||||
return false; // FIXME-ERRORHANDLING
|
||||
IMGUI_USER_ERROR(tab_bar, "BeginTabItem() Needs to be called between BeginTabBar() and EndTabBar()!");
|
||||
return false;
|
||||
}
|
||||
bool ret = TabItemEx(tab_bar, label, p_open, flags);
|
||||
if (ret && !(flags & ImGuiTabItemFlags_NoPushId))
|
||||
|
Reference in New Issue
Block a user