mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 12:02:55 +08:00
Fix settings overlay not invalidating presence on filter change
This commit is contained in:
parent
2961c383f6
commit
4c7c611218
@ -100,9 +100,23 @@ namespace osu.Game.Overlays.Settings
|
||||
|
||||
public IEnumerable<string> Keywords { get; set; }
|
||||
|
||||
public override bool IsPresent => base.IsPresent && MatchingFilter;
|
||||
private bool matchingFilter;
|
||||
|
||||
public bool MatchingFilter { get; set; } = true;
|
||||
public bool MatchingFilter
|
||||
{
|
||||
get => matchingFilter;
|
||||
set
|
||||
{
|
||||
bool wasPresent = IsPresent;
|
||||
|
||||
matchingFilter = value;
|
||||
|
||||
if (IsPresent != wasPresent)
|
||||
Invalidate(Invalidation.Presence);
|
||||
}
|
||||
}
|
||||
|
||||
public override bool IsPresent => base.IsPresent && MatchingFilter;
|
||||
|
||||
public bool FilteringActive { get; set; }
|
||||
|
||||
|
@ -21,8 +21,6 @@ namespace osu.Game.Overlays.Settings
|
||||
protected FillFlowContainer FlowContent;
|
||||
protected override Container<Drawable> Content => FlowContent;
|
||||
|
||||
public override bool IsPresent => base.IsPresent && MatchingFilter;
|
||||
|
||||
private IBindable<SettingsSection> selectedSection;
|
||||
|
||||
private Box dim;
|
||||
@ -40,7 +38,23 @@ namespace osu.Game.Overlays.Settings
|
||||
private const int header_size = 24;
|
||||
private const int border_size = 4;
|
||||
|
||||
public bool MatchingFilter { get; set; } = true;
|
||||
private bool matchingFilter;
|
||||
|
||||
public bool MatchingFilter
|
||||
{
|
||||
get => matchingFilter;
|
||||
set
|
||||
{
|
||||
bool wasPresent = IsPresent;
|
||||
|
||||
matchingFilter = value;
|
||||
|
||||
if (IsPresent != wasPresent)
|
||||
Invalidate(Invalidation.Presence);
|
||||
}
|
||||
}
|
||||
|
||||
public override bool IsPresent => base.IsPresent && MatchingFilter;
|
||||
|
||||
public bool FilteringActive { get; set; }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user