Internals: Added GetWindowResizeID(), renamed GetScrollbarID() to GetWindowScrollbarID(). Using integer for resize ID so they matches regardless of the pointer size.

Internals: Renamed IMGUI_USER_ERROR to IM_ASSERT_USER_ERROR().
This commit is contained in:
omar
2019-11-15 16:44:16 +01:00
parent 8f40020ca6
commit 7e232092a6
3 changed files with 31 additions and 19 deletions

View File

@ -166,8 +166,8 @@ extern IMGUI_API ImGuiContext* GImGui; // Current implicit context pointer
#define IM_ROUND(_VAL) ((float)(int)((_VAL) + 0.5f)) //
// Error handling
#ifndef IMGUI_USER_ERROR
#define IMGUI_USER_ERROR(_EXPR, _MSG) IM_ASSERT((_EXPR) && (_MSG)) // Recoverable User Error
#ifndef IM_ASSERT_USER_ERROR
#define IM_ASSERT_USER_ERROR(_EXPR,_MSG) IM_ASSERT((_EXPR) && (_MSG)) // Recoverable User Error
#endif
// Debug Logging
@ -1712,7 +1712,8 @@ namespace ImGui
IMGUI_API bool ArrowButtonEx(const char* str_id, ImGuiDir dir, ImVec2 size_arg, ImGuiButtonFlags flags);
IMGUI_API void Scrollbar(ImGuiAxis axis);
IMGUI_API bool ScrollbarEx(const ImRect& bb, ImGuiID id, ImGuiAxis axis, float* p_scroll_v, float avail_v, float contents_v, ImDrawCornerFlags rounding_corners);
IMGUI_API ImGuiID GetScrollbarID(ImGuiWindow* window, ImGuiAxis axis);
IMGUI_API ImGuiID GetWindowScrollbarID(ImGuiWindow* window, ImGuiAxis axis);
IMGUI_API ImGuiID GetWindowResizeID(ImGuiWindow* window, int n); // 0..3: corners, 4..7: borders
IMGUI_API void SeparatorEx(ImGuiSeparatorFlags flags);
// Widgets low-level behaviors