diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-11-07 11:21:33 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-11-07 11:21:33 +0100 |
commit | 5bbe7c88c41e694c7a98a08c3f5209c78be4ef4f (patch) | |
tree | 1e9489cfcb14b991fb161fccec47781e5ae9b6ad /editor | |
parent | 94ebd2816ed1cbf08334573175d2ed1dec18f962 (diff) |
a
Diffstat (limited to 'editor')
-rw-r--r-- | editor/scenery-editor.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/editor/scenery-editor.cpp b/editor/scenery-editor.cpp index 74776ea1..a3560d2f 100644 --- a/editor/scenery-editor.cpp +++ b/editor/scenery-editor.cpp @@ -5,7 +5,7 @@ namespace floormat { -using rotation_ = enum rotation; +using rotation_ = rotation; using rotation_t = std::underlying_type_t<rotation_>; scenery_editor::pair::operator bool() const { return atlas != nullptr; } @@ -15,12 +15,12 @@ scenery_editor::scenery_editor() noexcept load_atlases(); } -void scenery_editor::set_rotation(enum rotation r) +void scenery_editor::set_rotation(rotation_ r) { _selected.r = r; } -rotation scenery_editor::rotation() const +rotation_ scenery_editor::rotation() const { return _selected.r; } @@ -52,7 +52,7 @@ void scenery_editor::select_tile(const std::shared_ptr<anim_atlas>& atlas, rotat void scenery_editor::clear_selection() { - _selected = { nullptr, rotation::COUNT, scenery::NO_FRAME }; + _selected = { nullptr, rotation_::COUNT, scenery::NO_FRAME }; } auto scenery_editor::get_selected() -> pair @@ -65,7 +65,7 @@ bool scenery_editor::is_atlas_selected(const std::shared_ptr<anim_atlas>& atlas) return _selected.atlas == atlas; } -bool scenery_editor::is_item_selected(const std::shared_ptr<anim_atlas>& atlas, enum rotation r, frame_t frame) const +bool scenery_editor::is_item_selected(const std::shared_ptr<anim_atlas>& atlas, rotation_ r, frame_t frame) const { return is_atlas_selected(atlas) && _selected.r == r && _selected.frame == frame; } |