mirror of
https://github.com/ppy/osu.git
synced 2025-01-27 18:32:56 +08:00
Rename out of place interface name
This commit is contained in:
parent
e631653f4b
commit
63f0b0c932
@ -178,7 +178,7 @@ namespace osu.Game.Beatmaps
|
||||
/// <summary>
|
||||
/// Fired when the user requests to view the resulting import.
|
||||
/// </summary>
|
||||
public Action<IEnumerable<ILive<BeatmapSetInfo>>> PresentImport { set => beatmapModelManager.PresentImport = value; }
|
||||
public Action<IEnumerable<ILive<BeatmapSetInfo>>> PresentImport { set => beatmapModelManager.PostImport = value; }
|
||||
|
||||
/// <summary>
|
||||
/// Delete a beatmap difficulty.
|
||||
|
@ -30,7 +30,7 @@ namespace osu.Game.Database
|
||||
/// </summary>
|
||||
/// <typeparam name="TModel">The model type.</typeparam>
|
||||
/// <typeparam name="TFileModel">The associated file join type.</typeparam>
|
||||
public abstract class ArchiveModelManager<TModel, TFileModel> : ICanAcceptFiles, IModelManager<TModel>, IModelFileManager<TModel, TFileModel>, IPresentImports<TModel>
|
||||
public abstract class ArchiveModelManager<TModel, TFileModel> : ICanAcceptFiles, IModelManager<TModel>, IModelFileManager<TModel, TFileModel>, IPostImports<TModel>
|
||||
where TModel : class, IHasFiles<TFileModel>, IHasPrimaryKey, ISoftDelete
|
||||
where TFileModel : class, INamedFileInfo, new()
|
||||
{
|
||||
@ -200,12 +200,12 @@ namespace osu.Game.Database
|
||||
? $"Imported {imported.First()}!"
|
||||
: $"Imported {imported.Count} {HumanisedModelName}s!";
|
||||
|
||||
if (imported.Count > 0 && PresentImport != null)
|
||||
if (imported.Count > 0 && PostImport != null)
|
||||
{
|
||||
notification.CompletionText += " Click to view.";
|
||||
notification.CompletionClickAction = () =>
|
||||
{
|
||||
PresentImport?.Invoke(imported);
|
||||
PostImport?.Invoke(imported);
|
||||
return true;
|
||||
};
|
||||
}
|
||||
@ -249,7 +249,7 @@ namespace osu.Game.Database
|
||||
return import;
|
||||
}
|
||||
|
||||
public Action<IEnumerable<ILive<TModel>>> PresentImport { protected get; set; }
|
||||
public Action<IEnumerable<ILive<TModel>>> PostImport { protected get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Silently import an item from an <see cref="ArchiveReader"/>.
|
||||
|
@ -6,12 +6,12 @@ using System.Collections.Generic;
|
||||
|
||||
namespace osu.Game.Database
|
||||
{
|
||||
public interface IPresentImports<out TModel>
|
||||
public interface IPostImports<out TModel>
|
||||
where TModel : class
|
||||
{
|
||||
/// <summary>
|
||||
/// Fired when the user requests to view the resulting import.
|
||||
/// </summary>
|
||||
public Action<IEnumerable<ILive<TModel>>> PresentImport { set; }
|
||||
public Action<IEnumerable<ILive<TModel>>> PostImport { set; }
|
||||
}
|
||||
}
|
@ -627,7 +627,7 @@ namespace osu.Game
|
||||
BeatmapManager.PresentImport = items => PresentBeatmap(items.First().Value);
|
||||
|
||||
ScoreManager.PostNotification = n => Notifications.Post(n);
|
||||
ScoreManager.PresentImport = items => PresentScore(items.First().Value);
|
||||
ScoreManager.PostImport = items => PresentScore(items.First().Value);
|
||||
|
||||
// make config aware of how to lookup skins for on-screen display purposes.
|
||||
// if this becomes a more common thing, tracked settings should be reconsidered to allow local DI.
|
||||
|
@ -25,7 +25,7 @@ using osu.Game.Rulesets.Scoring;
|
||||
|
||||
namespace osu.Game.Scoring
|
||||
{
|
||||
public class ScoreManager : IModelManager<ScoreInfo>, IModelFileManager<ScoreInfo, ScoreFileInfo>, IModelDownloader<ScoreInfo>, ICanAcceptFiles, IPresentImports<ScoreInfo>
|
||||
public class ScoreManager : IModelManager<ScoreInfo>, IModelFileManager<ScoreInfo, ScoreFileInfo>, IModelDownloader<ScoreInfo>, ICanAcceptFiles, IPostImports<ScoreInfo>
|
||||
{
|
||||
private readonly Scheduler scheduler;
|
||||
private readonly Func<BeatmapDifficultyCache> difficulties;
|
||||
@ -365,9 +365,9 @@ namespace osu.Game.Scoring
|
||||
|
||||
#region Implementation of IPresentImports<ScoreInfo>
|
||||
|
||||
public Action<IEnumerable<ILive<ScoreInfo>>> PresentImport
|
||||
public Action<IEnumerable<ILive<ScoreInfo>>> PostImport
|
||||
{
|
||||
set => scoreModelManager.PresentImport = value;
|
||||
set => scoreModelManager.PostImport = value;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
Loading…
Reference in New Issue
Block a user