Reset buttons - fixed rotation of instances with multiple volumes

Mirroring buttons now hide where appropriate
This commit is contained in:
Lukas Matena 2019-06-05 11:23:30 +02:00
parent a3c1644ead
commit 980c6673d4
5 changed files with 83 additions and 33 deletions

View file

@ -56,9 +56,19 @@ class ObjectManipulation : public OG_Settings
// Non-owning pointers to the reset buttons, so we can hide and show them.
ScalableButton* m_reset_scale_button = nullptr;
ScalableButton* m_reset_rotation_button = nullptr;
std::map<std::string, ScalableButton*> m_mirror_buttons;
// Mirroring buttons and their current state
enum MirrorButtonState {
mbHidden,
mbShown,
mbActive
};
std::array<std::pair<ScalableButton*, MirrorButtonState>, 3> m_mirror_buttons;
// Bitmaps for the mirroring buttons.
ScalableBitmap m_mirror_bitmap_on;
ScalableBitmap m_mirror_bitmap_off;
ScalableBitmap m_mirror_bitmap_hidden;
// Needs to be updated from OnIdle?
bool m_dirty = false;