1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 14:17:26 +08:00

Log posted notifications

To help with test failures and the likes.
This commit is contained in:
Dean Herbert 2022-01-25 23:38:46 +09:00
parent c32c26dc72
commit cdef67ccd0
4 changed files with 8 additions and 2 deletions

View File

@ -12,6 +12,7 @@ using osu.Framework.Allocation;
using osu.Framework.Audio;
using osu.Framework.Bindables;
using osu.Framework.Localisation;
using osu.Framework.Logging;
using osu.Framework.Threading;
using osu.Game.Graphics;
using osu.Game.Localisation;
@ -118,6 +119,8 @@ namespace osu.Game.Overlays
{
++runningDepth;
Logger.Log($"⚠️ {notification.Text}");
notification.Closed += notificationClosed;
if (notification is IHasCompletionTarget hasCompletionTarget)

View File

@ -11,6 +11,7 @@ using osu.Framework.Graphics.Effects;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Input.Events;
using osu.Framework.Localisation;
using osu.Game.Graphics;
using osu.Game.Graphics.Containers;
using osuTK;
@ -25,6 +26,8 @@ namespace osu.Game.Overlays.Notifications
/// </summary>
public event Action Closed;
public abstract LocalisableString Text { get; set; }
/// <summary>
/// Whether this notification should forcefully display itself.
/// </summary>

View File

@ -25,7 +25,7 @@ namespace osu.Game.Overlays.Notifications
private LocalisableString text;
public LocalisableString Text
public override LocalisableString Text
{
get => text;
set

View File

@ -18,7 +18,7 @@ namespace osu.Game.Overlays.Notifications
{
private LocalisableString text;
public LocalisableString Text
public override LocalisableString Text
{
get => text;
set