diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2024-06-05 12:02:40 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-06-05 12:03:08 +0200 |
commit | a4261d25e5f191184dbc37c32346343c5cb5b166 (patch) | |
tree | 68e52df7aa4d9a8b6679b0358472bccd2fc98a15 | |
parent | b84fc31d161594f6e19f890ef4f6661456536dbf (diff) |
fix msvc link failure
-rw-r--r-- | editor/imgui-raii.cpp | 6 | ||||
-rw-r--r-- | editor/imgui-raii.hpp | 5 |
2 files changed, 8 insertions, 3 deletions
diff --git a/editor/imgui-raii.cpp b/editor/imgui-raii.cpp index b5997c7b..4c4b5911 100644 --- a/editor/imgui-raii.cpp +++ b/editor/imgui-raii.cpp @@ -160,6 +160,10 @@ raii_wrapper begin_child(StringView name, const ImVec2& size, int flags, int win return {&ImGui::EndChild}; } +} // namespace floormat::imgui + +namespace floormat::imgui::detail { + const char* label_left_(StringView label, char* buf, size_t buf_len, float width); const char* label_left_(StringView label, char* buf, size_t buf_len, float width) @@ -173,4 +177,4 @@ const char* label_left_(StringView label, char* buf, size_t buf_len, float width return buf; } -} // namespace floormat::imgui +} // namespace floormat::imgui::detail diff --git a/editor/imgui-raii.hpp b/editor/imgui-raii.hpp index 59134deb..63738113 100644 --- a/editor/imgui-raii.hpp +++ b/editor/imgui-raii.hpp @@ -67,11 +67,12 @@ private: float font_size; }; +namespace detail { const char* label_left_(StringView, char*, size_t, float); } + template<std::size_t N> const char* label_left(StringView label, char(&buf)[N], float width) { - const char* label_left_(StringView, char*, size_t, float); - return label_left_(label, static_cast<char*>(buf), N, width); + return detail::label_left_(label, static_cast<char*>(buf), N, width); } } // namespace floormat::imgui |