mirror of
https://github.com/ocornut/imgui.git
synced 2026-03-27 23:37:03 -05:00
Revert changing default value of ImTextureID_Invalid to -1. Back to 0. (#9295, #9310, #9293, #8745, #8465, #7090)
Reverts 0db591935f
This commit is contained in:
@@ -41,16 +41,6 @@ HOW TO UPDATE?
|
||||
|
||||
Breaking Changes:
|
||||
|
||||
- Changed default ImTextureID_Invalid value to -1 instead of 0 if not #define-d.
|
||||
(#9293, #8745, #8465, #7090)
|
||||
- It seems like a better default since it will work with backends storing
|
||||
indices or memory offsets inside ImTextureID, where 0 might be a valid value.
|
||||
- If this is causing problem with e.g your custom ImTextureID definition, you can
|
||||
add '#define ImTextureID_Invalid 0' to your imconfig.h + PLEASE report this to GitHub.
|
||||
- If you have hardcoded e.g. 'if (tex_id == 0)' checks they should be updated.
|
||||
e.g. OpenGL2, OpenGL3 and SDLRenderer3 backends incorrectly had 'IM_ASSERT(tex->TexID == 0)'
|
||||
lines which were replaced with 'IM_ASSERT(tex->TexID == ImTextureID_Invalid)'.
|
||||
If you have copied or forked backends consider fixing locally. (#9295)
|
||||
- Separator(): fixed a legacy quirk where Separator() was submitting a zero-height
|
||||
item for layout purpose, even though it draws a 1-pixel separator.
|
||||
The fix could affect code e.g. computing height from multiple widgets in order to
|
||||
|
||||
Reference in New Issue
Block a user