Skip to content

Commit

Permalink
Fixes to build examples on older imgui
Browse files Browse the repository at this point in the history
  • Loading branch information
azonenberg committed Nov 23, 2023
1 parent 0f69978 commit da5bd51
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions imgui_extra_math.inl
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,13 @@ inline ImVec2 operator*(const float lhs, const ImVec2& rhs)
return ImVec2(lhs * rhs.x, lhs * rhs.y);
}

# if IMGUI_VERSION_NUM < 18955
inline ImVec2 operator-(const ImVec2& lhs)
{
return ImVec2(-lhs.x, -lhs.y);
}
# endif

//------------------------------------------------------------------------------
inline float ImLength(float v)
{
Expand Down

0 comments on commit da5bd51

Please sign in to comment.