فهرست منبع

Backends: Allegro5: fixed use of obsolete IM_OFFSETOF().

ocornut 1 ماه پیش
والد
کامیت
e2a662eed8
1فایلهای تغییر یافته به همراه3 افزوده شده و 3 حذف شده
  1. 3 3
      backends/imgui_impl_allegro5.cpp

+ 3 - 3
backends/imgui_impl_allegro5.cpp

@@ -526,9 +526,9 @@ void ImGui_ImplAllegro5_SetDisplay(ALLEGRO_DISPLAY* display)
         // We still use a custom declaration to use 'ALLEGRO_PRIM_TEX_COORD' instead of 'ALLEGRO_PRIM_TEX_COORD_PIXEL' else we can't do a reliable conversion.
         // We still use a custom declaration to use 'ALLEGRO_PRIM_TEX_COORD' instead of 'ALLEGRO_PRIM_TEX_COORD_PIXEL' else we can't do a reliable conversion.
         ALLEGRO_VERTEX_ELEMENT elems[] =
         ALLEGRO_VERTEX_ELEMENT elems[] =
         {
         {
-            { ALLEGRO_PRIM_POSITION, ALLEGRO_PRIM_FLOAT_2, IM_OFFSETOF(ImDrawVertAllegro, pos) },
-            { ALLEGRO_PRIM_TEX_COORD, ALLEGRO_PRIM_FLOAT_2, IM_OFFSETOF(ImDrawVertAllegro, uv) },
-            { ALLEGRO_PRIM_COLOR_ATTR, 0, IM_OFFSETOF(ImDrawVertAllegro, col) },
+            { ALLEGRO_PRIM_POSITION, ALLEGRO_PRIM_FLOAT_2, offsetof(ImDrawVertAllegro, pos) },
+            { ALLEGRO_PRIM_TEX_COORD, ALLEGRO_PRIM_FLOAT_2, offsetof(ImDrawVertAllegro, uv) },
+            { ALLEGRO_PRIM_COLOR_ATTR, 0, offsetof(ImDrawVertAllegro, col) },
             { 0, 0, 0 }
             { 0, 0, 0 }
         };
         };
         bd->VertexDecl = al_create_vertex_decl(elems, sizeof(ImDrawVertAllegro));
         bd->VertexDecl = al_create_vertex_decl(elems, sizeof(ImDrawVertAllegro));