mirror of
https://github.com/ppy/osu.git
synced 2024-12-13 08:32:57 +08:00
Update usages of RemoveInternal
This commit is contained in:
parent
a215d009fe
commit
105aa01e7d
@ -56,7 +56,7 @@ namespace osu.Game.Rulesets.Catch.Edit.Blueprints.Components
|
||||
public void UpdateFrom(ScrollingHitObjectContainer hitObjectContainer, JuiceStream hitObject)
|
||||
{
|
||||
while (path.Vertices.Count < InternalChildren.Count)
|
||||
RemoveInternal(InternalChildren[^1]);
|
||||
RemoveInternal(InternalChildren[^1], true);
|
||||
|
||||
while (InternalChildren.Count < path.Vertices.Count)
|
||||
AddInternal(new VertexPiece());
|
||||
|
@ -30,7 +30,7 @@ namespace osu.Game.Rulesets.Catch.Edit.Blueprints.Components
|
||||
.Where(h => !(h is TinyDroplet)));
|
||||
|
||||
while (nestedHitObjects.Count < InternalChildren.Count)
|
||||
RemoveInternal(InternalChildren[^1]);
|
||||
RemoveInternal(InternalChildren[^1], true);
|
||||
|
||||
while (InternalChildren.Count < nestedHitObjects.Count)
|
||||
AddInternal(new FruitOutline());
|
||||
|
@ -77,7 +77,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
||||
// This is a bit ugly but we don't have the concept of InternalContent so it'll have to do for now. (https://github.com/ppy/osu-framework/issues/1690)
|
||||
protected override void AddInternal(Drawable drawable) => shakeContainer.Add(drawable);
|
||||
protected override void ClearInternal(bool disposeChildren = true) => shakeContainer.Clear(disposeChildren);
|
||||
protected override bool RemoveInternal(Drawable drawable) => shakeContainer.Remove(drawable, true);
|
||||
protected override bool RemoveInternal(Drawable drawable, bool disposeImmediately) => shakeContainer.Remove(drawable, disposeImmediately);
|
||||
|
||||
protected sealed override double InitialLifetimeOffset => HitObject.TimePreempt;
|
||||
|
||||
|
@ -57,7 +57,7 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
{
|
||||
if (bufferedContainer == null && newBlurSigma != Vector2.Zero)
|
||||
{
|
||||
RemoveInternal(Sprite);
|
||||
RemoveInternal(Sprite, false);
|
||||
|
||||
AddInternal(bufferedContainer = new BufferedContainer(cachedFrameBuffer: true)
|
||||
{
|
||||
|
@ -35,7 +35,7 @@ namespace osu.Game.Graphics.Containers
|
||||
if (value == expandableHeader) return;
|
||||
|
||||
if (expandableHeader != null)
|
||||
RemoveInternal(expandableHeader);
|
||||
RemoveInternal(expandableHeader, false);
|
||||
|
||||
expandableHeader = value;
|
||||
|
||||
|
@ -165,7 +165,7 @@ namespace osu.Game.Rulesets.Judgements
|
||||
|
||||
// sub-classes might have added their own children that would be removed here if .InternalChild was used.
|
||||
if (JudgementBody != null)
|
||||
RemoveInternal(JudgementBody);
|
||||
RemoveInternal(JudgementBody, true);
|
||||
|
||||
AddInternal(JudgementBody = new SkinnableDrawable(new GameplaySkinComponent<HitResult>(type), _ =>
|
||||
CreateDefaultJudgement(type), confineMode: ConfineMode.NoScaling)
|
||||
|
@ -132,7 +132,7 @@ namespace osu.Game.Rulesets.Objects.Pooling
|
||||
/// <remarks>
|
||||
/// Invoked when the entry became dead.
|
||||
/// </remarks>
|
||||
protected virtual void RemoveDrawable(TEntry entry, TDrawable drawable) => RemoveInternal(drawable);
|
||||
protected virtual void RemoveDrawable(TEntry entry, TDrawable drawable) => RemoveInternal(drawable, false);
|
||||
|
||||
private void entryCrossedBoundary(LifetimeEntry lifetimeEntry, LifetimeBoundaryKind kind, LifetimeBoundaryCrossingDirection direction)
|
||||
{
|
||||
|
@ -124,7 +124,7 @@ namespace osu.Game.Rulesets.UI
|
||||
|
||||
unbindStartTime(drawable);
|
||||
|
||||
RemoveInternal(drawable);
|
||||
RemoveInternal(drawable, false);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
@ -166,8 +166,7 @@ namespace osu.Game.Screens.Play
|
||||
if (filters.Parent == null)
|
||||
return;
|
||||
|
||||
RemoveInternal(filters);
|
||||
filters.Dispose();
|
||||
RemoveInternal(filters, true);
|
||||
}
|
||||
|
||||
protected override void Update()
|
||||
|
@ -34,7 +34,7 @@ namespace osu.Game.Screens.Ranking
|
||||
if (InternalChildren.Count == 0)
|
||||
throw new InvalidOperationException("Score panel container is not attached.");
|
||||
|
||||
RemoveInternal(Panel);
|
||||
RemoveInternal(Panel, false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
Loading…
Reference in New Issue
Block a user