diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-11-02 19:03:32 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-11-02 20:25:31 +0100 |
commit | 5a95eb1282e30bd803d7e0b352a8443795842e42 (patch) | |
tree | c97bc43e4d5107a427817c65aa1b0c2eeb64a427 /editor | |
parent | 0fe5336b9a53f20817f54be0bd7cd935db14914c (diff) |
fix build with Linux and/or GCC
Diffstat (limited to 'editor')
-rw-r--r-- | editor/events.cpp | 6 | ||||
-rw-r--r-- | editor/save.cpp | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/editor/events.cpp b/editor/events.cpp index 86ff4d59..821c9c4d 100644 --- a/editor/events.cpp +++ b/editor/events.cpp @@ -67,7 +67,7 @@ void app::on_mouse_move(const mouse_move_event& event) noexcept void app::on_mouse_up_down(const mouse_button_event& event, bool is_down) noexcept { - enum class Button : std::underlying_type_t<mouse_button> { + enum class Button_ : std::underlying_type_t<mouse_button> { Left = mouse_button_left, Right = mouse_button_right, Middle = mouse_button_middle, @@ -76,10 +76,10 @@ void app::on_mouse_up_down(const mouse_button_event& event, bool is_down) noexce const auto button = std::uint8_t(1 << (event.button-1)); struct ev { - using Button = Button; + using Button = Button_; accessor(Vector2i, position) accessor(Button, button) - } e = {event.position, Button(button)}; + } e = {event.position, Button_(button)}; if (!(cursor.in_imgui = is_down ? _imgui.handleMousePressEvent(e) : _imgui.handleMouseReleaseEvent(e))) do_mouse_up_down(button, is_down, fixup_mods(event.mods)); diff --git a/editor/save.cpp b/editor/save.cpp index 6b6f5ce2..35cdf9e7 100644 --- a/editor/save.cpp +++ b/editor/save.cpp @@ -1,6 +1,8 @@ #include "app.hpp" #include "floormat/main.hpp" #include "src/world.hpp" + +#include <filesystem> #include <Corrade/Utility/Path.h> namespace floormat { |