mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 01:17:00 +00:00
Remove const qualifier on ImTextureID local (#4060)
When defining ImTextureID to a type such as Texture*, the const-qualifier here stops us from using the texture ID. const Texture* is not valid to be pushed as a texture ID anymore.
This commit is contained in:
parent
7b8932554e
commit
04e98fbe6b
@ -3770,7 +3770,7 @@ void ImGui::RenderMouseCursor(ImDrawList* draw_list, ImVec2 pos, float scale, Im
|
|||||||
if (font_atlas->GetMouseCursorTexData(mouse_cursor, &offset, &size, &uv[0], &uv[2]))
|
if (font_atlas->GetMouseCursorTexData(mouse_cursor, &offset, &size, &uv[0], &uv[2]))
|
||||||
{
|
{
|
||||||
pos -= offset;
|
pos -= offset;
|
||||||
const ImTextureID tex_id = font_atlas->TexID;
|
ImTextureID tex_id = font_atlas->TexID;
|
||||||
draw_list->PushTextureID(tex_id);
|
draw_list->PushTextureID(tex_id);
|
||||||
draw_list->AddImage(tex_id, pos + ImVec2(1, 0) * scale, pos + (ImVec2(1, 0) + size) * scale, uv[2], uv[3], col_shadow);
|
draw_list->AddImage(tex_id, pos + ImVec2(1, 0) * scale, pos + (ImVec2(1, 0) + size) * scale, uv[2], uv[3], col_shadow);
|
||||||
draw_list->AddImage(tex_id, pos + ImVec2(2, 0) * scale, pos + (ImVec2(2, 0) + size) * scale, uv[2], uv[3], col_shadow);
|
draw_list->AddImage(tex_id, pos + ImVec2(2, 0) * scale, pos + (ImVec2(2, 0) + size) * scale, uv[2], uv[3], col_shadow);
|
||||||
|
Loading…
Reference in New Issue
Block a user