1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-21 03:02:54 +08:00

Revert some changes

I can see `IsDisplayingToast` being removed and `IsPresent` becoming `=> Notifications.Any()` but I'll just leave this for another day.
This commit is contained in:
Salman Ahmed 2024-07-11 14:22:23 +03:00
parent bfe34c9671
commit 7b541d378c

View File

@ -24,7 +24,7 @@ namespace osu.Game.Overlays
/// </summary>
public partial class NotificationOverlayToastTray : CompositeDrawable
{
public override bool IsPresent => toastContentBackground.Height > 0 || Notifications.Any();
public override bool IsPresent => toastContentBackground.Height > 0 || toastFlow.Count > 0;
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => toastFlow.ReceivePositionalInputAt(screenSpacePos);
@ -33,7 +33,7 @@ namespace osu.Game.Overlays
/// </summary>
public IEnumerable<Notification> Notifications => toastFlow.Concat(InternalChildren.OfType<Notification>());
public bool IsDisplayingToasts => Notifications.Any();
public bool IsDisplayingToasts => toastFlow.Count > 0;
private FillFlowContainer<Notification> toastFlow = null!;
private BufferedContainer toastContentBackground = null!;