mirror of
https://github.com/ppy/osu.git
synced 2026-05-24 07:14:10 +08:00
Make AbortConfirm() virtual and override with filter logic
This commit is contained in:
@@ -100,7 +100,7 @@ namespace osu.Game.Graphics.Containers
|
||||
/// <summary>
|
||||
/// Abort any ongoing confirmation. Should be called when the container's interaction is no longer valid (ie. the user releases a key).
|
||||
/// </summary>
|
||||
protected void AbortConfirm()
|
||||
protected virtual void AbortConfirm()
|
||||
{
|
||||
if (!confirming || (!AllowMultipleFires && Fired)) return;
|
||||
|
||||
|
||||
@@ -74,6 +74,12 @@ namespace osu.Game.Overlays.Dialog
|
||||
Progress.BindValueChanged(progressChanged);
|
||||
}
|
||||
|
||||
protected override void AbortConfirm()
|
||||
{
|
||||
lowPassFilter.CutoffTo(AudioFilter.MAX_LOWPASS_CUTOFF);
|
||||
base.AbortConfirm();
|
||||
}
|
||||
|
||||
protected override void Confirm()
|
||||
{
|
||||
lowPassFilter.CutoffTo(AudioFilter.MAX_LOWPASS_CUTOFF);
|
||||
@@ -92,7 +98,6 @@ namespace osu.Game.Overlays.Dialog
|
||||
{
|
||||
if (!e.HasAnyButtonPressed)
|
||||
{
|
||||
lowPassFilter.CutoffTo(AudioFilter.MAX_LOWPASS_CUTOFF);
|
||||
AbortConfirm();
|
||||
mouseDown = false;
|
||||
}
|
||||
@@ -112,7 +117,6 @@ namespace osu.Game.Overlays.Dialog
|
||||
|
||||
if (!mouseDown) return;
|
||||
|
||||
lowPassFilter.CutoffTo(AudioFilter.MAX_LOWPASS_CUTOFF);
|
||||
AbortConfirm();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user