mirror of
https://github.com/ppy/osu
synced 2025-01-24 23:03:14 +00:00
Fix rotation popover potentially crashing due to activating selection origin just before disabling it
This commit is contained in:
parent
3a3471c202
commit
e2a4a9b300
@ -103,6 +103,11 @@ namespace osu.Game.Rulesets.Osu.Edit
|
|||||||
});
|
});
|
||||||
angleInput.Current.BindValueChanged(angle => rotationInfo.Value = rotationInfo.Value with { Degrees = angle.NewValue });
|
angleInput.Current.BindValueChanged(angle => rotationInfo.Value = rotationInfo.Value with { Degrees = angle.NewValue });
|
||||||
|
|
||||||
|
rotationHandler.CanRotateAroundSelectionOrigin.BindValueChanged(e =>
|
||||||
|
{
|
||||||
|
selectionCentreButton.Selected.Disabled = !e.NewValue;
|
||||||
|
}, true);
|
||||||
|
|
||||||
bool didSelect = false;
|
bool didSelect = false;
|
||||||
|
|
||||||
configRotationOrigin.BindValueChanged(val =>
|
configRotationOrigin.BindValueChanged(val =>
|
||||||
@ -154,11 +159,6 @@ namespace osu.Game.Rulesets.Osu.Edit
|
|||||||
if (b.NewValue) configRotationOrigin.Value = EditorOrigin.SelectionCentre;
|
if (b.NewValue) configRotationOrigin.Value = EditorOrigin.SelectionCentre;
|
||||||
});
|
});
|
||||||
|
|
||||||
rotationHandler.CanRotateAroundSelectionOrigin.BindValueChanged(e =>
|
|
||||||
{
|
|
||||||
selectionCentreButton.Selected.Disabled = !e.NewValue;
|
|
||||||
}, true);
|
|
||||||
|
|
||||||
rotationInfo.BindValueChanged(rotation =>
|
rotationInfo.BindValueChanged(rotation =>
|
||||||
{
|
{
|
||||||
rotationHandler.Update(rotation.NewValue.Degrees, getOriginPosition(rotation.NewValue));
|
rotationHandler.Update(rotation.NewValue.Degrees, getOriginPosition(rotation.NewValue));
|
||||||
|
Loading…
Reference in New Issue
Block a user